bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: nm x86 bug when configured for linux and solaris


From: Alan Modra
Subject: Re: nm x86 bug when configured for linux and solaris
Date: Fri, 21 May 2010 15:45:17 +0930
User-agent: Mutt/1.5.20 (2009-06-14)

On Mon, May 10, 2010 at 05:19:44PM +0100, Duncan Simpson wrote:
> I configured binutils with
> $../binutils/src/configure -C --prefix=/usr --enable-shared --enable-gold 
> --with-sysroot=/ --enable-lto 
> --enable-targets=x86_64-unknown-linux-gnu,i686-unknown-linux-gnu,i686-sun-solaris2
> 
> and the built version nm says
> $./nm-new --help says
> <usage and options snipped>
> supported targets: elf64-x86-64 elf32-i386 a.out-i386-linux pei-i386 
> pei-x86-64 elf64-l1om elf64-little elf64-big elf32-little elf32-big 
> elf32-i386-sol2 coff-i386 elf64-x86-64-sol2 srec symbolsrec verilog tekhex 
> binary ihex
> $./nm-new /solaris/bin/ls
> ./.libs/lt-nm-new: /solaris/bin/ls: File format is ambiguous
> ./.libs/lt-nm-new: Matching formats: elf32-i386 elf32-i386-sol2
> 
> This is suboptimal behaviour IMHO particular because the output of nm
> is the same for both formats.

Agreed.  The easy solution is to choose one of these two targets as
the default, in this case it's preferable to choose elf32-i386.  So
add --target=i686-unknown-linux-gnu to your configure line.  I'm
assuming here that you're on an x86_64 linux box.

-- 
Alan Modra
Australia Development Lab, IBM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]