[DRE-maint] Bug#633302: Bug#633302: ruby-bcrypt: FTBFS everywhere: [BUG] Segmentation fault

Antonio Terceiro terceiro at softwarelivre.org
Tue Jul 19 01:31:16 UTC 2011


Vasudev Kamath escreveu isso aí:
> Antonio thanks for fixing the issue.
> 
> > Actually this is a packaging problem: the tests for Ruby 1.8 are being
> > run against the compiled extension for Ruby 1.9.
> >
> $: << 'lib' << 'ext/mri' << '.'
> 
> If I remember correctly this line was added because when I was trying
> to build the package with tests enabled first time it was throwing
> error complaining bcrypt.h file is not found. This is error was thrown
> from the file ext/mri/bcrypt_ext.c file. To fix this line was added.
> Is it building fine without this line?

With the new gem2deb (not uploaded yet), yes. gem2deb will prepare the
$LOAD_PATH automatically to run the tests against the code that was
installed in debian/$package so the maintainer does not need to manually
manipulate the $LOAD_PATH.

The problem is that gem2deb builds the C extension for 1.8 in ext/mri,
then cleans (as in `make clean`), and then builds for 1.9 in the same
directory. This all happens before the tests are run, so when you add
"ext/mri" to the $LOAD_PATH in the test file, it only contains a 1.9
.so, and that's why the 1.8 tests segfault.

-- 
Antonio Terceiro <terceiro at softwarelivre.org>
http://softwarelivre.org/terceiro


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-ruby-extras-maintainers/attachments/20110718/014c8b8a/attachment.pgp>


More information about the Pkg-ruby-extras-maintainers mailing list