aboutsummaryrefslogtreecommitdiff
path: root/gold/ChangeLog
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2018-11-02 13:04:31 +1030
committerAlan Modra <amodra@gmail.com>2018-11-02 13:58:31 +1030
commit285e3f99c77510344021b1252c594b28fe7971e8 (patch)
treef6b01cd21681d40b0884b44133d210406ad034de /gold/ChangeLog
parenta4bcd733712abd892aa7fe0d79a3f999b461f119 (diff)
downloadgdb-285e3f99c77510344021b1252c594b28fe7971e8.zip
gdb-285e3f99c77510344021b1252c594b28fe7971e8.tar.gz
gdb-285e3f99c77510344021b1252c594b28fe7971e8.tar.bz2
Squash readelf warning on zero sh_link reloc section
On readelf examining a static executable built with current glibc, we get a silly warning. Section Headers: [Nr] Name Type Address Off Size ES Flg Lk Inf Al [ 0] NULL 0000000000000000 000000 000000 00 0 0 0 [ 1] .note.ABI-tag NOTE 0000000000400190 000190 000020 00 A 0 0 4 [ 2] .note.gnu.build-id NOTE 00000000004001b0 0001b0 000024 00 A 0 0 4 readelf: Warning: [ 3]: Link field (0) should index a symtab section. [ 3] .rela.plt RELA 00000000004001d8 0001d8 000228 18 AI 0 20 8 This .rela.plt section contains only IRELATIVE relocations (which have symbol index zero), so it isn't appropriate to warn. A zero sh_link section is deliberately chosen for such a section (see PR10337 and PR23850). So this patch disables the SHT_REL* sh_link warning. I've also removed the .rel.dyn/.rela.dyn section name test to disable the sh_info warning for SHT_REL* sections. While relocation sections in an executable need not specify the section they relocate (the relocation sh_offset field is an address, not a section offset), that isn't true in a relocatable file where sh_offset is relative to a section. If .rela.dyn happens to exist in an ET_REL object it must specify a valid section. * readelf.c (process_section_headers): Don't warn on a zero sh_info or sh_link for any reloc section in an executable or shared library. Do warn for .rel.dyn/.rela.dyn in ET_REL.
Diffstat (limited to 'gold/ChangeLog')
0 files changed, 0 insertions, 0 deletions