diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2010-05-24 18:09:37 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2010-05-24 18:09:37 +0000 |
commit | af8faf643f9dfe2fc4ef89d7c4aa6df213ecb386 (patch) | |
tree | a726b9964edad1e7a6cfd113c73d6e826e035b35 /gnu/usr.bin | |
parent | f497e7b6095b11027348a018c16049554af08691 (diff) |
Make sure references to hidden symbols are resolved locally and don't go
through the PLT.
Diffstat (limited to 'gnu/usr.bin')
-rw-r--r-- | gnu/usr.bin/binutils/bfd/elf64-sparc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gnu/usr.bin/binutils/bfd/elf64-sparc.c b/gnu/usr.bin/binutils/bfd/elf64-sparc.c index 4568a22d643..90de3b974d5 100644 --- a/gnu/usr.bin/binutils/bfd/elf64-sparc.c +++ b/gnu/usr.bin/binutils/bfd/elf64-sparc.c @@ -1638,7 +1638,11 @@ sparc64_elf_adjust_dynamic_symbol (info, h) || h->root.type == bfd_link_hash_defweak) && (h->root.u.def.section->flags & SEC_CODE) != 0)) { - if (! elf_hash_table (info)->dynamic_sections_created) + if (! info->shared + && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0 + && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0 + && h->root.type != bfd_link_hash_undefweak + && h->root.type != bfd_link_hash_undefined) { /* This case can occur if we saw a WPLT30 reloc in an input file, but none of the input files were dynamic objects. |