diff options
Diffstat (limited to 'bfd/elf32-i386.c')
-rw-r--r-- | bfd/elf32-i386.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/bfd/elf32-i386.c b/bfd/elf32-i386.c index 98902ac..3063bed 100644 --- a/bfd/elf32-i386.c +++ b/bfd/elf32-i386.c @@ -1576,6 +1576,10 @@ elf_i386_check_relocs (bfd *abfd, /* It is referenced by a non-shared object. */ h->ref_regular = 1; h->root.non_ir_ref = 1; + + if (h->type == STT_GNU_IFUNC) + elf_tdata (info->output_bfd)->has_gnu_symbols + |= elf_gnu_symbol_ifunc; } if (! elf_i386_tls_transition (info, abfd, sec, NULL, @@ -5330,11 +5334,11 @@ elf_i386_add_symbol_hook (bfd * abfd, asection ** secp ATTRIBUTE_UNUSED, bfd_vma * valp ATTRIBUTE_UNUSED) { - if ((ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC - || ELF_ST_BIND (sym->st_info) == STB_GNU_UNIQUE) + if (ELF_ST_BIND (sym->st_info) == STB_GNU_UNIQUE && (abfd->flags & DYNAMIC) == 0 && bfd_get_flavour (info->output_bfd) == bfd_target_elf_flavour) - elf_tdata (info->output_bfd)->has_gnu_symbols = TRUE; + elf_tdata (info->output_bfd)->has_gnu_symbols + |= elf_gnu_symbol_unique; return TRUE; } |