aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorPhil Blundell <philb@gnu.org>2000-11-06 19:38:10 +0000
committerPhil Blundell <philb@gnu.org>2000-11-06 19:38:10 +0000
commitcf919dfdd753416017c8a78dc7271e2a6f77465c (patch)
tree0900b5f05a7d746fa35d25b1374a79d9cb3aefef /bfd
parent704c465c23b5a5be6cb0d1585a8f66016d9130ef (diff)
downloadgdb-cf919dfdd753416017c8a78dc7271e2a6f77465c.zip
gdb-cf919dfdd753416017c8a78dc7271e2a6f77465c.tar.gz
gdb-cf919dfdd753416017c8a78dc7271e2a6f77465c.tar.bz2
2000-11-05 Philip Blundell <philb@gnu.org>
* elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit BFDs containing no sections to be merged, regardless of their flags. 2000-11-04 Philip Blundell <philb@gnu.org> * elf32-arm.h (elf32_arm_relocate_section): Suppress error message if a relocation for an undefined symbol also results in an overflow.
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog11
-rw-r--r--bfd/elf32-arm.h31
2 files changed, 38 insertions, 4 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 9eb0ad8..e661114 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,14 @@
+2000-11-05 Philip Blundell <philb@gnu.org>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Always permit
+ BFDs containing no sections to be merged, regardless of their flags.
+
+2000-11-04 Philip Blundell <philb@gnu.org>
+
+ * elf32-arm.h (elf32_arm_relocate_section): Suppress error message
+ if a relocation for an undefined symbol also results in an
+ overflow.
+
Mon Nov 6 13:35:07 2000 Christopher Faylor <cgf@cygnus.com>
* config.bfd: Add support for Sun Chorus.
diff --git a/bfd/elf32-arm.h b/bfd/elf32-arm.h
index 64c1125..7bd0cce 100644
--- a/bfd/elf32-arm.h
+++ b/bfd/elf32-arm.h
@@ -1907,10 +1907,15 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
switch (r)
{
case bfd_reloc_overflow:
- if (!((*info->callbacks->reloc_overflow)
- (info, name, howto->name, (bfd_vma) 0,
- input_bfd, input_section, rel->r_offset)))
- return false;
+ /* If the overflowing reloc was to an undefined symbol,
+ we have already printed one error message and there
+ is no point complaining again. */
+ if ((! h ||
+ h->root.type != bfd_link_hash_undefined)
+ && (!((*info->callbacks->reloc_overflow)
+ (info, name, howto->name, (bfd_vma) 0,
+ input_bfd, input_section, rel->r_offset))))
+ return false;
break;
case bfd_reloc_undefined:
@@ -2042,6 +2047,8 @@ elf32_arm_merge_private_bfd_data (ibfd, obfd)
flagword out_flags;
flagword in_flags;
boolean flags_compatible = true;
+ boolean null_input_bfd = true;
+ asection *sec;
/* Check if we have the same endianess. */
if (_bfd_generic_verify_endian_match (ibfd, obfd) == false)
@@ -2086,6 +2093,22 @@ elf32_arm_merge_private_bfd_data (ibfd, obfd)
if (in_flags == out_flags)
return true;
+ /* Check to see if the input BFD actually contains any sections.
+ If not, its flags may not have been initialised either, but it cannot
+ actually cause any incompatibility. */
+ for (sec = ibfd->sections; sec != NULL; sec = sec->next)
+ {
+ /* Ignore synthetic glue sections. */
+ if (strcmp (sec->name, ".glue_7")
+ && strcmp (sec->name, ".glue_7t"))
+ {
+ null_input_bfd = false;
+ break;
+ }
+ }
+ if (null_input_bfd)
+ return true;
+
/* Complain about various flag mismatches. */
if (EF_ARM_EABI_VERSION (in_flags) != EF_ARM_EABI_VERSION (out_flags))
{