This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

building cross compiler fails for target powerpc-linux-gnuspe


Hi,

I'm trying to build a gcc cross compiler for target powerpc-linux-gnuspe.
The binutils bulds without any problem but I'm not sure why building gcc
fails.

There is a description at http://gcc.gnu.org/install/download.html :
> If you also intend to build binutils (either to upgrade an existing
> installation or for use in place of the corresponding tools of your OS),
> unpack the binutils distribution either in the same directory or a
> separate one. In the latter case, add symbolic links to any components
> of the binutils you intend to build alongside the compiler (bfd, binutils,
> gas, gprof, ld, opcodes, ...) to the directory containing the GCC sources.

Let's take an example: I downloaded binutils-2.20.tar.bz2 and
gcc-core-4.4.2.tar.bz2. Then I did:

$ tar xjvRf gcc-core-4.4.2.tar.bz2
$ cd gcc-4.4.2
$ tar xjvRf ../binutils-2.20.tar.bz2
$ ln -s binutils-2.20 binutils
$ cd ..
$ mkdir gcc-build
$ cd gcc-build
$ ../gcc-4.4.2/configure --target=powerpc-linux-gnuspe --prefix=/home/nmarci/usr/local/gcc --disable-shared --disable-threads --enable-languages=c
$ make

When executing this procedure the build fails with:

checking for powerpc-linux-gnuspe-gcc... /usr/src/gcc-build/./gcc/xgcc -B/usr/src/gcc-build/./gcc/ -B/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/bin/
-B/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/lib/ -isystem /home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/include -isystem
/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/sys-include
checking for suffix of object files... configure: error: in `/usr/src/gcc-build/powerpc-linux-gnuspe/libgcc':
configure: error: cannot compute suffix of object files: cannot compile
See `config.log' for more details.
make[1]: *** [configure-target-libgcc] Error 1
make[1]: Leaving directory `/usr/src/gcc-build'
make: *** [all] Error 2

In the file powerpc-linux-gnuspe/libgcc/config.log I can find the following
messages:

configure:2393: /usr/src/gcc-build/./gcc/xgcc -B/usr/src/gcc-build/./gcc/ -B/home/nmarci/usr/local/gcc/powerpc-lin
ux-gnuspe/bin/ -B/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/lib/ -isystem /home/nmarci/usr/local/gcc/powerpc-
linux-gnuspe/include -isystem /home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/sys-include -V </dev/null >&5
xgcc: '-V' must come at the start of the command line
configure:2396: $? = 1
configure:2415: /usr/src/gcc-build/./gcc/xgcc -B/usr/src/gcc-build/./gcc/ -B/home/nmarci/usr/local/gcc/powerpc-lin
ux-gnuspe/bin/ -B/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/lib/ -isystem /home/nmarci/usr/local/gcc/powerpc-
linux-gnuspe/include -isystem /home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/sys-include -o conftest -g -O2     c
onftest.c  >&5
/usr/src/gcc-build/./gcc/as: line 76: exec: : not found
configure:2418: $? = 1
configure:2590: checking for suffix of object files
configure:2611: /usr/src/gcc-build/./gcc/xgcc -B/usr/src/gcc-build/./gcc/ -B/home/nmarci/usr/local/gcc/powerpc-lin
ux-gnuspe/bin/ -B/home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/lib/ -isystem /home/nmarci/usr/local/gcc/powerpc-
linux-gnuspe/include -isystem /home/nmarci/usr/local/gcc/powerpc-linux-gnuspe/sys-include -c -g -O2    conftest.c
>&5
/usr/src/gcc-build/./gcc/as: line 76: exec: : not found
configure:2614: $? = 1

It seems that the script gcc/as tries to execute an empty string. In gcc/as I can
see that ORIGINAL_AS_FOR_TARGET="".

So what's wrong with the procedure?

Regards,

	MÃrton NÃmeth


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]