problems cross-compilng gcc

Sun Dec 26 10:25:00 GMT 1999

I'm trying to  build  a cross compiler for powerpc OpenBSD on a i386
OpenBSD machine (2.5)

I configured binutils with the following:
configure ---host=$MACHTYPE --target=powerpc--openbsd
--prefix=/usr/cross-tools -v
This worked fine and built binutils.
I then ran configure script  for gcc with the same parameters and then ran
make all install.
There I get error:

bash-2.03# make all install
make all-recursive
Making all in intl
Making all in lib
Making all in makeinfo
(cd intl && make all)
/usr/buildtools/gcc-2.95.2/gcc/xgcc -B/usr/buildtools/gcc-2.95.2/gcc/
-I/usr/cross-tools/powerpc--openbsd/include -DCROSS_COMPILE -DIN_GCC
-DHAIFA   -g -O2 -I./include     -c ./libgcc1-test.c
./libgcc1-test.c:101: warning: conflicting types for built-in function `memcpy'
Testing libgcc1.  Ignore linker warning messages.
/usr/buildtools/gcc-2.95.2/gcc/xgcc -B/usr/buildtools/gcc-2.95.2/gcc/
-I/usr/cross-tools/powerpc--openbsd/include -DCROSS_COMPILE -DIN_GCC
-DHAIFA   -g -O2 -I./include  libgcc1-test.o -o libgcc1-test  -nostartfiles
-nostdlib `/usr/buildtools/gcc-2.95.2/gcc/xgcc
-B/usr/buildtools/gcc-2.95.2/gcc/ -B/usr/cross-tools/powerpc--openbsd/bin/
-I/usr/cross-tools/powerpc--openbsd/include --print-libgcc-file-name`
test x"no" != xyes ||  /usr/buildtools/gcc-2.95.2/gcc/xgcc
-B/usr/buildtools/gcc-2.95.2/gcc/ -B/usr/cross-tools/powerpc--openbsd/bin/
-c -DHAVE_CONFIG_H -g -O2 -I. -I./../../include   vsprintf.c -o
/usr/buildtools/gcc-2.95.2/gcc/xgcc -B/usr/buildtools/gcc-2.95.2/gcc/
-B/usr/cross-tools/powerpc--openbsd/bin/ -c -DHAVE_CONFIG_H -g -O2 -I.
-I./../../include  vsprintf.c
vsprintf.c: In function `vsprintf':
vsprintf.c:47: structure has no member named `_flag'
vsprintf.c:47: `_IOWRT' undeclared (first use in this function)
vsprintf.c:47: (Each undeclared identifier is reported only once
vsprintf.c:47: for each function it appears in.)
vsprintf.c:47: `_IOSTRG' undeclared (first use in this function)
vsprintf.c:48: structure has no member named `_ptr'
vsprintf.c:49: structure has no member named `_cnt'
*** Error code 1

Stop in /usr/buildtools/gcc-2.95.2/powerpc--openbsd/libiberty.
*** Error code 1

Stop in /usr/buildtools/gcc-2.95.2.

Looks like it's running a test of libgc1.a and fails to find the correct
definitions for things like FILE among others.
I don't quite understand why this is happening.
Also: gcc was complaining a lot  about not being able to find files
stdio.h and stdedef.h  and such until I created a symllink to usr/include
in cross-tools/powerpc--openbsd ( my prefix directory)
The thing that confuses me most is how do I determine from the error
messages it spits out which particular module it was compiling
Also, what else do I need to build a functional cross compile environment
besides gcc and binutils? The FAQ refers to newlib but it is my
underdstanding that newlib is used only in the embedded development.
Thanks in advance


Want more information?  See the CrossGCC FAQ,
Want to unsubscribe? Send a note to

More information about the crossgcc mailing list