aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf.c')
-rw-r--r--bfd/elf.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/bfd/elf.c b/bfd/elf.c
index f434fcf..2f81105 100644
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -3306,6 +3306,9 @@ prep_headers (abfd)
i_ehdrp->e_machine = EM_S370;
break;
case bfd_arch_i386:
+ if (bfd_get_arch_size (abfd) == 64)
+ i_ehdrp->e_machine = EM_X86_64;
+ else
i_ehdrp->e_machine = EM_386;
break;
case bfd_arch_ia64: