Less intrussive fix for glibc 2.16 cross-rpcgen build

Using LD_LIBRARY_PATH, sets overrides of libs for all binaries run.

On mips64, the libz in the bootstrap-tools is a bit incompatible with
the libz binutils are built with (ld.so outputs a warning at every program run
that uses libz). binutils need to be dynamically linked to the libz they
have been linked to.

Glibc creates 'shlib.lds' using the gas program output, and it includes the
ld.so warning in case of using LD_LIBRARY_PATH. That breaks the glibc build.

As Makefile includes BUILD_LDFLAGS for the purpose of cross-rpcgen, I
use this instead of the intrusive LD_LIBRARY_PATH.
This commit is contained in:
Lluís Batlle i Rossell 2012-12-24 13:06:04 +01:00
parent 0584c1c693
commit 636722eb93

@ -170,8 +170,7 @@ stdenv.mkDerivation ({
configureScript="`pwd`/../$sourceRoot/configure"
# Needed to build rpcgen.
export LD_LIBRARY_PATH=${stdenv.gcc.libc}/lib
makeFlags="$makeFlags BUILD_LDFLAGS=-Wl,-rpath,${stdenv.gcc.libc}/lib"
${preConfigure}
'';