[libbfd] Mach-O format support ?

mpsuzuki@hiroshima-u.ac.jp mpsuzuki@hiroshima-u.ac.jp
Wed Apr 14 08:40:00 GMT 2010


Hi,

How about "nm" for universal binary?

If I execute "nm" of latest binutils (downloaded from CVS)
and try for universal binary archive (/usr/lib/libwrap.a)
on Mac OS X, "nm" complains as:

$ ./nm-new /usr/lib/libwrap.a 
./nm-new: /usr/lib/libwrap.a:i386: File format not recognized
./nm-new: /usr/lib/libwrap.a:powerpc:common: File format not recognized

Nothing to say, "objdump -f" works well as you replied.

Regards,
mpsuzuki

On Wed, 14 Apr 2010 10:27:31 +0200
Tristan Gingold <gingold@adacore.com> wrote:
>On Apr 14, 2010, at 10:07 AM, Emmanuel Fleury wrote:
>> So, what I suspect is just that libbfd does not handle this 'multi-arch'
>> packaging feature that seems to be supported in Mach-O.
>> 
>> Is it right ?
>
>No, this works for me, using the current head (should also work with 2.21):
>
>$ ./binutils/objdump -f /bin/ls 
>In archive /bin/ls:
>
>/bin/ls:i386:x86-64:     file format mach-o-x86-64
>architecture: i386:x86-64, flags 0x00000012:
>EXEC_P, HAS_SYMS
>start address 0x0000000100001478
>
>
>/bin/ls:i386:     file format mach-o-i386
>architecture: i386, flags 0x00000012:
>EXEC_P, HAS_SYMS
>start address 0x00001a60
>
>Tristan.
>



More information about the Binutils mailing list