Help building cross compiler...
joseph layton galbraith
galb@unm.edu
Wed Feb 4 14:09:00 GMT 1998
I am trying to build a cross compiler from linux
to sunos4, and it is failing building target
libraries (in libio/gen-params) because it
can't find stdio.h.
Here is what I've done ... if someone can please give me some hint where
I've gone wrong, I'dbe eternally grateful. I've read all the faqs and
information I can find... (including egcs INSTALL directory and the
cross-faq at cygnus)
1. Build binutils-2.8.1.0.19 for targeted for sparc-sunos4
and installed into /home/galb/egcs-sun.
2. Copied newlib-1.8.0/newlib/libc/include to
/home/galb/egcs-sun and to /egcs-980122/include
3. Configured egcs as follows (from config.status):
../egcs-980122/configure --host=i586-pc-linux-gnulibc1
--prefix=/home/galb/egcs-sun --target=sparc-sunos4
--with-headers=/home/galb/egcs-sun/include
--with-libs=/home/galb/egcs-sun/lib --with-newlib --norecursion
4. gmake cross
which gets the following error:
gmake[2]: Entering directory `/home/galb/egcs-build/sparc-sunos4/libio'
rootme=`pwd`/ ; export rootme; \
CC="/home/galb/egcs-build/gcc/xgcc -B/home/galb/egcs-build/gcc/"; export
CC; \
CXX="/home/galb/egcs-build/gcc/xgcc -B/home/galb/egcs-build/gcc/
-nostdinc++ -g -O2"; export CXX; \
CONFIG_NM="sparc-sunos4-nm"; export CONFIG_NM; \
/bin/sh ../../../egcs-980122/libio/gen-params LIB_VERSION=2.8.0
>tmp-params.h
dummy.c:1: sys/types.h: No such file or directory
dummy.c:8: stdio.h: No such file or directory
dummy.c:9: time.h: No such file or directory
dummy.c:10: signal.h: No such file or directory
gen-params: could not invoke /home/galb/egcs-build/gcc/xgcc
-B/home/galb/egcs-build/gcc/ -E on dummy.c
gmake[2]: *** [_G_config.h] Error 1
gmake[2]: Leaving directory `/home/galb/egcs-build/sparc-sunos4/libio'
gmake[1]: *** [all-target-libio] Error 2
gmake[1]: Leaving directory `/home/galb/egcs-build'
gmake: *** [cross] Error 2
Each of the .h files referenced above exists
in /home/galb/egcs-sun/include.
At first it looked to me like gen-params needed to be
passed some -I options for the compiler, but then I
thought the cross compiler should be automatically
searching the /home/galb/egcs-sun/include directory
for it's system includes... now I don't even pretend to have a
clue what is up.
So what did I screw up... I'm sure it's something obvious
and dumb.
Thanks for your time and patience,
Joseph
More information about the Gcc
mailing list