[U-Boot-Users] Building on Mac OS X?

Rick Mann rmann at latencyzero.com
Wed Jan 9 19:58:46 CET 2008


Hi. The SourceForge archive search is broken ("can't connect to search  
server"), so I was unable to look through them.

I'd like to compile u-boot on Mac OS X 10.5, but I don't get very far  
in the process.

I have a recent xscale-elf toolchain (gcc 4.2.2, newlib 1.15, binutils  
2.17) that I'm using successfully to build binary images that can be  
loaded and run by u-boot. I posted the build transcript below.

Any suggestions would be most appreciated. Thanks!

-- 
Rick


TwinAero:u-boot-1.1.6 rmann$ make triton320_config
Configuring for triton320 board...
TwinAero:u-boot-1.1.6 rmann$ make all
for dir in tools examples post post/cpu ; do make -C $dir _depend ; done
ln -s ../common/environment.c environment.c
ln -s ../lib_generic/crc32.c crc32.c
make[1]: Circular environment.c <- environment.c dependency dropped.
ln -s ../common/environment.c environment.c
make[1]: Circular crc32.c <- crc32.c dependency dropped.
ln -s ../lib_generic/crc32.c crc32.c
make[1]: Circular img2srec.c <- img2srec.c dependency dropped.
make[1]: Circular mkimage.c <- mkimage.c dependency dropped.
make[1]: Circular envcrc.c <- envcrc.c dependency dropped.
make[1]: Circular gen_eth_addr.c <- gen_eth_addr.c dependency dropped.
make[1]: Circular bmp_logo.c <- bmp_logo.c dependency dropped.
make[1]: Nothing to be done for `_depend'.
make[1]: Circular hello_world.c <- hello_world.c dependency dropped.
make[1]: Circular stubs.c <- stubs.c dependency dropped.
make[1]: Nothing to be done for `_depend'.
make[1]: Circular cache_8xx.S <- cache_8xx.S dependency dropped.
make[1]: Circular cache.c <- cache.c dependency dropped.
make[1]: Circular codec.c <- codec.c dependency dropped.
make[1]: Circular cpu.c <- cpu.c dependency dropped.
make[1]: Circular dsp.c <- dsp.c dependency dropped.
make[1]: Circular ether.c <- ether.c dependency dropped.
make[1]: Circular i2c.c <- i2c.c dependency dropped.
make[1]: Circular memory.c <- memory.c dependency dropped.
make[1]: Circular post.c <- post.c dependency dropped.
make[1]: Circular rtc.c <- rtc.c dependency dropped.
make[1]: Circular spr.c <- spr.c dependency dropped.
make[1]: Circular sysmon.c <- sysmon.c dependency dropped.
make[1]: Circular tests.c <- tests.c dependency dropped.
make[1]: Circular uart.c <- uart.c dependency dropped.
make[1]: Circular usb.c <- usb.c dependency dropped.
make[1]: Circular watchdog.c <- watchdog.c dependency dropped.
make[1]: Nothing to be done for `_depend'.
make[1]: Circular asm.S <- asm.S dependency dropped.
make[1]: Circular cmp.c <- cmp.c dependency dropped.
make[1]: Circular cmpi.c <- cmpi.c dependency dropped.
make[1]: Circular two.c <- two.c dependency dropped.
make[1]: Circular twox.c <- twox.c dependency dropped.
make[1]: Circular three.c <- three.c dependency dropped.
make[1]: Circular threex.c <- threex.c dependency dropped.
make[1]: Circular threei.c <- threei.c dependency dropped.
make[1]: Circular andi.c <- andi.c dependency dropped.
make[1]: Circular srawi.c <- srawi.c dependency dropped.
make[1]: Circular rlwnm.c <- rlwnm.c dependency dropped.
make[1]: Circular rlwinm.c <- rlwinm.c dependency dropped.
make[1]: Circular rlwimi.c <- rlwimi.c dependency dropped.
make[1]: Circular store.c <- store.c dependency dropped.
make[1]: Circular load.c <- load.c dependency dropped.
make[1]: Circular cr.c <- cr.c dependency dropped.
make[1]: Circular b.c <- b.c dependency dropped.
make[1]: Circular multi.c <- multi.c dependency dropped.
make[1]: Circular string.c <- string.c dependency dropped.
make[1]: Circular complex.c <- complex.c dependency dropped.
make[1]: Nothing to be done for `_depend'.
make -C tools all
make[1]: Circular environment.c <- environment.c dependency dropped.
ln -s ../common/environment.c environment.c
make[1]: Circular crc32.c <- crc32.c dependency dropped.
ln -s ../lib_generic/crc32.c crc32.c
make[1]: Circular img2srec.c <- img2srec.c dependency dropped.
make[1]: Circular mkimage.c <- mkimage.c dependency dropped.
make[1]: Circular envcrc.c <- envcrc.c dependency dropped.
make[1]: Circular gen_eth_addr.c <- gen_eth_addr.c dependency dropped.
make[1]: Circular bmp_logo.c <- bmp_logo.c dependency dropped.
gcc -Wall -pedantic -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include2 -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -DTEXT_BASE=0x800c0000 -DUSE_HOSTCC -O -c -o  
img2srec.o img2srec.c
gcc -Wall -pedantic -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include2 -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -DTEXT_BASE=0x800c0000 -DUSE_HOSTCC -O  -o img2srec  
img2srec.o
strip img2srec
gcc -g -Wall -pedantic -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include2 -idirafter /Users/rmann/Desktop/U-Boot/source/u- 
boot-1.1.6/include -DTEXT_BASE=0x800c0000 -DUSE_HOSTCC -O -c -o  
mkimage.o mkimage.c
mkimage.c: In function ‘main’:
mkimage.c:325: error: ‘caddr_t’ undeclared (first use in this function)
mkimage.c:325: error: (Each undeclared identifier is reported only once
mkimage.c:325: error: for each function it appears in.)
mkimage.c:325: error: syntax error before ‘ptr’
mkimage.c:306: warning: unused variable ‘data’
mkimage.c:305: warning: unused variable ‘len’
mkimage.c:345: error: ‘data’ undeclared (first use in this function)
mkimage.c:346: error: ‘len’ undeclared (first use in this function)
mkimage.c: At top level:
mkimage.c:382: error: syntax error before numeric constant
mkimage.c:387: error: syntax error before numeric constant
mkimage.c:387: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:387: error: conflicting types for ‘exit’
mkimage.c:387: warning: data definition has no type or storage class
mkimage.c:394: error: syntax error before ‘for’
mkimage.c:394: warning: ISO C does not allow extra ‘;’ outside of a  
function
mkimage.c:405: error: syntax error before numeric constant
mkimage.c:405: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:405: error: conflicting types for ‘exit’
mkimage.c:405: warning: data definition has no type or storage class
mkimage.c:407: warning: type defaults to ‘int’ in declaration of ‘size’
mkimage.c:407: error: conflicting types for ‘size’
mkimage.c:392: error: previous declaration of ‘size’ was here
mkimage.c:407: error: ‘sbuf’ undeclared here (not in a function)
mkimage.c:407: warning: data definition has no type or storage class
mkimage.c:408: error: syntax error before ‘}’ token
mkimage.c:415: error: syntax error before numeric constant
mkimage.c:415: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:415: error: conflicting types for ‘exit’
mkimage.c:415: warning: data definition has no type or storage class
mkimage.c:424: warning: type defaults to ‘int’ in declaration of ‘file’
mkimage.c:424: error: ‘sep’ undeclared here (not in a function)
mkimage.c:424: warning: data definition has no type or storage class
mkimage.c:425: error: syntax error before ‘}’ token
mkimage.c:430: warning: type defaults to ‘int’ in declaration of ‘file’
mkimage.c:430: error: redefinition of ‘file’
mkimage.c:424: error: previous definition of ‘file’ was here
mkimage.c:430: warning: initialization makes integer from pointer  
without a cast
mkimage.c:430: error: initializer element is not constant
mkimage.c:430: warning: data definition has no type or storage class
mkimage.c:432: error: syntax error before ‘for’
mkimage.c:432: warning: ISO C does not allow extra ‘;’ outside of a  
function
mkimage.c:436: error: syntax error before numeric constant
mkimage.c:436: warning: type defaults to ‘int’ in declaration of  
‘copy_file’
mkimage.c:436: error: conflicting types for ‘copy_file’
mkimage.c:145: error: previous declaration of ‘copy_file’ was here
mkimage.c:436: warning: data definition has no type or storage class
mkimage.c:437: error: syntax error before ‘++’ token
mkimage.c:438: warning: type defaults to ‘int’ in declaration of ‘file’
mkimage.c:438: error: redefinition of ‘file’
mkimage.c:424: error: previous definition of ‘file’ was here
mkimage.c:438: warning: data definition has no type or storage class
mkimage.c:439: error: syntax error before ‘}’ token
mkimage.c:458: error: syntax error before numeric constant
mkimage.c:458: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:458: error: conflicting types for ‘exit’
mkimage.c:458: warning: data definition has no type or storage class
mkimage.c:461: warning: type defaults to ‘int’ in declaration of ‘ptr’
mkimage.c:462: error: ‘ifd’ undeclared here (not in a function)
mkimage.c:462: warning: initialization makes integer from pointer  
without a cast
mkimage.c:462: error: initializer element is not constant
mkimage.c:462: warning: data definition has no type or storage class
mkimage.c:463: error: syntax error before ‘if’
mkimage.c:466: error: syntax error before numeric constant
mkimage.c:466: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:466: error: conflicting types for ‘exit’
mkimage.c:466: warning: data definition has no type or storage class
mkimage.c:469: warning: type defaults to ‘int’ in declaration of ‘hdr’
mkimage.c:469: error: conflicting types for ‘hdr’
mkimage.c:175: error: previous definition of ‘hdr’ was here
mkimage.c:469: warning: initialization makes integer from pointer  
without a cast
mkimage.c:469: error: initializer element is not constant
mkimage.c:469: warning: data definition has no type or storage class
mkimage.c:471: warning: type defaults to ‘int’ in declaration of  
‘checksum’
mkimage.c:474: error: initializer element is not constant
mkimage.c:474: warning: data definition has no type or storage class
mkimage.c:477: error: syntax error before ‘->’ token
mkimage.c:488: error: syntax error before ‘(’ token
mkimage.c:490: warning: type defaults to ‘int’ in declaration of  
‘checksum’
mkimage.c:490: error: redefinition of ‘checksum’
mkimage.c:471: error: previous definition of ‘checksum’ was here
mkimage.c:490: error: initializer element is not constant
mkimage.c:490: warning: data definition has no type or storage class
mkimage.c:492: error: syntax error before ‘->’ token
mkimage.c:494: warning: type defaults to ‘int’ in declaration of  
‘print_header’
mkimage.c:494: warning: parameter names (without types) in function  
declaration
mkimage.c:494: error: conflicting types for ‘print_header’
mkimage.c:147: error: previous declaration of ‘print_header’ was here
mkimage.c:494: warning: data definition has no type or storage class
mkimage.c:496: error: syntax error before ‘void’
mkimage.c:508: error: syntax error before numeric constant
mkimage.c:508: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:508: error: conflicting types for ‘exit’
mkimage.c:508: warning: data definition has no type or storage class
mkimage.c:511: error: syntax error before numeric constant
mkimage.c:511: warning: type defaults to ‘int’ in declaration of ‘exit’
mkimage.c:511: error: conflicting types for ‘exit’
mkimage.c:511: warning: data definition has no type or storage class
mkimage.c:516: error: conflicting types for ‘copy_file’
mkimage.c:436: error: previous declaration of ‘copy_file’ was here
mkimage.c:619: error: conflicting types for ‘print_header’
mkimage.c:494: error: previous declaration of ‘print_header’ was here
make[1]: *** [mkimage.o] Error 1
make: *** [tools] Error 2
TwinAero:u-boot-1.1.6 rmann$ edit Makefile
TwinAero:u-boot-1.1.6 rmann$






More information about the U-Boot mailing list