From 073acc8136d1205cea593bc5aad0db9de4c39f8b Mon Sep 17 00:00:00 2001 From: jhibbits Date: Wed, 8 Feb 2017 03:21:29 +0000 Subject: [PATCH] Add elf*-powerpc-freebsd targets to the elftoolchain target list FreeBSD uses the full target triple when generating embedded rootfs images (MFS_IMAGE= make option). Without this change objcopy errors out with: objcopy: elf64-poewrpc-freebsd: invalid target name MFC after: 2 weeks --- .../elftoolchain/libelftc/libelftc_bfdtarget.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c b/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c index 43b9480c321f..e73dc2a947f3 100644 --- a/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c +++ b/contrib/elftoolchain/libelftc/libelftc_bfdtarget.c @@ -126,6 +126,15 @@ struct _Elftc_Bfd_Target _libelftc_targets[] = { .bt_machine = EM_PPC, }, + { + .bt_name = "elf32-powerpc-freebsd", + .bt_type = ETF_ELF, + .bt_byteorder = ELFDATA2MSB, + .bt_elfclass = ELFCLASS32, + .bt_machine = EM_PPC, + .bt_osabi = ELFOSABI_FREEBSD, + }, + { .bt_name = "elf32-powerpcle", .bt_type = ETF_ELF, @@ -289,6 +298,15 @@ struct _Elftc_Bfd_Target _libelftc_targets[] = { .bt_machine = EM_PPC64, }, + { + .bt_name = "elf64-powerpc-freebsd", + .bt_type = ETF_ELF, + .bt_byteorder = ELFDATA2MSB, + .bt_elfclass = ELFCLASS64, + .bt_machine = EM_PPC64, + .bt_osabi = ELFOSABI_FREEBSD, + }, + { .bt_name = "elf64-powerpcle", .bt_type = ETF_ELF,