Linker generating incorrect sh_info values for .dynsym section
Alan Modra
amodra@gmail.com
Fri Aug 12 14:44:00 GMT 2016
On Fri, Aug 12, 2016 at 10:37:40PM +0930, Alan Modra wrote:
> On Fri, Aug 12, 2016 at 12:58:56PM +0100, Nick Clifton wrote:
> > It appears that the linker is generating incorrect values for the
> > sh_info field of the .dynsym section.
>
> Should be fixed with the following. As yet untested.
Tested and committed along with the inevitable testsuite update.
bfd/
* elf-bfd.h (struct elf_link_hash_table): Add local_dynsymcount.
* elflink.c (_bfd_elf_link_renumber_dynsyms): Set local_dynsymcount.
(bfd_elf_final_link): Set .dynsym sh_info from local_dynsymcount.
ld/
* testsuite/ld-tic6x/shlib-1.rd: Correct expected .dynsym sh_info.
* testsuite/ld-tic6x/shlib-1b.rd: Likewise.
* testsuite/ld-tic6x/shlib-1r.rd: Likewise.
* testsuite/ld-tic6x/shlib-1rb.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1b.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1r.rd: Likewise.
* testsuite/ld-tic6x/shlib-app-1rb.rd: Likewise.
* testsuite/ld-tic6x/shlib-noindex.rd: Likewise.
* testsuite/ld-tic6x/static-app-1.rd: Likewise.
* testsuite/ld-tic6x/static-app-1b.rd: Likewise.
* testsuite/ld-tic6x/static-app-1r.rd: Likewise.
* testsuite/ld-tic6x/static-app-1rb.rd: Likewise.
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list