diff options
author | Richard Henderson <rth@redhat.com> | 2001-02-09 00:29:58 +0000 |
---|---|---|
committer | Richard Henderson <rth@redhat.com> | 2001-02-09 00:29:58 +0000 |
commit | 5ecf4de1384c0a27cc1623c8e409c41ddc58495d (patch) | |
tree | 43562855a317dc19ea4efd2ead906c329ce65d0f /bfd/elf64-alpha.c | |
parent | ab916dff8cc9b2089c12f1db2a939ebe332d7e62 (diff) | |
download | gdb-5ecf4de1384c0a27cc1623c8e409c41ddc58495d.tar.gz |
* elf64-alpha.c (alpha_elf_dynamic_symbol_p): Respect weakness
before visibility. Locally defined protected symbols are not
dynamic.
Diffstat (limited to 'bfd/elf64-alpha.c')
-rw-r--r-- | bfd/elf64-alpha.c | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/bfd/elf64-alpha.c b/bfd/elf64-alpha.c index 9808c8f2e31..28f0f4c2948 100644 --- a/bfd/elf64-alpha.c +++ b/bfd/elf64-alpha.c @@ -240,17 +240,24 @@ alpha_elf_dynamic_symbol_p (h, info) if (h->dynindx == -1) return false; + + if (h->root.type == bfd_link_hash_undefweak + || h->root.type == bfd_link_hash_defweak) + return true; + switch (ELF_ST_VISIBILITY (h->other)) { - case STV_INTERNAL: + case STV_DEFAULT: + break; case STV_HIDDEN: + case STV_INTERNAL: return false; + case STV_PROTECTED: + if (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) + return false; + break; } - if (h->root.type == bfd_link_hash_undefweak - || h->root.type == bfd_link_hash_defweak) - return true; - if ((info->shared && !info->symbolic) || ((h->elf_link_hash_flags & (ELF_LINK_HASH_DEF_DYNAMIC | ELF_LINK_HASH_REF_REGULAR)) |