summaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorH.J. Lu <hjl@lucon.org>2001-08-30 15:24:18 +0000
committerH.J. Lu <hjl@lucon.org>2001-08-30 15:24:18 +0000
commite72ebea6d9f998f6edd9ce6ecd70e462072e818d (patch)
tree2fcf6a84498db3028b6368497baf16951f490e4f /bfd
parent29fc7da657700eb8eeb9f64f148b226e99fcecbf (diff)
downloadgdb-e72ebea6d9f998f6edd9ce6ecd70e462072e818d.tar.gz
2001-08-30 H.J. Lu <hjl@gnu.org>
* elf32-mips.c (mips_elf_calculate_relocation): Don't create dynamic relocation for undefined weak symbols when creating executables. Check h->root.root.type, instead of h->root.type.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog6
-rw-r--r--bfd/elf32-mips.c3
2 files changed, 8 insertions, 1 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index dac33c962fd..9bde0aa7645 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,9 @@
+2001-08-30 H.J. Lu <hjl@gnu.org>
+
+ * elf32-mips.c (mips_elf_calculate_relocation): Don't create
+ dynamic relocation for undefined weak symbols when creating
+ executables. Check h->root.root.type, instead of h->root.type.
+
2001-08-29 Joel Sherrill <joel@OARcorp.com>
* config.bfd (i[3456]86-*-rtems*, m68*-*-rtems*): Change
diff --git a/bfd/elf32-mips.c b/bfd/elf32-mips.c
index 1f6ecef2d60..4d224df5d33 100644
--- a/bfd/elf32-mips.c
+++ b/bfd/elf32-mips.c
@@ -6332,7 +6332,8 @@ mips_elf_calculate_relocation (abfd,
if ((info->shared
|| (elf_hash_table (info)->dynamic_sections_created
&& h != NULL
- && (h->root.type == bfd_link_hash_defweak
+ && h->root.root.type != bfd_link_hash_undefweak
+ && (h->root.root.type == bfd_link_hash_defweak
|| (h->root.elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0)))
&& (input_section->flags & SEC_ALLOC) != 0)