diff options
author | Alan Modra <amodra@gmail.com> | 2023-05-30 12:59:55 +0930 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2023-05-30 12:59:55 +0930 |
commit | 796029320e75a141570220224731c8151311f8d9 (patch) | |
tree | b78438b855ba5505066fe260ff1930f66dd613e6 /binutils | |
parent | 20c52e689ac7ecda11c7002b797868c423f960ee (diff) | |
download | binutils-796029320e75a141570220224731c8151311f8d9.zip binutils-796029320e75a141570220224731c8151311f8d9.tar.gz binutils-796029320e75a141570220224731c8151311f8d9.tar.bz2 |
arm-pe objdump -P
arm-pe looks to be a very old PE implementation, incompatible with
current arm-wince-pe. arm-pe has different relocations and uses
ARMMAGIC which has this comment: "I just made this up". Well, OK, I
don't know the history but it was probably before Microsoft "just made
up" their constants for ARM windows CE.
This patch supports objdump -P for arm-pe, and another magic constant
that may appear in object files. (I don't think binutils generates
files using ARMV7PEMAGIC aka IMAGE_FILE_MACHINE_ARMNT.)
* od-pe.c (is_pe_object_magic): Handle IMAGE_FILE_MACHINE_ARMNT
and ARMMAGIC.
Diffstat (limited to 'binutils')
-rw-r--r-- | binutils/od-pe.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/binutils/od-pe.c b/binutils/od-pe.c index 5f03bd8..5a57a6e 100644 --- a/binutils/od-pe.c +++ b/binutils/od-pe.c @@ -450,6 +450,7 @@ is_pe_object_magic (unsigned short magic) case IMAGE_FILE_MACHINE_ALPHA: case IMAGE_FILE_MACHINE_ARM: case IMAGE_FILE_MACHINE_ARM64: + case IMAGE_FILE_MACHINE_ARMNT: case IMAGE_FILE_MACHINE_I386: case IMAGE_FILE_MACHINE_IA64: case IMAGE_FILE_MACHINE_POWERPC: @@ -457,6 +458,7 @@ is_pe_object_magic (unsigned short magic) case IMAGE_FILE_MACHINE_AMD64: // FIXME: Add more machine numbers. return true; + case 0x0a00: /* ARMMAGIC */ case 0x0500: /* SH_ARCH_MAGIC_BIG */ case 0x0550: /* SH_ARCH_MAGIC_LITTLE */ case 0x0b00: /* MCore */ |