-   Linux - General (
-   -   Building cross-compiler gcc for powerpc-linux (

ccool 05-19-2004 10:17 AM

Building cross-compiler gcc for powerpc-linux
Hello everyone,

I'm trying to build (compile) gcc "core" to make a cross-development platform. My problem is a compilation error in rs6000/linux.h everytime I try to compile gcc. I'm trying to do this on a standard Slackware 9.1, AMD 2500+.

My steps are
compile binutils- with : "
./configure --prefix=/home/ccool/linuxppc/dev/ --target=powerpc-linux
make install (without any problems)

and then, I make sure that the tools just build here are in my $PATH with:
export PATH=$PATH:/home/ccool/linuxppc/dev/bin
the output of "echo $PATH" seems alright : "/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games:/usr/lib/java/bin:/usr/lib/java/jre/bin:/opt/kde/bin:/usr/lib/qt-3.2.1/bin:/usr/share/texmf/bin:.:/home/ccool/OpenOffice.org1.1.0:/home/ccool/linuxppc/dev/bin "

and then, the fun part begins, I tried theses steps with gcc-3.3.1 and gcc-3.4.0 and gcc-2.95.3
configure with:
gcc-3.4.0/configure --target=powerpc-linux --with-newlib --prefix=/home/ccool/linuxppc/dev/
and then, I make and here is my errors:
/home/ccool/programs/linuxppc/gcc/gcc/xgcc -B/home/ccool/programs/linuxppc/gcc/gcc/ -B/home/ccool/linuxppc/dev//powerpc-linux/bin/ -B/home/ccool/linuxppc/dev//powerpc-linux/lib/ -isystem /home/ccool/linuxppc/dev//powerpc-linux/include -isystem /home/ccool/linuxppc/dev//powerpc-linux/sys-include -O2 -DIN_GCC -DCROSS_COMPILE -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../gcc-3.4.0/gcc -I../gcc-3.4.0/gcc/. -I../gcc-3.4.0/gcc/../include -fPIC -mstrict-align -DL_muldi3 -c ../gcc-3.4.0/gcc/libgcc2.c -o libgcc/./_muldi3.o
In file included from ./tm.h:10,
from ../gcc-3.4.0/gcc/libgcc2.c:43:
../gcc-3.4.0/gcc/config/rs6000/linux.h:100:20: signal.h: No such file or directory
In file included from ./tm.h:10,
from ../gcc-3.4.0/gcc/libgcc2.c:43:
../gcc-3.4.0/gcc/config/rs6000/linux.h:109: error: parse error before "stack_t"
../gcc-3.4.0/gcc/config/rs6000/linux.h:109: warning: no semicolon at end of struct or union
../gcc-3.4.0/gcc/config/rs6000/linux.h:111: error: parse error before "uc_sigmask"
../gcc-3.4.0/gcc/config/rs6000/linux.h:111: warning: type defaults to `int' in declaration of `uc_sigmask'
../gcc-3.4.0/gcc/config/rs6000/linux.h:111: warning: data definition has no type or storage class
../gcc-3.4.0/gcc/config/rs6000/linux.h:110: error: storage size of `uc_mcontext' isn't known
make[2]: *** [libgcc/./_muldi3.o] Error 1
make[2]: Leaving directory `/home/ccool/programs/linuxppc/gcc/gcc'
make[1]: *** [stmp-multilib] Error 2
make[1]: Leaving directory `/home/ccool/programs/linuxppc/gcc/gcc'
make: *** [all-gcc] Error 2


if anyone could help me, or tell me where I should look to find an answer. I googled for a few hours to find different ways to build a cross-compiler and they all have similar ways to do it. I also havent any place where this kind of error appears. Maybe there is some libraries that I need !!

Thanks alot

laceupboots 05-19-2004 02:41 PM

See if this link has your answer

Would be interested in knowing your results with the new gcc 3.4

ccool 05-19-2004 08:04 PM

Thanks for the tip, I might try it, if I ever find the solution, I'll try to post it.

navaneeth 09-17-2004 06:33 AM

how did y solved the signal.h problem in building tool chain for powerpc-linux

All times are GMT -5. The time now is 03:51 AM.