mistake
Hi people!
I work with based on AT91RM9200 board.
At compilation gcc2.95.3 there is a mistake
arm-elf-gcc -g -Os -fno-strict-aliasing -fno-common -ffixed-r8
-mshort-load-bytes -msoft-float -D__KERNEL__ -DTEXT_BASE=0x21f00000
-I/home/ask/distr/u-boot-1.1.3/include -fno-builtin -ffreestanding
-nostdinc -isystem /usr/local/lib/gcc-lib/arm-elf/2.95.3/include -pipe
-DCONFIG_ARM -D__ARM__ -mapcs-32 -march=armv4 -Wall
-Wstrict-prototypes -c -o cfi_flash.o cfi_flash.c In file included
from cfi_flash.c:48:/home/ask/distr/u-boot-1.1.3/include/asm/processor.h:52: parse error before 1' /home/ask/distr/u-boot-1.1.3/include/asm/processor.h:52: warning: no semicolon at end of struct or union /home/ask/distr/u-boot-1.1.3/include/asm/processor.h:54: parse error before }' /home/ask/distr/u-boot-1.1.3/include/asm/processor.h:58: field `insn' has incomplete type
Problem in the next line in file "processor.h":
union debug_insn {
u32 arm; // ERROR HERE
u16 thumb;
};
How to solve a problem?
ThankP.S. host OS - ASPLinux 9.2
Alexandr
Quoted 3 lines · In message <[email protected]> you wrote:
I work with based on AT91RM9200 board.
At compilation gcc2.95.3 there is a mistake
...
Quoted 4 lines
/home/ask/distr/u-boot-1.1.3/include/asm/processor.h:52: parse error before1' /home/ask/distr/u-boot-1.1.3/include/asm/processor.h:52: warning: no semicolon at end of struct or union /home/ask/distr/u-boot-1.1.3/include/asm/processor.h:54: parse error before}'/home/ask/distr/u-boot-1.1.3/include/asm/processor.h:58: field `insn' has incomplete type
...
Quoted 1 line
u32 arm; // ERROR HERE
...
Quoted 1 line
How to solve a problem?
Use a working toolchain. Yours is broken, as it seems to define "arm" as something else. But "arm" is not a reserved identifier or anything like that.
Best regards,
Wolfgang Denk
Signature · 5 lines
Software Engineering: Embedded and Realtime Systems, Embedded Linux Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de The philosophy exam was a piece of cake - which was a bit of a surprise, actually, because I was expecting some questions on a sheet of paper.
Alexandr Kuleschov <[email protected]> schrieb am Dienstag, 29. November 2005 um 11:00 +0100:
Quoted 5 lines
I work with based on AT91RM9200 board.
At compilation gcc2.95.3 there is a mistake
from cfi_flash.c:48:/home/ask/distr/u-boot-1.1.3/include/asm/processor.h:52: parse error before `1'
Quoted 7 lines
Problem in the next line in file "
processor.h":union
debug_insn{
u32 arm; // ERROR HERE
u16 thumb;
};
Hi,
your tool-chain is broken; your compiler defines the macro "arm" (with the value "1").
IIRC this was standard behaviour by gcc 2.95.3, so you need a different version.
Quoted 3 lines
How to solve a problem?
Choose one (best solution first):
1. upgrade to a more recent tool-chain (2.95.3 is very old)
2. place the line "#undef arm" just before "union debug_insn"
3. change the offending line in processor.h
(change "arm" to "gogetanewcompiler" or something like that;
debug_insn is not used by U-Boot).
2 and 3 are kludges and should only be temporary solutions.
Cheers
Anders