diff options
author | Alexandre Oliva <aoliva@redhat.com> | 2003-05-07 05:09:25 +0000 |
---|---|---|
committer | Alexandre Oliva <aoliva@redhat.com> | 2003-05-07 05:09:25 +0000 |
commit | aa701218b758e960355dd24e5494b22d49a2f3a0 (patch) | |
tree | 20aecea570d945f93e1e26d2a5b587dc3349253b /bfd/elfxx-mips.c | |
parent | 21b99e265891743916569aed1a19e02f11e80609 (diff) | |
download | gdb-aa701218b758e960355dd24e5494b22d49a2f3a0.zip gdb-aa701218b758e960355dd24e5494b22d49a2f3a0.tar.gz gdb-aa701218b758e960355dd24e5494b22d49a2f3a0.tar.bz2 |
* elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Improve
error message for mixing different-endian files. Check for ABI
compatibility of input files with the selected emulation.
Diffstat (limited to 'bfd/elfxx-mips.c')
-rw-r--r-- | bfd/elfxx-mips.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/bfd/elfxx-mips.c b/bfd/elfxx-mips.c index 0c3a5d9..c889115 100644 --- a/bfd/elfxx-mips.c +++ b/bfd/elfxx-mips.c @@ -9174,12 +9174,25 @@ _bfd_mips_elf_merge_private_bfd_data (ibfd, obfd) /* Check if we have the same endianess */ if (! _bfd_generic_verify_endian_match (ibfd, obfd)) - return FALSE; + { + (*_bfd_error_handler) + (_("%s: endianness incompatible with that of the selected emulation"), + bfd_archive_filename (ibfd)); + return FALSE; + } if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour || bfd_get_flavour (obfd) != bfd_target_elf_flavour) return TRUE; + if (strcmp (bfd_get_target (ibfd), bfd_get_target (obfd)) != 0) + { + (*_bfd_error_handler) + (_("%s: ABI is incompatible with that of the selected emulation"), + bfd_archive_filename (ibfd)); + return FALSE; + } + new_flags = elf_elfheader (ibfd)->e_flags; elf_elfheader (obfd)->e_flags |= new_flags & EF_MIPS_NOREORDER; old_flags = elf_elfheader (obfd)->e_flags; |