GCC installation problem using crosstool

Andrew Haley aph-gcc@littlepinkcloud.COM
Wed Oct 17 11:42:00 GMT 2007


Aprev writes:
 > 
 > When using Crosstool to setup GCC for ARM (running on x86 linux) I get the
 > following error at the end of the installation:
 > 
 > /temp/crosstool-0.43/build/arm-unknown-linux-gnu/gcc-4.1.0-glibc-2.2.2/binutils-2.16.1/configure
 > --target=arm-unknown-linux-gnu --host=i686-host_pc-linux-gnulibc1
 > --prefix=/opt/crosstool/gcc-4.1.0-glibc-2.2.2/arm-unknown-linux-gnu
 > --disable-nls
 > --with-sysroot=/opt/crosstool/gcc-4.1.0-glibc-2.2.2/arm-unknown-linux-gnu/arm-unknown-linux-gnu
 > creating cache ./config.cache
 > checking host system type... i686-host_pc-linux-gnulibc1
 > checking target system type... arm-unknown-linux-gnu
 > checking build system type... i686-host_pc-linux-gnulibc1
 > checking for a BSD compatible install... /usr/bin/install -c
 > checking whether ln works... yes
 > checking whether ln -s works... yes
 > checking for gcc... gcc
 > checking whether the C compiler (gcc  ) works... no
 > configure: error: installation or configuration problem: C compiler cannot
 > create executables.
 > 
 > ---
 > 
 > The complete log and sh-file is attached to the document. I'm rather new to
 > Linux and am not sure how to interpret the log.
 > 
 > http://www.nabble.com/file/p13249711/log.txt log.txt 
 > http://www.nabble.com/file/p13249711/demo-arm.sh demo-arm.sh 

You don't have a working C compiler on your *host* system!

First, make sure you have gcc installed on your host system.  You OS
has some commands to install packages: on fedora it would be

  yum install gcc

Building a cross compiler is much harder than building a native
compiler.  If I were you I'd first try to build a native compiler from
the same sources, and only then try building for ARM.

Something like  

  <gcc srcdir>/configure
  make

just to make sure that gcc builds.  Once you've done that
successfully, leap into the magical world of crosstool.

Andrew.



More information about the Gcc-help mailing list