I
Ishmael
I am trying to compile the Math::GMP module locally (not as root). I
have successfully built gmp-4.2.1, but am having trouble getting the
Perl wrapper to work. I am doing the following:
perl Makefile.PL PREFIX=/home/kstahl/PERL/Math-GMP-2.04
Here, I receive the following messages:
Note (probably harmless): No library found for -lgmp
Writing Makefile for Math::GMP
Now in order to point Make in the right direction to find my
installation of gmp, I edited the Makefile, and added the correct path
to CCFLAGS, i.e. the last entry below:
CCFLAGS = -I/usr/local/include/db3 -I/usr/local/include
-I/apps/supported/include -I/home/kstahl/PERL/gmp-4.2.1
Then I run make and get these messages:
cc -c -I/usr/local/include/db3 -I/usr/local/include
-I/apps/supported/include
-I/home/kstahl/PERL/gmp-4.2.1 -O -DVERSION=\"2.04\"
-DXS_VERSION=\"2.04\"
-KPIC "-I/apps/gnu/perl-5.6.1/lib/sol2.sun4/CORE" GMP.c
Running Mkbootstrap for Math::GMP ()
chmod 644 GMP.bs
rm -f blib/arch/auto/Math/GMP/GMP.so
LD_RUN_PATH="" cc -G -L/usr/local/lib/db3 -L/usr/local/lib
-L/apps/supported/lib/sol2.sun4 GMP.o -o
blib/arch/auto/Math/GMP/GMP.so
chmod 755 blib/arch/auto/Math/GMP/GMP.so
cp GMP.bs blib/arch/auto/Math/GMP/GMP.bs
chmod 644 blib/arch/auto/Math/GMP/GMP.bs
Manifying blib/man3/Math::GMP.3pm
It looks like everything worked, but then I run 'make test' and get the
following errors:
PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-e"
"test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/gmppm....Can't load
'/home/kstahl/PERL/Math-GMP-2.04/blib/arch/auto/Math/GMP/GMP.so' for
module
Math::GMP: ld.so.1: /usr/local/bin/perl: fatal: relocation error:
file
/home/kstahl/PERL/Math-GMP-2.04/blib/arch/auto/Math/GMP/GMP.so:
symbol
__gmpz_init_set_str: referenced symbol not found at
/apps/gnu/perl-5.6.1/lib/sol2.sun4/DynaLoader.pm line 206.
at t/gmppm.t line 7
Compilation failed in require at t/gmppm.t line 7.
BEGIN failed--compilation aborted at t/gmppm.t line 7.
t/gmppm....dubious
Test returned status 255 (wstat 65280, 0xff00)
FAILED--1 test script could be run, alas--no output ever seen
make: *** [test_dynamic] Error 255
I checked in the directory shown above, and GMP.so is right there, as
expected. Any help with this will be greatly appreciated. Thanks!
have successfully built gmp-4.2.1, but am having trouble getting the
Perl wrapper to work. I am doing the following:
perl Makefile.PL PREFIX=/home/kstahl/PERL/Math-GMP-2.04
Here, I receive the following messages:
Note (probably harmless): No library found for -lgmp
Writing Makefile for Math::GMP
Now in order to point Make in the right direction to find my
installation of gmp, I edited the Makefile, and added the correct path
to CCFLAGS, i.e. the last entry below:
CCFLAGS = -I/usr/local/include/db3 -I/usr/local/include
-I/apps/supported/include -I/home/kstahl/PERL/gmp-4.2.1
Then I run make and get these messages:
cc -c -I/usr/local/include/db3 -I/usr/local/include
-I/apps/supported/include
-I/home/kstahl/PERL/gmp-4.2.1 -O -DVERSION=\"2.04\"
-DXS_VERSION=\"2.04\"
-KPIC "-I/apps/gnu/perl-5.6.1/lib/sol2.sun4/CORE" GMP.c
Running Mkbootstrap for Math::GMP ()
chmod 644 GMP.bs
rm -f blib/arch/auto/Math/GMP/GMP.so
LD_RUN_PATH="" cc -G -L/usr/local/lib/db3 -L/usr/local/lib
-L/apps/supported/lib/sol2.sun4 GMP.o -o
blib/arch/auto/Math/GMP/GMP.so
chmod 755 blib/arch/auto/Math/GMP/GMP.so
cp GMP.bs blib/arch/auto/Math/GMP/GMP.bs
chmod 644 blib/arch/auto/Math/GMP/GMP.bs
Manifying blib/man3/Math::GMP.3pm
It looks like everything worked, but then I run 'make test' and get the
following errors:
PERL_DL_NONLAZY=1 /usr/local/bin/perl "-MExtUtils::Command::MM" "-e"
"test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/gmppm....Can't load
'/home/kstahl/PERL/Math-GMP-2.04/blib/arch/auto/Math/GMP/GMP.so' for
module
Math::GMP: ld.so.1: /usr/local/bin/perl: fatal: relocation error:
file
/home/kstahl/PERL/Math-GMP-2.04/blib/arch/auto/Math/GMP/GMP.so:
symbol
__gmpz_init_set_str: referenced symbol not found at
/apps/gnu/perl-5.6.1/lib/sol2.sun4/DynaLoader.pm line 206.
at t/gmppm.t line 7
Compilation failed in require at t/gmppm.t line 7.
BEGIN failed--compilation aborted at t/gmppm.t line 7.
t/gmppm....dubious
Test returned status 255 (wstat 65280, 0xff00)
FAILED--1 test script could be run, alas--no output ever seen
make: *** [test_dynamic] Error 255
I checked in the directory shown above, and GMP.so is right there, as
expected. Any help with this will be greatly appreciated. Thanks!