PATCH: Fix ELF arrays

Carlos O'Donell carlos@systemhalted.org
Fri Jul 15 01:56:00 GMT 2005
On Thu, Jul 14, 2005 at 10:21:52AM -0700, H. J. Lu wrote:
> On Thu, Jul 14, 2005 at 10:06:07AM -0700, H. J. Lu wrote:
> > On Thu, Jul 14, 2005 at 07:44:02AM -0700, H. J. Lu wrote:
> > 
> > > _bfd_elf_provide_section_bound_symbols should be called at least
> > > once after lang_size_sections. Otherwise, the section size will be
> > > zero.
> > > 
> > > 
> > 
> > On Linux, only ia64 uses ELF arrays. People may not see the problems
> > with ELF arrays. I checked in this patch to test them on all ELF
> > targets. They may fail if the system C library doesn't support ELF
> > arrays.
> > 
> > 
> 
> This patch fixes ELF arrays and restore the patch for
> 
> http://sourceware.org/ml/binutils/2005-04/msg00660.html:
> 
> 
> H.J.
> ----
> bfd/
> 
> 2005-07-14  H.J. Lu  <hongjiu.lu@intel.com>
> 
> 	* elflink.c (_bfd_elf_provide_section_bound_symbols): Redefine
> 	the symbol if it is relative to the same section and its value
> 	is 0.
> 
> ld/
> 
> 2005-07-14  H.J. Lu  <hongjiu.lu@intel.com>
> 
> 	* emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Set to the
> 	provide_section_symbols field to NULL.
> 	* emultempl/armcoff.em: Likewise.
> 	* emultempl/beos.em: Likewise.
> 	* emultempl/generic.em: Likewise.
> 	* emultempl/gld960.em: Likewise.
> 	* emultempl/gld960c.em: Likewise.
> 	* emultempl/linux.em: Likewise.
> 	* emultempl/lnk960.em: Likewise.
> 	* emultempl/m68kcoff.em: Likewise.
> 	* emultempl/pe.em: Likewise.
> 	* emultempl/sunos.em: Likewise.
> 	* emultempl/ticoff.em: Likewise.
> 	* emultempl/vanilla.em: Likewise.
> 
> 	* emultempl/elf32.em (gld${EMULATION_NAME}_provide_init_fini_syms):
> 	Renamd to ...
> 	(gld${EMULATION_NAME}_provide_section_symbols): This.
> 
> 	* ldemul.c (ldemul_provide_section_symbols): New.
> 
> 	* ldemul.h (ldemul_provide_section_symbols): New.
> 	(ld_emulation_xfer_struct): Add the provide_section_symbols
> 	field.
> 
> 	* ldlang.c (lang_process): Call ldemul_provide_section_symbols
> 	after lang_size_sections.
> 

Whichever version was checked into cvs fixes the extra R_PARISC_NONE
relocs for hppa. Thanks.

c.



More information about the Binutils mailing list