* elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
authorMartin Schwidefsky <schwidefsky@de.ibm.com>
Tue, 29 Jan 2002 11:14:35 +0000 (11:14 +0000)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Tue, 29 Jan 2002 11:14:35 +0000 (11:14 +0000)
relocations with PC32 relocations for undefined or weak symbols.
* elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
* elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.

bfd/ChangeLog
bfd/elf32-i386.c
bfd/elf32-s390.c
bfd/elf64-s390.c

index 169118ee63cad098800c9c4a601c35a3b0940273..832bce529e1de36ac4dc1fa3553dff43ff04cb2f 100644 (file)
@@ -1,3 +1,10 @@
+2002-01-29  Martin Schwidefsky  <schwidefsky@de.ibm.com>
+
+       * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
+       relocations with PC32 relocations for undefined or weak symbols.
+       * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
+       * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
+
 2002-01-28  Jason Thorpe  <thorpej@wasabisystems.com>
 
        * elfcore.h (elf_core_file_p): Improve comment for last change.
index 236e167911db87e276d9ca41465910ece8f1c8b8..6e79199e0999364444170adf397d6ade248c57e7 100644 (file)
@@ -1108,7 +1108,9 @@ elf_i386_adjust_dynamic_symbol (info, h)
       if (h->plt.refcount <= 0
          || (! info->shared
              && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0))
+             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
+             && h->root.type != bfd_link_hash_undefweak
+             && h->root.type != bfd_link_hash_undefined))
        {
          /* This case can occur if we saw a PLT32 reloc in an input
             file, but the symbol was never referred to by a dynamic
index e5d07b17d7f0d356d3e66f1ecb526ea6a2943e81..0e7792fb022001b00649980a31d008f36f06819f 100644 (file)
@@ -1047,7 +1047,9 @@ elf_s390_adjust_dynamic_symbol (info, h)
       if (h->plt.refcount <= 0
          || (! info->shared
              && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0))
+             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
+             && h->root.type != bfd_link_hash_undefweak
+             && h->root.type != bfd_link_hash_undefined))
        {
          /* This case can occur if we saw a PLT32 reloc in an input
              file, but the symbol was never referred to by a dynamic
index 51ab444c4479049c04405739e5d69bb3e6d5be83..210e152b05826c3603ba7b8b05a41a8f4a544032 100644 (file)
@@ -1026,7 +1026,9 @@ elf_s390_adjust_dynamic_symbol (info, h)
       if (h->plt.refcount <= 0
          || (! info->shared
              && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
-             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0))
+             && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
+             && h->root.type != bfd_link_hash_undefweak
+             && h->root.type != bfd_link_hash_undefined))
        {
          /* This case can occur if we saw a PLT32 reloc in an input
              file, but the symbol was never referred to by a dynamic
This page took 0.033599 seconds and 4 git commands to generate.