This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Building gcc for uclinux (arm)
- To: gcc at gcc dot gnu dot org
- Subject: Building gcc for uclinux (arm)
- From: Adrian von Bidder <avbidder at acter dot ch>
- Date: Mon, 29 Oct 2001 11:16:59 +0100
- References: <3BDD1325.6E07E022@acter.ch>
Adrian von Bidder wrote in gcc-help:
>
> Greets everybody!
>
> I'm trying to build a gcc for uclinux with the arm(7tdmi). I'm a little
> bit lost - apparently, I can't just take the same target name as with
> gcc-2.96:
[...]
Ok, since binutils had the same problem, I asked there and got this
patch:
--- gcc-3.0.2/config.sub Mon Jul 16 12:04:04 2001
+++ config.sub Mon Oct 29 11:11:11 2001
@@ -1035,7 +1035,8 @@
| -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
- | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* | -os2*)
+ | -storm-chaos* | -tops10* | -tenex* | -tops20* \
+ | -its* | -os2* | -uclinux*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
Which lets configure do its work the right way (choosig uclinux-elf.h
with
--target=arm-uclinux). But building the thumb code libgcc then fails
with
=========
/home/avbidder/build-toolchain/build-gcc/gcc/xgcc
-B/home/avbidder/build-toolchain/build-gcc/gcc/
-B/home/avbidder/gcc-3/arm-uclinux/bin/
-B/home/avbidder/gcc-3/arm-uclinux/lib/ -isystem
/home/avbidder/gcc-3/arm-uclinux/include -O2 -DCROSS_COMPILE
-DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -isystem ./include -Dinhibit_libc -fno-inline -g1
-DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I.
-I../../gcc-3.0.2/gcc -I../../gcc-3.0.2/gcc/.
-I../../gcc-3.0.2/gcc/config -I../../gcc-3.0.2/gcc/../include -mthumb
-DL_clear_cache -c ../../gcc-3.0.2/gcc/libgcc2.c -o
libgcc/thumb/_clear_cache.o
/tmp/ccfNEk6M.s: Assembler messages:
/tmp/ccfNEk6M.s:122: Error: Invalid swi expression
/tmp/ccfNEk6M.s:122: Error: Value of 10420226 too large for field of 2
bytes at 2
make[2]: *** [libgcc/thumb/_clear_cache.o] Error 1
make[2]: Leaving directory `/tmp/avbidder-build-toolchain/build-gcc/gcc'
make[1]: *** [stmp-multilib] Error 2
make[1]: Leaving directory `/tmp/avbidder-build-toolchain/build-gcc/gcc'
make: *** [all-gcc] Error 2
========
where 10420226 is the software interrupt the clear_cache (or similar)
syscall uses. It seems there'll have to be an ifdef __THUMBEL__, causing
it to use the other syscall number (which I, of course, do not know
right now...)
Griessli
-- vbi