_DYNAMIC and _GLOBAL_OFFSET_TABLE_

Alan Modra amodra@bigpond.net.au
Thu Aug 28 03:40:00 GMT 2003


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;

It's particularly curious given that absolute symbols are relocated
by current glibc ld.so.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre



More information about the Binutils mailing list