_DYNAMIC and _GLOBAL_OFFSET_TABLE_

Ian Lance Taylor ian@airs.com
Mon Sep 8 17:39:00 GMT 2003


Nick Clifton <nickc@redhat.com> writes:

> Hi Ian,  Hi Alan,
> 
>   [Sorry for taking so long to getting around to commenting on this
>   question].
> 
> > Alan Modra writes:
> >
> > Can anyone comment on the history of the following code in elf32-i386.c?
> > 
> >   /* Mark _DYNAMIC and _GLOBAL_OFFSET_TABLE_ as absolute.  */
> >   if (strcmp (h->root.root.string, "_DYNAMIC") == 0
> >       || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
> >     sym->st_shndx = SHN_ABS;
> 
> 
> : Ian Lance Taylor writes:
> :
> : I sure with I still had access to the Cygnus repository.
> 
> For the record, the patch entered the Cygnus repository with this
> ChangeLog entry, which can still be found in bfd/ChangeLog-9495:

Oh yeah, I forgot to follow up.  Whoops.

Basically, as can be seen from the ChangeLog entry, that code went in
when i386 ELF shared library support went in.  In other words, those
symbols have always been SHN_ABS.  As I said earlier, this is probably
because the equivalent Solaris symbols were SHN_ABS.

Ian



More information about the Binutils mailing list