On Ubuntu 11.04, I think the easiest option is to install the ubuntu packages gcc-4.4 and g++-4.4 and use this compiler with the following configure options
Concerning the custom gcc:
The problem is the "--enable-version-specific-runtime-libs" option together with the multilib system. The gcc installation places libgcc_s.so(.1) in
Code: Select all
$PREFIX/lib/gcc/x86_64-linux-gnu/lib{64,32}/libgcc_s.so
But the linker looks only in
Code: Select all
$PREFIX/lib/gcc/x86_64-linux-gnu/4.6.1, $PREFIX/lib64, $PREFIX/lib
which wont work.
Seems to be a long open gcc bug:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32415
One fix was to add LDFLAGS="-L$PREFIX/lib/gcc/x86_64-linux-gnu/lib64/" to configure, but the ldflags will not be passed to the nauty configure script (because they should not be necessary there), thus this configure script fails and does not create nauty.h.
You can either add the ldflags to the call of the nauty configuration script in some Makefile or you could move libgcc_s.so(.1) from .../lib64 to .../4.6.1 and the 32bit versions from .../lib32 to .../4.6.1/32. (I think the second one is the better solution as this is where these files should lie)
Or, last option, remove the --enable-version-specific-runtime-libs option and reinstall gcc, then the library should end up in $PREFIX/lib{64,32} which is correct and one of the paths scanned by the linker.
Once you got it to compile the next problem you might face is that the
runtime linker will find the system default libgcc_s.so / libstdc++.so first which will be too old for a pogram linked with a newer version of the library. Then you need to set a runtime linker path:
Code: Select all
-Wl,-rpath,$PREFIX/lib/gcc/x86_64-linux-gnu/4.6.1