This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Make undefined symbols in allocate_dynrelocs dynamic
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Tue, 22 Aug 2017 19:55:03 -0400
- Subject: [binutils-gdb] Make undefined symbols in allocate_dynrelocs dynamic
- Authentication-results: sourceware.org; auth=none
*** TEST RESULTS FOR COMMIT 46434633f9cee98afac1cf945ad00c9d4fdf5a4d ***
Author: Alan Modra <amodra@gmail.com>
Branch: master
Commit: 46434633f9cee98afac1cf945ad00c9d4fdf5a4d
Make undefined symbols in allocate_dynrelocs dynamic
..if they have dynamic relocs. An undefined symbol in a PIC object
that finds no definition ought to become dynamic in order to support
--allow-shlib-undefined, but there is nothing in the generic ELF
linker code to do this if the reference isn't via the GOT or PLT. (An
initialized function pointer is an example.) So it falls to backend
code to ensure the symbol is made dynamic.
PR 21988
* elf64-ppc.c (ensure_undef_dynamic): Rename from
ensure_undefweak_dynamic. Handle undefined too.
* elf32-ppc.c (ensure_undef_dynamic): Likewise.
* elf32-hppa.c (ensure_undef_dynamic): Likewise.
(allocate_dynrelocs): Discard undefined non-default visibility
relocs first. Make undefined syms dynamic. Tidy goto.