bfd/
[deliverable/binutils-gdb.git] / bfd / elf-hppa.h
index 5efd808819e385d738368249a80c74f44bbcfed2..f5aba51e55f78f51164b601b604d405ac5b3e07c 100644 (file)
@@ -1118,8 +1118,7 @@ elf_hppa_unmark_useless_dynamic_symbols (struct elf_link_hash_entry *h,
      Ultimately we should have better controls over the generic ELF BFD
      linker code.  */
   if (! info->relocatable
-      && ! (info->shared
-           && info->unresolved_syms_in_shared_libs == RM_IGNORE)
+      && info->unresolved_syms_in_shared_libs != RM_IGNORE
       && h->root.type == bfd_link_hash_undefined
       && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0
       && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0)
@@ -1153,8 +1152,7 @@ elf_hppa_remark_useless_dynamic_symbols (struct elf_link_hash_entry *h,
      Ultimately we should have better controls over the generic ELF BFD
      linker code.  */
   if (! info->relocatable
-      && ! (info->shared
-           && info->unresolved_syms_in_shared_libs == RM_IGNORE)
+      && info->unresolved_syms_in_shared_libs != RM_IGNORE
       && h->root.type == bfd_link_hash_undefined
       && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
       && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0
@@ -1420,16 +1418,9 @@ elf_hppa_relocate_section (bfd *output_bfd,
              else
                relocation = 0;
            }
-         /* Allow undefined symbols in shared libraries.  */
-         else if (info->shared
-                  && info->unresolved_syms_in_shared_libs == RM_IGNORE
+         else if (info->unresolved_syms_in_objects == RM_IGNORE
                   && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
            {
-             if (info->symbolic)
-               (*info->callbacks->undefined_symbol)
-                 (info, h->root.root.string, input_bfd,
-                  input_section, rel->r_offset, FALSE);
-
              /* If this symbol has an entry in the PA64 dynamic hash
                 table, then get it.  */
              dyn_name = get_dyn_name (input_bfd, h, rel,
@@ -1471,7 +1462,9 @@ elf_hppa_relocate_section (bfd *output_bfd,
                {
                  if (!((*info->callbacks->undefined_symbol)
                        (info, h->root.root.string, input_bfd,
-                        input_section, rel->r_offset, TRUE)))
+                        input_section, rel->r_offset,
+                        (info->unresolved_syms_in_objects == RM_GENERATE_ERROR
+                         || ELF_ST_VISIBILITY (h->other)))))
                    return FALSE;
                  break;
                }
This page took 0.025215 seconds and 4 git commands to generate.