When trying to cross compile a stage1 (I believe that is the correct terminology) compiler I get the following error.
--- /home/tony/buildall/ia64/gcc0/./gcc/xgcc -B/home/tony/buildall/ia64/gcc0/./gcc/ -B/opt/cross/gcc-4.4.4-nolibc/ia64-linux//ia64-linux/bin/ -B/opt/cross/gcc-4.4.4-nolibc/ia64-linux//ia64-linux/lib/ -isystem /opt/cross/gcc-4.4.4-nolibc/ia64-linux//ia64-linux/include -isystem /opt/cross/gcc-4.4.4-nolibc/ia64-linux//ia64-linux/sys-include -g -O2 -O2 -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -DUSE_LIBUNWIND_EXCEPTIONS -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wcast-qual -Wold-style-definition -isystem ./include -fPIC -DUSE_GAS_SYMVER -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../.././gcc -I/home/tony/buildall/src/gcc/libgcc -I/home/tony/buildall/src/gcc/libgcc/. -I/home/tony/buildall/src/gcc/libgcc/../gcc -I/home/tony/buildall/src/gcc/libgcc/../include -DHAVE_CC_TLS -o unwind-c.o -MT unwind-c.o -MD -MP -MF unwind-c.dep -fexceptions -c /home/tony/buildall/src/gcc/libgcc/../gcc/unwind-c.c In file included from /home/tony/buildall/src/gcc/libgcc/../gcc/unwind-sjlj.c:30: /home/tony/buildall/ia64/gcc0/./gcc/include/unwind.h:214:20: error: stdlib.h: No such file or directory In file included from /home/tony/buildall/src/gcc/libgcc/../gcc/unwind-c.c:29: /home/tony/buildall/ia64/gcc0/./gcc/include/unwind.h:214:20: error: stdlib.h: No such file or directory --- It looks like stdlib.h is included to get the prototype for abort(). I'll attach the buildlogs for binutils and gcc so you have the exact commandline used. Also I have a patch I use to get past the error I cannot speak to it's correctness but it seems "safe" to me. -- Summary: Cross compiling for ia64 fails as stdlib.h doesn't exist Product: gcc Version: 4.4.4 Status: UNCONFIRMED Severity: minor Priority: P3 Component: c AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: tony at bakeyournoodle dot com GCC build triplet: ia64-unknown-linux-gnu GCC host triplet: x86_64-unknown-linux-gnu GCC target triplet: ia64-unknown-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44553