• Anthony Martin's avatar
    ld: fix and simplify ELF symbol generation · c5030e5f
    Anthony Martin authored
    I started looking at this code because the nm in GNU
    binutils was ignoring the first symbol in the .symtab
    section.  Apparently, the System V ABI reserves the
    first entry and requires all fields inside to be set
    to zero.
    
    The list of changes is as follows:
    
      · reserve the first symbol entry (as noted above)
      · fix the section indices for .data and .bss symbols
      · factor out common code for Elf32 and Elf64
      · remove the special case for elfsymo in [568]l/asm.c:/^asmb
      · add the "etext" symbol in 6l
      · add static symbols
    
    R=rsc
    CC=golang-dev
    https://golang.org/cl/4524075
    c5030e5f
Name
Last commit
Last update
..
data.c Loading commit data...
doc.go Loading commit data...
dwarf.c Loading commit data...
dwarf.h Loading commit data...
dwarf_defs.h Loading commit data...
elf.c Loading commit data...
elf.h Loading commit data...
go.c Loading commit data...
ldelf.c Loading commit data...
ldmacho.c Loading commit data...
ldpe.c Loading commit data...
lib.c Loading commit data...
lib.h Loading commit data...
macho.c Loading commit data...
macho.h Loading commit data...
pe.c Loading commit data...
pe.h Loading commit data...
symtab.c Loading commit data...