Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 05-19-2004, 10:17 AM   #1
Registered: Oct 2002
Location: Canada
Distribution: Slackware 10.1
Posts: 71

Rep: Reputation: 15
Question 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
Old 05-19-2004, 02:41 PM   #2
Registered: Dec 2003
Location: Houston
Distribution: Windows Vista/ XP/ Mepis
Posts: 304

Rep: Reputation: 30
See if this link has your answer

Would be interested in knowing your results with the new gcc 3.4
Old 05-19-2004, 08:04 PM   #3
Registered: Oct 2002
Location: Canada
Distribution: Slackware 10.1
Posts: 71

Original Poster
Rep: Reputation: 15
Thanks for the tip, I might try it, if I ever find the solution, I'll try to post it.
Old 09-17-2004, 06:33 AM   #4
LQ Newbie
Registered: Aug 2004
Location: bangalore
Posts: 2

Rep: Reputation: 0

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


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Error building cross gcc-3.3.2 for i386-mingw32msvc target ugenn Linux - Software 2 10-05-2012 02:33 AM
cross compiler -> ppc_405-gcc marri Programming 0 08-19-2005 08:28 AM
windows to linux cross-compiler back2morrie Linux - General 8 07-13-2005 03:15 AM
help: gcc cross-compiler for m68000 worthij Linux - Software 0 11-09-2004 01:32 PM
Building an ARM7 cross compiler from gcc Charlie_B Linux - Software 2 08-20-2003 08:59 AM

All times are GMT -5. The time now is 11:40 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration