aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog8
-rw-r--r--bfd/elflink.c13
2 files changed, 16 insertions, 5 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 5923bc3..c70a7db 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,13 @@
2014-01-21 H.J. Lu <hongjiu.lu@intel.com>
+ PR ld/16467
+ * elflink.c (_bfd_elf_merge_symbol): When types of the existing
+ regular default symbol definition and the versioned dynamic
+ symbol definition mismatch, skip the default symbol definition
+ if one of them is IFUNC.
+
+2014-01-21 H.J. Lu <hongjiu.lu@intel.com>
+
PR ld/2404
* elflink.c (_bfd_elf_merge_symbol): Don't check info->shared,
info->export_dynamic nor h->ref_dynamic for type mismatch when
diff --git a/bfd/elflink.c b/bfd/elflink.c
index d0006da..792e14e 100644
--- a/bfd/elflink.c
+++ b/bfd/elflink.c
@@ -1092,11 +1092,14 @@ _bfd_elf_merge_symbol (bfd *abfd,
&& newdyn
&& newdef
&& !olddyn
- && (olddef || h->root.type == bfd_link_hash_common)
- && ELF_ST_TYPE (sym->st_info) != h->type
- && ELF_ST_TYPE (sym->st_info) != STT_NOTYPE
- && h->type != STT_NOTYPE
- && !(newfunc && oldfunc))
+ && (((olddef || h->root.type == bfd_link_hash_common)
+ && ELF_ST_TYPE (sym->st_info) != h->type
+ && ELF_ST_TYPE (sym->st_info) != STT_NOTYPE
+ && h->type != STT_NOTYPE
+ && !(newfunc && oldfunc))
+ || (olddef
+ && ((h->type == STT_GNU_IFUNC)
+ != (ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)))))
{
*skip = TRUE;
return TRUE;