summaryrefslogtreecommitdiffstats
path: root/sources/binutils-012_check_ldrunpath_length.patch
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2003-08-22 12:47:39 +0000
committerEric Andersen <andersen@codepoet.org>2003-08-22 12:47:39 +0000
commit541ecb8d06fe2f1808606fa3ed8f46a285b4922d (patch)
treed5982e7f9a3479d26ca894bef19bb56f8a50e57c /sources/binutils-012_check_ldrunpath_length.patch
parent772128bd40162c51a7a7f6fe7074660fdc83a48d (diff)
downloadbuildroot-novena-541ecb8d06fe2f1808606fa3ed8f46a285b4922d.tar.gz
buildroot-novena-541ecb8d06fe2f1808606fa3ed8f46a285b4922d.zip
Make binutils not leak libraries
Diffstat (limited to 'sources/binutils-012_check_ldrunpath_length.patch')
-rw-r--r--sources/binutils-012_check_ldrunpath_length.patch21
1 files changed, 21 insertions, 0 deletions
diff --git a/sources/binutils-012_check_ldrunpath_length.patch b/sources/binutils-012_check_ldrunpath_length.patch
new file mode 100644
index 000000000..5aa09abef
--- /dev/null
+++ b/sources/binutils-012_check_ldrunpath_length.patch
@@ -0,0 +1,21 @@
+diff -urN binutils-2.12.90.0.12/ld/emultempl/elf32.em binutils-2.12.90.0.12.new/ld/emultempl/elf32.em
+--- binutils-2.12.90.0.12/ld/emultempl/elf32.em Wed Jun 19 00:41:59 2002
++++ binutils-2.12.90.0.12.new/ld/emultempl/elf32.em Wed Jun 26 10:00:26 2002
+@@ -672,6 +672,8 @@
+ && command_line.rpath == NULL)
+ {
+ lib_path = (const char *) getenv ("LD_RUN_PATH");
++ if ((lib_path) && (strlen (lib_path) == 0))
++ lib_path = NULL;
+ if (gld${EMULATION_NAME}_search_needed (lib_path, l->name,
+ force))
+ break;
+@@ -867,6 +869,8 @@
+ rpath = command_line.rpath;
+ if (rpath == NULL)
+ rpath = (const char *) getenv ("LD_RUN_PATH");
++ if ((rpath) && (strlen (rpath) == 0))
++ rpath = NULL;
+ if (! (bfd_elf${ELFSIZE}_size_dynamic_sections
+ (output_bfd, command_line.soname, rpath,
+ command_line.filter_shlib,