mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-28 15:18:37 +08:00
2008-03-02 H.J. Lu <hongjiu.lu@intel.com>
PR ld/5789 * elflink.c (_bfd_elf_symbol_refs_local_p): Always return true for hidden and local symbols.
This commit is contained in:
@ -1,3 +1,9 @@
|
|||||||
|
2008-03-02 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
PR ld/5789
|
||||||
|
* elflink.c (_bfd_elf_symbol_refs_local_p): Always return true
|
||||||
|
for hidden and local symbols.
|
||||||
|
|
||||||
2008-03-03 Alan Modra <amodra@bigpond.net.au>
|
2008-03-03 Alan Modra <amodra@bigpond.net.au>
|
||||||
|
|
||||||
* elf32-ppc.c (allocate_dynrelocs): Discard relocs on
|
* elf32-ppc.c (allocate_dynrelocs): Discard relocs on
|
||||||
|
@ -2789,6 +2789,11 @@ _bfd_elf_symbol_refs_local_p (struct elf_link_hash_entry *h,
|
|||||||
if (h == NULL)
|
if (h == NULL)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
|
/* STV_HIDDEN or STV_INTERNAL ones must be local. */
|
||||||
|
if (ELF_ST_VISIBILITY (h->other) == STV_HIDDEN
|
||||||
|
|| ELF_ST_VISIBILITY (h->other) == STV_INTERNAL)
|
||||||
|
return TRUE;
|
||||||
|
|
||||||
/* Common symbols that become definitions don't get the DEF_REGULAR
|
/* Common symbols that become definitions don't get the DEF_REGULAR
|
||||||
flag set, so test it first, and don't bail out. */
|
flag set, so test it first, and don't bail out. */
|
||||||
if (ELF_COMMON_DEF_P (h))
|
if (ELF_COMMON_DEF_P (h))
|
||||||
@ -2817,10 +2822,6 @@ _bfd_elf_symbol_refs_local_p (struct elf_link_hash_entry *h,
|
|||||||
if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
|
if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
/* However, STV_HIDDEN or STV_INTERNAL ones must be local. */
|
|
||||||
if (ELF_ST_VISIBILITY (h->other) != STV_PROTECTED)
|
|
||||||
return TRUE;
|
|
||||||
|
|
||||||
hash_table = elf_hash_table (info);
|
hash_table = elf_hash_table (info);
|
||||||
if (!is_elf_hash_table (hash_table))
|
if (!is_elf_hash_table (hash_table))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
Reference in New Issue
Block a user