This is the mail archive of the
mailing list for the binutils project.
Issue with BFD and foreign ELF files
- From: "Alexandro Sanchez Bach" <alexaltea123 at gmail dot com>
- To: <binutils at sourceware dot org>
- Date: Sat, 13 May 2017 12:18:42 +0200
- Subject: Issue with BFD and foreign ELF files
- Authentication-results: sourceware.org; auth=none
Not sure if this is the appropriate mailing list as this concerns libbfd.
After opening ARM/MIPS/PPC ELF files (see attachments) via open_bfd(...),
whenever I query bfd_get_arch_info(...) I get bfd_arch_unknown (0) in the
arch and mach fields. Only x86/amd64 works as expected.
libbfd is a dependency (-lbfd) for my project. I installed it via `apt-get
install libbfd-dev` on Ubuntu 16.04, and noticed that there are multiple
"flavors" of BFD at /usr/lib/x86_64-linux-gnu/libbfd-2.26* (*.so, *-arm.so,
*-mips.so, *-system.so, etc.). Is there any way to dynamically load a
version that works with any architecture?
I would be really happy if someone could point me in the right direction.