From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10466 invoked by alias); 20 Apr 2010 16:07:01 -0000 Received: (qmail 10162 invoked by uid 22791); 20 Apr 2010 16:06:59 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=BAYES_00 X-Spam-Check-By: sourceware.org Received: from wmh1.mail.saunalahti.fi (HELO wmh1.mail.saunalahti.fi) (62.142.5.133) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 20 Apr 2010 16:06:53 +0000 Received: from [192.168.0.20] (dsl-olubrasgw1-ff58c000-204.dhcp.inet.fi [88.192.88.204]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: kai.ruottu@wippies.com) by wmh1.mail.saunalahti.fi (Postfix) with ESMTPSA id DB2751FC068; Tue, 20 Apr 2010 19:06:48 +0300 (EEST) Message-ID: <4BCDD104.1020401@wippies.com> Date: Wed, 21 Apr 2010 13:21:00 -0000 From: Kai Ruottu User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; fi; rv:1.9.1.9) Gecko/20100317 Thunderbird/3.0.4 MIME-Version: 1.0 To: Massimiliano Cialdi CC: gcc-help@gcc.gnu.org Subject: Re: Error compiling arm-elf-gcc-4.5.0 References: <1271753344.7037.15.camel@lab7.powersoft.it> <4BCDB8FD.4050206@wippies.com> <1271777011.7037.58.camel@lab7.powersoft.it> In-Reply-To: <1271777011.7037.58.camel@lab7.powersoft.it> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2010-04/txt/msg00214.txt.bz2 20.4.2010 18:23, Massimiliano Cialdi kirjoitti: > Il giorno mar, 20/04/2010 alle 17.23 +0300, Kai Ruottu ha scritto: >>> I have configured as follows: >>> configure --enable-languages=c,c++ --target=arm-elf --with-gnu-as >>> --with-gnu-ld --prefix=path-to/arm-elf-gcc-4.5.0 >> >> The given $prefix should be some 'absolute' pathname, the default is >> '/usr/local' when no '--prefix=$prefix' is given. Yours is 'relative' >> to some directory. > path-to/arm-elf-gcc-4.5.0 > is only a placeholder, not the true prefix path. > The actual prefix is /usr/local/cross-gcc-arm-elf-4.5.0 > > Yes, I have previously built binutils 2.20.1 for arm target Ok... > when I make all I get the following error: > > Links are now set up to build a cross-compiler > from x86_64-unknown-linux-gnu to arm-unknown-elf. > checking for exported symbols... > path-to/arm-elf-gcc-4.5.0/arm-elf/bin/objdump: conftest: File format not > recognized > checking for -rdynamic... path-to/arm-elf-gcc-4.5.0/arm-elf/bin/objdump: > conftest: File format not recognized Probably the native 'objdump' should be used here, not the 'arm-elf' one... The code in 'gcc/configure' for this seems to be the : -------------------- clip ----------------------------------- pluginlibs= if test x"$enable_plugin" = x"yes"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for exported symbols" >&5 $as_echo_n "checking for exported symbols... " >&6; } echo "int main() {return 0;} int foobar() {return 0;}" > conftest.c ${CC} ${CFLAGS} ${LDFLAGS} conftest.c -o conftest > /dev/null 2>&1 if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then : # No need to use a flag else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -rdynamic" >&5 $as_echo_n "checking for -rdynamic... " >&6; } ${CC} ${CFLAGS} ${LDFLAGS} -rdynamic conftest.c -o conftest > /dev/null 2>&1 if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then pluginlibs="-rdynamic" else enable_plugin=no fi fi -------------------- clip ----------------------------------- The native GCC compiles and links a program and then the executable will be looked with 'objdump'... So my guess is that you have somehow messed your environment :( For instance putting the '$prefix/$target/bin' into your PATH before the '/usr/bin' where the native 'objdump' usually is... Why you would do a weird thing like this, I cannot guess... If some instruction somewhere told to do this, please tell us!