aboutsummaryrefslogtreecommitdiff
path: root/bfd/coffcode.h
diff options
context:
space:
mode:
authorOmar Majid <omajid@redhat.com>2019-07-23 09:44:57 +0100
committerNick Clifton <nickc@redhat.com>2019-07-23 09:44:57 +0100
commit1dd1bc4daf99ec7ad1f9a6feea8cf4ebe715a92d (patch)
tree968e6d80c069a68fcb0bc8630dd2b67ab14362e3 /bfd/coffcode.h
parent5ba29434765feed692b6342a8b0f853050be2402 (diff)
downloadgdb-1dd1bc4daf99ec7ad1f9a6feea8cf4ebe715a92d.zip
gdb-1dd1bc4daf99ec7ad1f9a6feea8cf4ebe715a92d.tar.gz
gdb-1dd1bc4daf99ec7ad1f9a6feea8cf4ebe715a92d.tar.bz2
Allow objdump to recognise the System.Runtime.dll files that get shipped with .NET Core 2.1.
include * coff/i386.h (IMAGE_FILE_MACHINE_NATIVE_APPLE_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_FREEBSD_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_LINUX_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_NETBSD_OVERRIDE): Define. (I386_APPLE_MAGIC): Define. (I386_FREEBSD_MAGIC): Define. (I386_LINUX_MAGIC): Define. (I386_NETBSD_MAGIC): Define. (I386BADMAG): Extend macro to allow new magic numbers. * coff/x86_64.h (IMAGE_FILE_MACHINE_NATIVE_APPLE_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_FREEBSD_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_LINUX_OVERRIDE): Define. (IMAGE_FILE_MACHINE_NATIVE_NETBSD_OVERRIDE): Define. (AMD64_APPLE_MAGIC): Define. (AMD64_FREEBSD_MAGIC): Define. (AMD64_LINUX_MAGIC): Define. (AMD64_NETBSD_MAGIC): Define. (AMD64BADMAG): Extend macro to allow new magic numbers. bfd * coffcode.h (coff_set_arch_mach_hook): Handle I386_APPLE_MAGIC, I386_FREEBSD_MAGIC, I386_LINUX_MAGIC, I386_NETBSD_MAGIC, AMD64_APPLE_MAGIC, AMD64_FREEBSD_MAGIC, AMD64_LINUX_MAGIC, AMD64_NETBSD_MAGIC. * peXXigen.c: Add comment about source of .NET magic numbers. binutils* Makefile.am (AUTOMAKE_OPTIONS): Add subdir-objects (GENTESTDLLSPROG): Define. (TEST_PROGS): Add GENTESTDLLSPROG. * Makefile.in: Regenerate. * testsuite/binutils-all/objdump.exp (test_objdump_dotnet_assemblies): New proc. Run the new proc. * testsuite/gentestdlls.c: New source file.
Diffstat (limited to 'bfd/coffcode.h')
-rw-r--r--bfd/coffcode.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/bfd/coffcode.h b/bfd/coffcode.h
index c67bfbb..c3f1330 100644
--- a/bfd/coffcode.h
+++ b/bfd/coffcode.h
@@ -2107,11 +2107,19 @@ coff_set_arch_mach_hook (bfd *abfd, void * filehdr)
case I386PTXMAGIC:
case I386AIXMAGIC: /* Danbury PS/2 AIX C Compiler. */
case LYNXCOFFMAGIC:
+ case I386_APPLE_MAGIC:
+ case I386_FREEBSD_MAGIC:
+ case I386_LINUX_MAGIC:
+ case I386_NETBSD_MAGIC:
arch = bfd_arch_i386;
break;
#endif
#ifdef AMD64MAGIC
case AMD64MAGIC:
+ case AMD64_APPLE_MAGIC:
+ case AMD64_FREEBSD_MAGIC:
+ case AMD64_LINUX_MAGIC:
+ case AMD64_NETBSD_MAGIC:
arch = bfd_arch_i386;
machine = bfd_mach_x86_64;
break;