From 3a27a730c73e9ad0383ed15eb17d542169d80cdb Mon Sep 17 00:00:00 2001 From: "H.J. Lu" Date: Tue, 23 May 2000 14:05:50 +0000 Subject: 2000-05-23 H.J. Lu * elf32-i386.c (elf_i386_relocate_section): Don't allow the undefined symbol with the non-default visibility attributes. * elf-hppa.h (elf_hppa_relocate_section): Likewise. * elf32-arm.h (elf32_arm_relocate_section): Likewise. * elf32-i370.c (i370_elf_relocate_section): Likewise. * elf32-m68k.c (elf_m68k_relocate_section): Likewise. * elf32-mcore.c (mcore_elf_relocate_section): Likewise. * elf32-mips.c (mips_elf_calculate_relocation): Likewise. * elf32-ppc.c (ppc_elf_relocate_section): Likewise. * elf32-sparc.c (elf32_sparc_relocate_section): Likewise. * elf64-alpha.c (elf64_alpha_relocate_section): Likewise. * elf64-ia64.c (elf64_ia64_relocate_section): Likewise. * elf64-sparc.c (sparc64_elf_relocate_section): Likewise. --- bfd/elf32-ppc.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'bfd/elf32-ppc.c') diff --git a/bfd/elf32-ppc.c b/bfd/elf32-ppc.c index b7e8592..cf83242 100644 --- a/bfd/elf32-ppc.c +++ b/bfd/elf32-ppc.c @@ -3091,7 +3091,9 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section, } else if (h->root.type == bfd_link_hash_undefweak) relocation = 0; - else if (info->shared && !info->symbolic && !info->no_undefined) + else if (info->shared && !info->symbolic + && !info->no_undefined + && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT) relocation = 0; else { @@ -3101,7 +3103,8 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section, input_section, rel->r_offset, (!info->shared - || info->no_undefined))) + || info->no_undefined + ELF_ST_VISIBILITY (h->other)))) return false; relocation = 0; } -- cgit v1.1