This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Universal Mach-O target for BFD



On Oct 8, 2009, at 10:59 PM, Ryan Govostes wrote:


I noticed that GDB 7, while it supports single-architecture Mach-O files, does not like "universal" (fat) binaries.

I haven't done any hacking on gdb / binutils before, so I'm not sure of the extent of changes that need to be made. I expect it's something like,

1. Add support for universal binaries to BFD.

Eeeh, this is already implemented! Universal binaries are seen as archive. The current implementation
is not complete, but you can do objdump on an universal binaries.


2. Add flags to GDB to select which architecture to extract.

Automatically extracting an architecture from a universal binary is already implemented. GDB does that
to read dylib.


What must do done for gdb (but use gdb mailing list for that) is to select which part to use (either
by adding the --arch option or using some heuristic) but also be sure that the selected part is executed.
Apple gdb use the arch(1) utility for that.


Tristan.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]