This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: ld/2218: Weak undefined symbol doesn't work properly with PIE


We should treat global symbols in PIE like shared library. There is
no regression on Linux/x86/x86-64/ia64.


H.J.
----
2006-01-26  H.J. Lu  <hongjiu.lu@intel.com>

	PR ld/2218
	* elflink.c (elf_link_add_object_symbols): Mark global symbol
	in shared library dynamic.

--- bfd/elflink.c.pie	2006-01-25 09:02:12.000000000 -0800
+++ bfd/elflink.c	2006-01-26 21:42:37.000000000 -0800
@@ -4050,7 +4050,7 @@ elf_link_add_object_symbols (bfd *abfd, 
 		}
 	      else
 		h->def_regular = 1;
-	      if (! info->executable
+	      if (info->shared
 		  || h->def_dynamic
 		  || h->ref_dynamic)
 		dynsym = TRUE;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]