diff options
author | Alan Modra <amodra@gmail.com> | 2003-05-17 06:16:03 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2003-05-17 06:16:03 +0000 |
commit | 9c7a29a32e738b51793f7f2bcaa4b403373b478c (patch) | |
tree | a925e4ef543194e6e886f4cb4ba54819d59cb067 /bfd/elflink.c | |
parent | b8b527c5a96aec839f5c8122ffd08556f7fe0d9f (diff) | |
download | gdb-9c7a29a32e738b51793f7f2bcaa4b403373b478c.zip gdb-9c7a29a32e738b51793f7f2bcaa4b403373b478c.tar.gz gdb-9c7a29a32e738b51793f7f2bcaa4b403373b478c.tar.bz2 |
* elf32-i386.c (elf_i386_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
to trim plt entries. Move undefweak non-default visibility test..
(allocate_dynrelocs): ..from here.
* elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't test
dynamic_sections_created here. Update comment. Move undefweak
non-default visibility test..
(allocate_dynrelocs): ..from here. Fix comment.
* elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
to trim plt entries. Move undefweak non-default visibility test..
(allocate_dynrelocs): ..from here. Fix comment.
* elflink.h (elf_link_output_extsym): Compare ELF_ST_VISIBILITY with
STV_DEFAULT rather than comparing with zero.
* elflink.c (_bfd_elf_merge_symbol): Likewise.
(_bfd_elf_fix_symbol_flags): Likewise. Format comment.
Diffstat (limited to 'bfd/elflink.c')
-rw-r--r-- | bfd/elflink.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/bfd/elflink.c b/bfd/elflink.c index bb5361e..3b0d353 100644 --- a/bfd/elflink.c +++ b/bfd/elflink.c @@ -855,7 +855,7 @@ _bfd_elf_merge_symbol (abfd, info, name, sym, psec, pvalue, sym_hash, skip, /* If the old symbol has non-default visibility, we ignore the new definition from a dynamic object. */ if (newdyn - && ELF_ST_VISIBILITY (h->other) + && ELF_ST_VISIBILITY (h->other) != STV_DEFAULT && !bfd_is_und_section (sec)) { *skip = TRUE; @@ -871,7 +871,7 @@ _bfd_elf_merge_symbol (abfd, info, name, sym, psec, pvalue, sym_hash, skip, return TRUE; } else if (!newdyn - && ELF_ST_VISIBILITY (sym->st_other) + && ELF_ST_VISIBILITY (sym->st_other) != STV_DEFAULT && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0) { /* If the new symbol with non-default visibility comes from a @@ -2427,8 +2427,8 @@ _bfd_elf_fix_symbol_flags (h, eif) /* If -Bsymbolic was used (which means to bind references to global symbols to the definition within the shared object), and this symbol was defined in a regular object, then it actually doesn't - need a PLT entry. Likewise, if the symbol has non-default - visibility. If the symbol has hidden or internal visibility, we + need a PLT entry. Likewise, if the symbol has non-default + visibility. If the symbol has hidden or internal visibility, we will force it local. */ if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0 && eif->info->shared @@ -2449,7 +2449,7 @@ _bfd_elf_fix_symbol_flags (h, eif) /* If a weak undefined symbol has non-default visibility, we also hide it from the dynamic linker. */ - if (ELF_ST_VISIBILITY (h->other) + if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT && h->root.type == bfd_link_hash_undefweak) { struct elf_backend_data *bed; |