From: Will Newton Date: Wed, 27 Mar 2013 09:48:46 +0000 (+0000) Subject: bfd/ChangeLog: X-Git-Tag: sid-snapshot-20130401~53 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=319438823faf122665c28991f1e2ef5718458d69;p=external%2Fbinutils.git bfd/ChangeLog: 2013-03-20 Will Newton * elf32-arm.c (elf32_arm_final_link_relocate): Avoid emitting a dynamic reloc for symbols with dynindx == -1. (allocate_dynrelocs_for_symbol): Avoid allocating space for a dynamic reloc for symbols with dynindx == -1. --- diff --git a/bfd/ChangeLog b/bfd/ChangeLog index e6e6c77..47f757d 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,10 @@ +2013-03-27 Will Newton + + * elf32-arm.c (elf32_arm_final_link_relocate): Avoid emitting a + dynamic reloc for non-default visibility undefined weaks. + (allocate_dynrelocs_for_symbol): Avoid allocating space for a + dynamic reloc for non-default visibility undefined weaks. + 2013-03-26 Alan Modra * elflink.c (_bfd_elf_add_default_symbol): Preserve section diff --git a/bfd/elf32-arm.c b/bfd/elf32-arm.c index 78c2d1d..ec33916 100644 --- a/bfd/elf32-arm.c +++ b/bfd/elf32-arm.c @@ -9158,7 +9158,9 @@ elf32_arm_final_link_relocate (reloc_howto_type * howto, { if (dynreloc_st_type == STT_GNU_IFUNC) outrel.r_info = ELF32_R_INFO (0, R_ARM_IRELATIVE); - else if (info->shared) + else if (info->shared && + (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT + || h->root.type != bfd_link_hash_undefweak)) outrel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE); else outrel.r_info = 0; @@ -13284,7 +13286,8 @@ allocate_dynrelocs_for_symbol (struct elf_link_hash_entry *h, void * inf) they all resolve dynamically instead. Reserve room for the GOT entry's R_ARM_IRELATIVE relocation. */ elf32_arm_allocate_irelocs (info, htab->root.srelgot, 1); - else if (info->shared) + else if (info->shared && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT + || h->root.type != bfd_link_hash_undefweak)) /* Reserve room for the GOT entry's R_ARM_RELATIVE relocation. */ elf32_arm_allocate_dynrelocs (info, htab->root.srelgot, 1); }