On 05/24/10 05:26 PM, leif wrote:
On 24 Mai, 14:45, Matthew Gwynne<mathew.gwy...@gmail.com>  wrote:
When building Sage 4.4.1, I (and also my colleague) get the following
errors during the build process -

/bin/sh ./libtool --tag=CXX --mode=link g++  -fPIC -I/home/csoliver/
SAT-Algorithmen/OKplatform/ExternalSources/Installations/Sage/
sage-4.4.1/local/include/ -L/home/csoliver/SAT-Algorithmen/OKplatform/
ExternalSources/Installations/Sage/sage-4.4.1/local/lib   -o
libfplll.la -rpath /home/csoliver/SAT-Algorithmen/OKplatform/
ExternalSources/Installations/Sage/sage-4.4.1/local/lib -version-info
1:0:1 dummy.lo -lgmp -lmpfr -lmpfr -lgmp -lmpfr -lgmp
g++ -shared -nostdlib /usr/lib/../lib64/crti.o /usr/local/lib/gcc/
x86_64-unknown-linux-gnu/4.1.2/crtbeginS.o  .libs/dummy.o  -Wl,--rpath
-Wl,/home/csoliver/SAT-Algorithmen/OKplatform/ExternalSources/
Installations/Sage/sage-4.4.1/local/lib -Wl,--rpath -Wl,/usr/local/
lib/../lib -Wl,--rpath -Wl,/home/csoliver/SAT-Algorithmen/OKplatform/
ExternalSources/Installations/Sage/sage-4.4.1/local/lib -Wl,--rpath -
Wl,/usr/local/lib/../lib -L/home/csoliver/SAT-Algorithmen/OKplatform/
ExternalSources/Installations/Sage/sage-4.4.1/local/lib /home/csoliver/
SAT-Algorithmen/OKplatform/ExternalSources/Installations/Sage/
sage-4.4.1/local/lib/libmpfr.so /home/csoliver/SAT-Algorithmen/
OKplatform/ExternalSources/Installations/Sage/sage-4.4.1/local/lib/
libgmp.so -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/4.1.2 -L/usr/
local/lib/gcc/x86_64-unknown-linux-gnu/4.1.2/../../../../x86_64-
unknown-linux-gnu/lib -L/usr/local/lib/gcc/x86_64-unknown-linux-gnu/
4.1.2/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 /usr/local/
lib/../lib/libstdc++.so -lm -lc -lgcc_s /usr/local/lib/gcc/x86_64-
unknown-linux-gnu/4.1.2/crtendS.o /usr/lib/../lib64/crtn.o  -Wl,-
soname -Wl,libfplll.so.0 -o .libs/libfplll.so.0.1.0
/usr/local/lib/../lib/libstdc++.so: could not read symbols: File in
wrong format
collect2: ld returned 1 exit status
make[4]: *** [libfplll.la] Error 1
make[4]: Leaving directory `/home/csoliver/SAT-Algorithmen/OKplatform/
ExternalSources/Installations/Sage/sage-4.4.1/spkg/build/
libfplll-3.0.12.p0/src'

Does anyone have any idea if I am doing something wrong, or whether
this is a possible problem with Sage itself?

Looks like the (fairly old) gcc/g++ in /usr/local is misconfigured; it
definitely tries to link a 64-bit (x86_64) C++ program against the 32-
bit libstdc++.so (in /usr/local/lib) instead of the 64-bit version in /
usr/local/lib64. (Actually it is forced to do so by libtool.)

-Leif


I'm not so convinced this failure with 'libfplll' is a gcc problem, but rather it is a 'libfplll' problem.

I'm seeing the exact same issue with 'libfplll' on OpenSolaris.

http://trac.sagemath.org/sage_trac/ticket/7864

The fact the original poster, his colleague and myself are all seeing this, suggests to me that perhaps libfplll may be at fault in trying to link 64-bit objects to 32-bit libstdc++

Other parts of the Sage build process are correctly using the 64-bit version of libstdc++.so on my OpenSolaris box - see for example this line.

g++ -shared -nostdlib /usr/lib/amd64/crti.o /usr/lib/amd64/values-Xa.o /usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4/amd64/crtbegin.o .libs/dummy.o cxx/.libs/isfuns.o cxx/.libs/ismpf.o cxx/.libs/ismpq.o cxx/.libs/ismpz.o cxx/.libs/ismpznw.o cxx/.libs/osdoprnti.o cxx/.libs/osfuns.o cxx/.libs/osmpf.o cxx/.libs/osmpq.o cxx/.libs/osmpz.o -Wl,-R -Wl,/export/home/drkirkby/sage-4.4.2/spkg/build/mpir-1.2.2.p1/src/.libs -Wl,-R -Wl,/usr/local/gcc-4.4.4/lib/amd64 -Wl,-R -Wl,/export/home/drkirkby/sage-4.4.2/local/lib -Wl,-R -Wl,/usr/local/gcc-4.4.4/lib/amd64 ./.libs/libgmp.so -L/usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4/amd64 -L/usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4/../../../amd64 -L/lib/amd64 -L/usr/lib/amd64 -L/export/home/drkirkby/sage-4.4.2/local/lib -L/usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4 -L/usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4/../../.. /usr/local/gcc-4.4.4/lib/amd64/libstdc++.so -lm -lgcc_s /usr/local/gcc-4.4.4/lib/gcc/i386-pc-solaris2.11/4.4.4/amd64/crtend.o /usr/lib/amd64/crtn.o -m64 -march=core2 -mtune=core2 -Wl,-h -Wl,libgmpxx.so.3 -o .libs/libgmpxx.so.3.1.6

where you can see that the 64-bit /usr/local/gcc-4.4.4/lib/amd64/libstdc++.so library is used, not the 32-bit library at /usr/local/gcc-4.4.4/lib/libstdc++.so

So some parts of the Sage build process manage to work out that the 64-bit library should be used, but libfplll does not.

I've found a similar issue with pynac. It would be intersting what the original poster gets if he runs:

$ ./sage -f pynac-0.1.12 (or it might need to be)
$ ./sage -f pynac-0.1.11

I would not be surprised if he sees the same problem.

Dave


--
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to