On Wed, 13 Jun 2001 11:30:38 +1200 (NZST),
Juha Saarinen <juha@xxxxxxxxxxxx> wrote:
>On Wed, 13 Jun 2001, Keith Owens wrote:
>
>> cd /usr/src/xfs-cvs/linux-2.4-xfs/linux/arch/i386/kernel
>> gcc -V egcs-2.91.66 -D__ASSEMBLY__ -D__KERNEL__ \
>> -I/usr/src/xfs-cvs/linux-2.4-xfs/linux/include -traditional -c \
>> trampoline.S -o - -E | grep -B 5 -A 5 ljmp
>> That will show exactly what it is complaining about. Also need output from
>> as -v < /dev/null
>
>Woarrgghh... kewl voodoo there, Keith! ;-)
Not really, just cut and paste the commands in your bug report,
changing the -o file to '-' and adding -E. It is the standard way to
see what the pre-processor is doing. Damn, there goes another trade
secret :).
>flush_instr:
> ljmpl $__KERNEL_CS, $0x00100000
> # jump to startup_32 in arch/1/kernel/head.S
>Why is "i386" translated into "1"?
gcc on i386 has a built in -Di386=1. It is only a comment, ignore it.
># as -v < /dev/null
>GNU assembler version 2.10.91 (i386-redhat-linux) using BFD version
>2.10.91.0.2
That version of as is OK.
The problem is gcc -V egcs-2.91.66 does not translate $__KERNEL_CS to
$0x10, kgcc does. kgcc uses the egcs-2.91.66 back end but a different
gcc wrapper. The kgcc wrapper sets pre-processor flag '-$' which
forbids the use of '$' in identifiers. With -$, gcc -V egcs-2.91.66
works as well. So the obvious fix is to change the top level Makefile
to say
CC = $(CROSS_COMPILE)gcc -V egcs-2.91.66 -$
The pre-processor from gcc 2.96 automatically sets -$. Consistency,
what consistency?
|