[committed, PATCH] Always create dynsym section with dynamic sections
H.J. Lu
hjl.tools@gmail.com
Fri Apr 22 19:29:00 GMT 2016
More information about the Binutils mailing list
Fri Apr 22 19:29:00 GMT 2016
- Previous message (by thread): [committed, PATCH] Always create dynsym section with dynamic sections
- Next message (by thread): [committed, PATCH] Always create dynsym section with dynamic sections
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Fri, Apr 22, 2016 at 11:55 AM, Faraz Shahbazker <faraz.shahbazker@imgtec.com> wrote: > On 04/22/2016 11:11 AM, H.J. Lu wrote: >> https://groups.google.com/d/msg/generic-abi/P9oE0srJtJI/ilktL8KJEQAJ >> >> You need to find a different way to track it. > > My problem is not with the motivation, but the method. ->dynsymcount is > initialized to 1 to account for the NULL symbol when an elf_link_hash_table > is initialized. So while the table remains non-empty, any renumbering must > still account for the NULL symbol, *irrespective* of whether on not dynamic > sections were created. Either that or you move the initial NULL symbol > counting from link_hash_table_init() to link_create_dynamic_sections(). > > This change is causing a two-way dependence between creating a > link_hash_table (an aspect of implementation) and having dynamic sections > in the output (your ABI issue). You want indirectly ensure that the table > is non-empty whenever dynamic sections are created. But do you also need to > ensure that it is empty when dynamic sections are not created? > > Just to be clear, we're talking about the elf_link_hash_table > (implementation), not the dynamic symbol table in the output ELF. The two > may coincide for dynamic ELFs but not necessarily for static ones. > > Please consider: > > + if (dynsymcount != 0 || elf_hash_table (info)->dynamic_sections_created) > + ++dynsymcount; Are you saying dynamic_sections_created is 0 for MIPS here and will become 1 later? -- H.J.
- Previous message (by thread): [committed, PATCH] Always create dynsym section with dynamic sections
- Next message (by thread): [committed, PATCH] Always create dynsym section with dynamic sections
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list