Updating to allow ld-linux.so.? interpreters, instead of always .so.2
svn path=/nixpkgs/trunk/; revision=16465
This commit is contained in:
parent
83116e4b8c
commit
dcf0a95a72
@ -10,15 +10,17 @@ echo Patching the bootstrap tools...
|
|||||||
|
|
||||||
# On x86_64, ld-linux-x86-64.so.2 barfs on patchelf'ed programs. So
|
# On x86_64, ld-linux-x86-64.so.2 barfs on patchelf'ed programs. So
|
||||||
# use a copy of patchelf.
|
# use a copy of patchelf.
|
||||||
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.2 $out/bin/cp $out/bin/patchelf .
|
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? $out/bin/cp $out/bin/patchelf .
|
||||||
|
|
||||||
|
set +e
|
||||||
for i in $out/bin/* $out/libexec/gcc/*/*/*; do
|
for i in $out/bin/* $out/libexec/gcc/*/*/*; do
|
||||||
echo patching $i
|
echo patching $i
|
||||||
if ! test -L $i; then
|
if ! test -L $i; then
|
||||||
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.2 \
|
LD_LIBRARY_PATH=$out/lib $out/lib/ld-linux*.so.? \
|
||||||
./patchelf --set-interpreter $out/lib/ld-linux*.so.2 --set-rpath $out/lib --force-rpath $i
|
./patchelf --set-interpreter $out/lib/ld-linux*.so.? --set-rpath $out/lib --force-rpath $i
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
set -e
|
||||||
|
|
||||||
# Fix the libc linker script.
|
# Fix the libc linker script.
|
||||||
export PATH=$out/bin
|
export PATH=$out/bin
|
||||||
|
Loading…
x
Reference in New Issue
Block a user