[Top][All Lists]

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

Re: [Tinycc-devel] TCC on ARM

From: Hanzac Chen
Subject: Re: [Tinycc-devel] TCC on ARM
Date: Sat, 2 Dec 2006 00:10:13 +0800


On 12/1/06, tike wrote:
Thanks for hint. Why wasn't -lm needed when host machine was i386?
Anyway, now tcc builds with a warning, though:

tcc.c:9505:2: warning: #warning add arch specific rt_get_caller_pc()

Hope that is not critical.

But then libtcc1 fails:

arm-linux-gcc -O2 -Wall -c -o libtcc1.o libtcc1.c
libtcc1.c:140:2: #error unsupported CPU type

I am confused. Isn't libtcc1 needed for a cross compiler (host i386;
target arm) as well. Why does it fail for a native (arm, arm) compiler?

Building bcheck fails also. Why does it try to build that when it
doesn't in case of i386 host?

Haven't you checked the souce code libtcc1.c:

#if defined(__i386__)
#define sub_ddmmss(sh, sl, ah, al, bh, bl) \
... ...
#error unsupported CPU type

You have to provide some arm assembly to replace the i386 ones ...
since you want to have a tcc targeted to arm cpu.

A fast way is to find these functions in gcc source code. I believe
that the libtcc1.c is also adapted from gcc, so you could find it
specially for arm cpu.

Hope you have the luck.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]