* Debugging 32/64 bit binaries on os/x 10.7 with cvs gdb?
@ 2011-11-29 20:33 Robert Lupton the Good
2011-11-30 7:47 ` Tristan Gingold
0 siblings, 1 reply; 2+ messages in thread
From: Robert Lupton the Good @ 2011-11-29 20:33 UTC (permalink / raw)
To: gdb
If I build gdb from source on os/x 10.7 and attempt to debug python (a 32/64 bit binary), gdb says;
> $ ~/Src/gnu/gdb/gdb /usr/bin/python
> GNU gdb (GDB) 7.3.50.20111109-cvs
> Copyright (C) 2011 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "x86_64-apple-darwin11.2.0".
> For bug reporting instructions, please see:
> <http://www.gnu.org/software/gdb/bugs/>...
> "/usr/bin/python": not in executable format: File format not recognized
> (gdb) quit
> $ file !$
> file /usr/bin/python
> /usr/bin/python: Mach-O universal binary with 2 architectures
> /usr/bin/python (for architecture x86_64): Mach-O 64-bit executable x86_64
> /usr/bin/python (for architecture i386): Mach-O executable i386
Is there a way to build gdb to work around this?
R
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Debugging 32/64 bit binaries on os/x 10.7 with cvs gdb?
2011-11-29 20:33 Debugging 32/64 bit binaries on os/x 10.7 with cvs gdb? Robert Lupton the Good
@ 2011-11-30 7:47 ` Tristan Gingold
0 siblings, 0 replies; 2+ messages in thread
From: Tristan Gingold @ 2011-11-30 7:47 UTC (permalink / raw)
To: Robert Lupton the Good; +Cc: gdb
On Nov 29, 2011, at 9:32 PM, Robert Lupton the Good wrote:
> If I build gdb from source on os/x 10.7 and attempt to debug python (a 32/64 bit binary), gdb says;
>
>> $ ~/Src/gnu/gdb/gdb /usr/bin/python
>> GNU gdb (GDB) 7.3.50.20111109-cvs
>> Copyright (C) 2011 Free Software Foundation, Inc.
>> License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
>> This is free software: you are free to change and redistribute it.
>> There is NO WARRANTY, to the extent permitted by law. Type "show copying"
>> and "show warranty" for details.
>> This GDB was configured as "x86_64-apple-darwin11.2.0".
>> For bug reporting instructions, please see:
>> <http://www.gnu.org/software/gdb/bugs/>...
>> "/usr/bin/python": not in executable format: File format not recognized
>> (gdb) quit
>> $ file !$
>> file /usr/bin/python
>> /usr/bin/python: Mach-O universal binary with 2 architectures
>> /usr/bin/python (for architecture x86_64): Mach-O 64-bit executable x86_64
>> /usr/bin/python (for architecture i386): Mach-O executable i386
>
> Is there a way to build gdb to work around this?
No. Currently gdb is not able to debug fat binary. Use lipo to extract the architecture you want to use.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-11-30 7:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-29 20:33 Debugging 32/64 bit binaries on os/x 10.7 with cvs gdb? Robert Lupton the Good
2011-11-30 7:47 ` Tristan Gingold
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).