* linker.c (link_action): Ignore duplicate warning syms.
[deliverable/binutils-gdb.git] / bfd / elf32-sh.c
index d8d4a6aab4d10803bed7c2775dadb264b132c468..74f276bfb5312a5458008f40a073f82c6ab7bf76 100644 (file)
@@ -3899,8 +3899,8 @@ sh_elf_size_dynamic_sections (output_bfd, info)
      will not fill them in in the relocate_section routine.  */
   if (info->shared && info->symbolic)
     sh_elf_link_hash_traverse (sh_elf_hash_table (info),
-                                sh_elf_discard_copies,
-                                (PTR) NULL);
+                              sh_elf_discard_copies,
+                              (PTR) NULL);
 
   /* The check_relocs and adjust_dynamic_symbol entry points have
      determined the sizes of the various dynamic sections.  Allocate
@@ -4038,6 +4038,9 @@ sh_elf_discard_copies (h, ignore)
 {
   struct elf_sh_pcrel_relocs_copied *s;
 
+  if (h->root.root.type == bfd_link_hash_warning)
+    h = (struct elf_sh_link_hash_entry *) h->root.root.u.i.link;
+
   /* We only discard relocs for symbols defined in a regular object.  */
   if ((h->root.elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
     return true;
This page took 0.033134 seconds and 4 git commands to generate.