[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Building a cross-compiler for sparc



* Christopher C. Chimelis <chris@debian.org> [020520 18:42]:

[ binutils-sparc ]
> Oh, I didn't realise that there was one :-P  Yes, that should be fine to
> use :-)

Okay, I'm now using toolchain-source and I think (?) I'm making
progress, it now throws the following error:

| make[2]: Entering directory `/usr/src/debian/gcc-sparc-3.0.4/build/gcc'
| HEADERS="auto-host.h gansidecl.h  i386/xm-i386.h defaults.h hwint.h" DEFINES="POSIX" \
| TARGET_CPU_DEFAULT="TARGET_CPU_sparc" \
| /bin/sh ../../src/gcc/mkconfig.sh config.h
| HEADERS="gansidecl.h sparc/sunos4.h sparc/sun4gas.h defaults.h" DEFINES="" TARGET_CPU_DEFAULT="" \
| TARGET_CPU_DEFAULT="TARGET_CPU_sparc" \
| /bin/sh ../../src/gcc/mkconfig.sh tm.h
| HEADERS="auto-host.h gansidecl.h  i386/xm-i386.h defaults.h hwint.h" DEFINES="POSIX" \
| TARGET_CPU_DEFAULT="TARGET_CPU_sparc" \
| /bin/sh ../../src/gcc/mkconfig.sh hconfig.h
| gcc -c -DCROSS_COMPILE -DIN_GCC    -g -O2 -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wtraditional -pedantic -Wno-long-long  -DHAVE_CONFIG_H -DGENERATOR_FILE    -I. -I. -I../../src/gcc -I../../src/gcc/. -I../../src/gcc/config -I../../src/gcc/../include ../../src/gcc/gengenrtl.c
| In file included from ../../src/gcc/system.h:114,
|                  from ../../src/gcc/gengenrtl.c:23:
| /usr/include/stdlib.h:571: conflicting types for `on_exit'
| ../../src/gcc/config/sparc/sunos4.h:53: previous declaration of `on_exit'
| make[2]: *** [gengenrtl.o] Error 1
| make[2]: Leaving directory `/usr/src/debian/gcc-sparc-3.0.4/build/gcc'
| make[1]: *** [all-gcc] Error 2
| make[1]: Leaving directory `/usr/src/debian/gcc-sparc-3.0.4/build'
| make: *** [build-stamp] Error 2
| debuild: fatal error at line 456:
| dpkg-buildpackage failed!

I'm guessing that it shouldn't search for stdlib.h in /usr/include but in
/usr/sparc-linux/include that was generated by libc6-sparc-cross and
libc6-dev-sparc-cross:

| mdb@tornado:/usr/sparc-linux/$ dpkg -S /usr/sparc-linux
| libc6-sparc-cross, libc6-dev-sparc-cross: /usr/sparc-linux
| 
| mdb@tornado:/usr/sparc-linux/include/$ ls -l stdlib.h
| -rw-r--r--    1 root     root        30988 Apr 28 21:01 stdlib.h

A little search into the build/gcc dir gave me the following in
build/gcc/Makefile:

| # Default cross SYSTEM_HEADER_DIR, to be overridden by targets.
| CROSS_SYSTEM_HEADER_DIR = $(build_tooldir)/sys-include

But here I'm a little stuck and don't know my way around the Makefile good
and quick enough to find a solution for this error. Can you help me out?

mdb
-- 
pobody is nerfect


-- 
To UNSUBSCRIBE, email to debian-gcc-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Reply to: