summaryrefslogtreecommitdiffstats
path: root/make
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2003-06-05 02:21:44 +0000
committerEric Andersen <andersen@codepoet.org>2003-06-05 02:21:44 +0000
commitfd9a6c1786d4c247905daa0cd129d0d11ca5fbe6 (patch)
tree7688949906254d6cef68b64e7d5e61cfd90e8847 /make
parentabcac7f79bc1e587ac683a08d4fb16ba070c1b7b (diff)
downloadbuildroot-novena-fd9a6c1786d4c247905daa0cd129d0d11ca5fbe6.tar.gz
buildroot-novena-fd9a6c1786d4c247905daa0cd129d0d11ca5fbe6.zip
Fixup a case where system libs could sneak into the link process
due to collect2 making wrong assumptions.
Diffstat (limited to 'make')
-rw-r--r--make/uclibc_toolchain_2_95.mk7
1 files changed, 7 insertions, 0 deletions
diff --git a/make/uclibc_toolchain_2_95.mk b/make/uclibc_toolchain_2_95.mk
index 987858468..488efbf7e 100644
--- a/make/uclibc_toolchain_2_95.mk
+++ b/make/uclibc_toolchain_2_95.mk
@@ -243,6 +243,13 @@ $(GCC_DIR)/.gcc_build_hacks: $(GCC_DIR)/.patched
perl -i -p -e "s,^#define.*STANDARD_INCLUDE_DIR.*,#define STANDARD_INCLUDE_DIR \
\"$(STAGING_DIR)/include\",;" $(GCC_DIR)/gcc/cppdefault.h;
#
+ # Prevent system glibc libraries from being found by collect2
+ # when it calls locatelib() and rummages about the system looking
+ # for libraries with the correct name...
+ #
+ perl -i -p -e "s,\"/lib/,\"$(STAGING_DIR)/lib,g;" $(GCC_DIR)/gcc/collect2.c
+ perl -i -p -e "s,\"/usr/,\"$(STAGING_DIR)/usr/,g;" $(GCC_DIR)/gcc/collect2.c
+ #
# Prevent gcc from using the unwind-dw2-fde-glibc code
#
perl -i -p -e "s,^#ifndef inhibit_libc,#define inhibit_libc\n\