[SciPy-user] error linking to libg2c on 64-bit machine

Giovanni Samaey Giovanni.Samaey at cs.kuleuven.ac.be
Tue Nov 9 04:22:55 CST 2004


Hi,

I get an error linking to lg2c when building scipy on a 64 bit machine. 
(machine and compiler characteristics
below...)
The error I get is the following:

/usr/bin/g77 -shared 
build/temp.linux-x86_64-2.3/Lib/interpolate/_fitpackmodule.o 
-Lbuild/temp.linux-x86_64-2.3 -lfitpack -lg2c -o 
build/lib.linux-x86_64-2.3/scipy/interpolate/_fitpack.so
/usr/bin/ld: /usr/lib/gcc-lib/i486-linux/3.3.2/64/libg2c.a(lread.o): 
relocation
R_X86_64_32 can not be used when making a shared object; recompile with 
-fPIC
/usr/lib/gcc-lib/i486-linux/3.3.2/64/libg2c.a: could not read symbols: 
Bad valuecollect2: ld returned 1 exit status
/usr/bin/ld: /usr/lib/gcc-lib/i486-linux/3.3.2/64/libg2c.a(lread.o): 
relocation
R_X86_64_32 can not be used when making a shared object; recompile with 
-fPIC
/usr/lib/gcc-lib/i486-linux/3.3.2/64/libg2c.a: could not read symbols: 
Bad valuecollect2: ld returned 1 exit status
error: Command "/usr/bin/g77 -shared 
build/temp.linux-x86_64-2.3/Lib/interpolate/_fitpackmodule.o 
-Lbuild/temp.linux-x86_64-2.3 -lfitpack -lg2c -o 
build/lib.linux-x86_64-2.3/scipy/interpolate/_fitpack.so" failed with 
exit status 1

So there is an incompatibility between what g77 is compiling and what is 
in this version of libg2c.
Recompiling libg2c (as suggested) is not an option.  But there are other 
libg2c versions available.  Only I don't
know (and didn't find in the doc's) how to change the standard choice in 
the installation script. What could I do?

I am trying to install scipy on a 64 bit machine with the following 
characteristics

posix linux2
Linux inti 2.4.27 #2 SMP Mon Aug 9 13:36:15 CEST 2004 x86_64 GNU/Linux

with compiler version gcc 3.3.2, configured as follows

Reading specs from /usr/lib/gcc-lib/i486-linux/3.3.2/specs
Configured with: ../src/configure -v 
--enable-languages=c,c++,java,f77,pascal,objc,ada,treelang --prefix=/usr 
--mandir=/usr/share/man --infodir=/usr/share/info
--with-gxx-include-dir=/usr/include/c++/3.3 --enable-shared 
--with-system-zlib --enable-nls --without-included-gettext 
--enable-__cxa_atexit --enable-clocale=gnu --enable-debug 
--enable-java-gc=boehm --enable-java-awt=xlib --enable-objc-gc
i486-linux
Thread model: posix
gcc version 3.3.2 (Debian)


-- 
Giovanni Samaey		 	http://www.cs.kuleuven.ac.be/~giovanni/ 
Katholieke Universiteit Leuven 	      email: giovanni at cs.kuleuven.ac.be 
Departement Computerwetenschappen                  phone: +32-16-327081
Celestijnenlaan 200A, B-3001 Heverlee, Belgium       fax: +32-16-327996
Office: A04.36




More information about the SciPy-user mailing list