aboutsummaryrefslogtreecommitdiff
path: root/bfd
diff options
context:
space:
mode:
authorMichael Meissner <gnu@the-meissners.org>1995-02-14 19:20:16 +0000
committerMichael Meissner <gnu@the-meissners.org>1995-02-14 19:20:16 +0000
commit8c9bfee312ac693df8f1e91d5709c25d38cbd9db (patch)
treef7ee10603949da3e8e11e8f4d942305647fa8cc7 /bfd
parentaed592693fbd9ae2f3771ea38050211230f80b0d (diff)
downloadfsf-binutils-gdb-8c9bfee312ac693df8f1e91d5709c25d38cbd9db.zip
fsf-binutils-gdb-8c9bfee312ac693df8f1e91d5709c25d38cbd9db.tar.gz
fsf-binutils-gdb-8c9bfee312ac693df8f1e91d5709c25d38cbd9db.tar.bz2
Reconize old versions of the PowerPC machine code (EM_PPC_OLD and EM_CYGNUS_POWERPC).
Diffstat (limited to 'bfd')
-rw-r--r--bfd/ChangeLog19
-rw-r--r--bfd/elf32-target.h12
-rw-r--r--bfd/elf64-target.h12
-rw-r--r--bfd/libelf.h4
4 files changed, 45 insertions, 2 deletions
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 47e8c4d..3ae7903 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,3 +1,22 @@
+Tue Feb 14 14:04:22 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * libelf.h (elf_backend_data): Add fields elf_machine_alt1 and
+ elf_machine_alt2 which provide alternate versions of the machine
+ code.
+
+ * elf32-ppc.c (ELF_MACHINE_ALT1, ELF_MACHINE_ALT2): Define to
+ recognize old versions of the PowerPC machine code.
+
+ * elf32-target.h (elf32_bed): Initialize alternate machine code
+ fields defined by ELF_MACHINE_ALT1 and ELF_MACHINE_ALT2.
+
+ * elf64-target.h (elf64_bed): Initialize alternate machine code
+ fields defined by ELF_MACHINE_ALT1 and ELF_MACHINE_ALT2.
+
+ * elfcode.h (elf_object_p, elf_core_file_p): In addition to the
+ main machine code field, check the two alternate machine code
+ fields.
+
Tue Feb 14 12:46:48 1995 Ian Lance Taylor <ian@cygnus.com>
* aoutf1.h (MACHTYPE_OK): Don't define if already defined. Don't
diff --git a/bfd/elf32-target.h b/bfd/elf32-target.h
index c1091f2..b6e4b57 100644
--- a/bfd/elf32-target.h
+++ b/bfd/elf32-target.h
@@ -149,6 +149,14 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#define elf_backend_ecoff_debug_swap 0
#endif
+#ifndef ELF_MACHINE_ALT1
+#define ELF_MACHINE_ALT1 0
+#endif
+
+#ifndef ELF_MACHINE_ALT2
+#define ELF_MACHINE_ALT2 0
+#endif
+
static CONST struct elf_backend_data elf32_bed =
{
#ifdef USE_REL
@@ -182,7 +190,9 @@ static CONST struct elf_backend_data elf32_bed =
elf_backend_finish_dynamic_sections,
elf_backend_begin_write_processing,
elf_backend_final_write_processing,
- elf_backend_ecoff_debug_swap
+ elf_backend_ecoff_debug_swap,
+ ELF_MACHINE_ALT1,
+ ELF_MACHINE_ALT2
};
#ifdef TARGET_BIG_SYM
diff --git a/bfd/elf64-target.h b/bfd/elf64-target.h
index 006d60c..0a8e911 100644
--- a/bfd/elf64-target.h
+++ b/bfd/elf64-target.h
@@ -152,6 +152,14 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
#define elf_backend_ecoff_debug_swap 0
#endif
+#ifndef ELF_MACHINE_ALT1
+#define ELF_MACHINE_ALT1 0
+#endif
+
+#ifndef ELF_MACHINE_ALT2
+#define ELF_MACHINE_ALT2 0
+#endif
+
static CONST struct elf_backend_data elf64_bed =
{
#ifdef USE_REL
@@ -185,7 +193,9 @@ static CONST struct elf_backend_data elf64_bed =
elf_backend_finish_dynamic_sections,
elf_backend_begin_write_processing,
elf_backend_final_write_processing,
- elf_backend_ecoff_debug_swap
+ elf_backend_ecoff_debug_swap,
+ ELF_MACHINE_ALT1,
+ ELF_MACHINE_ALT2
};
#ifdef TARGET_BIG_SYM
diff --git a/bfd/libelf.h b/bfd/libelf.h
index 5fb58c0..1c75f48 100644
--- a/bfd/libelf.h
+++ b/bfd/libelf.h
@@ -399,6 +399,10 @@ struct elf_backend_data
/* The swapping table to use when dealing with ECOFF information.
Used for the MIPS ELF .mdebug section. */
const struct ecoff_debug_swap *elf_backend_ecoff_debug_swap;
+
+ /* Alternate EM_xxxx machine codes for this backend. */
+ int elf_machine_alt1;
+ int elf_machine_alt2;
};
/* Information stored for each BFD section in an ELF file. This