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]

Re: mis-elf-as : local/global symbol order in symbol table


Pierre Habraken <Pierre.Habraken@imag.fr> writes:

> The ELF specification states that table all local symbols in a symbol
> should precede all global symbols.
> mips-elf-as (binutils 2.20) disregards this rule.
> Can anyone explain to me the reason for this ?

It's a historical issue.  The SGI Irix 5 assembler did not follow this
rule, and the Irix 5 linker got confused when gas did try to follow
this rule.  As I recall, Irix 5 thought the rule applied to
STT_SECTION symbols rather than to STB_LOCAL symbols.  To work around
this we (or maybe just me) introduced all the elf_bad_symtab code.
Later this was extended to the IRIX_COMPAT and SGI_COMPAT code.  We
can probably straighten out mips-elf-as if we try.

Ian


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