一切按步骤走,原先在fedora15上能正常编译,现在在ylmfos上不能编译,错误提示如下:
root@farce-laptop:/opt/FriendlyARM/mini6410/linux/u-boot-mini6410# make mini6410_sd_config-ram256;make
Configuring for mini6410 board which boot from SD ram256...
for dir in tools examples post post/cpu ; do make -C $dir _depend ; done
make[1]: 进入目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/tools”
make[1]: 对“_depend”无需做任何事。
make[1]: 离开目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/tools”
make[1]: 进入目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/examples”
make[1]: 对“_depend”无需做任何事。
make[1]: 离开目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/examples”
make[1]: 进入目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/post”
make[1]: 对“_depend”无需做任何事。
make[1]: 离开目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/post”
make[1]: 进入目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/post/cpu”
make[1]: 对“_depend”无需做任何事。
make[1]: 离开目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/post/cpu”
make -C tools all
make[1]: 进入目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/tools”
gcc -Wall -pedantic -idirafter /opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include -idirafter /opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include2 -idirafter /opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include -DTEXT_BASE=0xc7e00000 -DUSE_HOSTCC -O -c -o img2srec.o img2srec.c
img2srec.c:56:19: 错误:stdio.h:没有那个文件或目录
img2srec.c:57:20: 错误:stdlib.h:没有那个文件或目录
img2srec.c:58:19: 错误:ctype.h:没有那个文件或目录
img2srec.c:59:20: 错误:string.h:没有那个文件或目录
在包含自 img2srec.c:60 的文件中:
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:43:20: 错误:stdint.h:没有那个文件或目录
In file included from img2srec.c:60:
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:58: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Elf32_Addr’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:59: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Elf32_Off’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:60: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Elf32_Sword’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:61: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Elf32_Word’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:62: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Elf32_Half’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:123: 错误:expected specifier-qualifier-list before ‘Elf32_Half’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:243: 错误:expected specifier-qualifier-list before ‘Elf32_Word’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:353: 错误:expected specifier-qualifier-list before ‘Elf32_Word’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:403: 错误:expected specifier-qualifier-list before ‘Elf32_Addr’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:410: 错误:expected specifier-qualifier-list before ‘Elf32_Addr’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:422: 错误:expected specifier-qualifier-list before ‘Elf32_Word’
/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/include/elf.h:457: 错误:expected specifier-qualifier-list before ‘Elf32_Sword’
img2srec.c:61:20: 错误:unistd.h:没有那个文件或目录
img2srec.c:62:19: 错误:errno.h:没有那个文件或目录
img2srec.c:81: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘CHAR’
img2srec.c:82: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘BYTE’
img2srec.c:83: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘WORD’
img2srec.c:84: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘DWORD’
img2srec.c:95: 错误:expected ‘)’ before ‘*’ token
img2srec.c:96: 错误:expected ‘)’ before ‘*’ token
img2srec.c:97: 错误:expected ‘)’ before ‘*’ token
img2srec.c:98: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:99: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:100: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:101: 错误:expected declaration specifiers or ‘...’ before ‘BYTE’
img2srec.c:101: 错误:expected declaration specifiers or ‘...’ before ‘WORD’
img2srec.c:102: 错误:expected declaration specifiers or ‘...’ before ‘WORD’
img2srec.c:102: 错误:expected declaration specifiers or ‘...’ before ‘DWORD’
img2srec.c:103: 警告:在‘BYTE’的声明中,类型默认为‘int’
img2srec.c:103: 错误:expected ‘;’, ‘,’ or ‘)’ before ‘*’ token
img2srec.c:104: 错误:expected declaration specifiers or ‘...’ before ‘DWORD’
img2srec.c:111: 错误:expected ‘)’ before ‘*’ token
img2srec.c:133: 错误:expected ‘)’ before ‘*’ token
img2srec.c:154: 错误:expected ‘)’ before ‘*’ token
img2srec.c:174: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:184: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:196: 错误:expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
img2srec.c:203: 错误:expected declaration specifiers or ‘...’ before ‘BYTE’
img2srec.c:203: 错误:expected declaration specifiers or ‘...’ before ‘WORD’
img2srec.c: 在函数‘WriteHex’中:
img2srec.c:205: 错误:‘WORD’未声明(在此函数内第一次使用)
img2srec.c:205: 错误:(即使在一个函数内多次出现,每个未声明的标识符在其
img2srec.c:205: 错误:所在的函数内也只报告一次。)
img2srec.c:205: 错误:expected ‘;’ before ‘temp’
img2srec.c:207: 警告:ISO C90 不允许混合使用声明和代码
img2srec.c:209: 错误:‘pCheckSum’未声明(在此函数内第一次使用)
img2srec.c:209: 错误:‘value’未声明(在此函数内第一次使用)
img2srec.c:210: 错误:‘temp’未声明(在此函数内第一次使用)
img2srec.c: 在文件层:
img2srec.c:218: 错误:expected declaration specifiers or ‘...’ before ‘WORD’
img2srec.c:218: 错误:expected declaration specifiers or ‘...’ before ‘DWORD’
img2srec.c:219: 警告:在‘BYTE’的声明中,类型默认为‘int’
img2srec.c:219: 错误:expected ‘;’, ‘,’ or ‘)’ before ‘*’ token
img2srec.c:268: 错误:expected declaration specifiers or ‘...’ before ‘DWORD’
img2srec.c: 在函数‘ConvertELF’中:
img2srec.c:270: 错误:‘FILE’未声明(在此函数内第一次使用)
img2srec.c:270: 错误:‘file’未声明(在此函数内第一次使用)
img2srec.c:271: 警告:ISO C90 不允许混合使用声明和代码
img2srec.c:273: 错误:‘BYTE’未声明(在此函数内第一次使用)
img2srec.c:273: 错误:expected ‘;’ before ‘rxBlock’
img2srec.c:274: 错误:‘DWORD’未声明(在此函数内第一次使用)
img2srec.c:274: 错误:expected ‘;’ before ‘loadSize’
img2srec.c:275: 错误:expected ‘;’ before ‘firstAddr’
img2srec.c:276: 错误:expected ‘;’ before ‘loadAddr’
img2srec.c:277: 错误:expected ‘;’ before ‘loadDiff’
img2srec.c:278: 警告:ISO C90 不允许混合使用声明和代码
img2srec.c:280: 错误:‘getPtr’未声明(在此函数内第一次使用)
img2srec.c:281: 警告:ISO C90 不允许混合使用声明和代码
img2srec.c:286: 警告:隐式声明函数‘fopen’
img2srec.c:287: 警告:隐式声明函数‘fprintf’
img2srec.c:287: 警告:隐式声明与内建函数‘fprintf’不兼容
img2srec.c:287: 错误:‘stderr’未声明(在此函数内第一次使用)
img2srec.c:287: 警告:隐式声明函数‘strerror’
img2srec.c:292: 警告:隐式声明函数‘fread’
img2srec.c:292: 错误:‘rxBlock’未声明(在此函数内第一次使用)
img2srec.c:293: 警告:隐式声明函数‘ExtractBlock’
img2srec.c:294: 警告:隐式声明函数‘ExtractWord’
img2srec.c:294: 错误:‘Elf32_Ehdr’没有名为‘e_type’的成员
img2srec.c:295: 错误:‘Elf32_Ehdr’没有名为‘e_machine’的成员
img2srec.c:296: 警告:隐式声明函数‘ExtractLong’
img2srec.c:296: 错误:expected expression before ‘)’ token
img2srec.c:297: 错误:expected expression before ‘)’ token
img2srec.c:298: 错误:expected expression before ‘)’ token
img2srec.c:299: 错误:expected expression before ‘)’ token
img2srec.c:300: 错误:expected expression before ‘)’ token
img2srec.c:301: 错误:‘Elf32_Ehdr’没有名为‘e_ehsize’的成员
img2srec.c:302: 错误:‘Elf32_Ehdr’没有名为‘e_phentsize’的成员
img2srec.c:303: 错误:‘Elf32_Ehdr’没有名为‘e_phnum’的成员
img2srec.c:304: 错误:‘Elf32_Ehdr’没有名为‘e_shentsize’的成员
img2srec.c:305: 错误:‘Elf32_Ehdr’没有名为‘e_shnum’的成员
img2srec.c:306: 错误:‘Elf32_Ehdr’没有名为‘e_shstrndx’的成员
img2srec.c:312: 错误:‘Elf32_Ehdr’没有名为‘e_type’的成员
img2srec.c:314: 警告:隐式声明函数‘fclose’
img2srec.c:315: 警告:隐式声明与内建函数‘fprintf’不兼容
img2srec.c:320: 警告:隐式声明函数‘fseek’
img2srec.c:320: 错误:‘Elf32_Ehdr’没有名为‘e_shoff’的成员
img2srec.c:320: 错误:‘SEEK_SET’未声明(在此函数内第一次使用)
img2srec.c:321: 错误:‘Elf32_Ehdr’没有名为‘e_shnum’的成员
img2srec.c:323: 错误:expected expression before ‘)’ token
img2srec.c:324: 错误:expected expression before ‘)’ token
img2srec.c:325: 错误:expected expression before ‘)’ token
img2srec.c:326: 错误:expected expression before ‘)’ token
img2srec.c:327: 错误:expected expression before ‘)’ token
img2srec.c:328: 错误:expected expression before ‘)’ token
img2srec.c:329: 错误:expected expression before ‘)’ token
img2srec.c:330: 错误:expected expression before ‘)’ token
img2srec.c:331: 错误:expected expression before ‘)’ token
img2srec.c:332: 错误:expected expression before ‘)’ token
img2srec.c:335: 警告:隐式声明与内建函数‘fprintf’不兼容
img2srec.c:340: 警告:隐式声明函数‘strrchr’
img2srec.c:340: 警告:隐式声明与内建函数‘strrchr’不兼容
img2srec.c:346: 警告:隐式声明函数‘BuildSRecord’
img2srec.c:346: 错误:expected expression before ‘)’ token
img2srec.c:347: 警告:隐式声明函数‘printf’
img2srec.c:347: 警告:隐式声明与内建函数‘printf’不兼容
img2srec.c:350: 错误:‘firstAddr’未声明(在此函数内第一次使用)
img2srec.c:351: 错误:‘loadAddr’未声明(在此函数内第一次使用)
img2srec.c:352: 错误:‘Elf32_Ehdr’没有名为‘e_shnum’的成员
img2srec.c:353: 错误:‘Elf32_Shdr’没有名为‘sh_type’的成员
img2srec.c:354: 错误:‘Elf32_Shdr’没有名为‘sh_size’的成员
img2srec.c:356: 错误:‘loadSize’未声明(在此函数内第一次使用)
img2srec.c:356: 错误:‘Elf32_Shdr’没有名为‘sh_size’的成员
img2srec.c:357: 错误:‘Elf32_Shdr’没有名为‘sh_flags’的成员
img2srec.c:358: 错误:‘Elf32_Shdr’没有名为‘sh_addr’的成员
img2srec.c:359: 错误:‘loadDiff’未声明(在此函数内第一次使用)
img2srec.c:359: 错误:‘Elf32_Shdr’没有名为‘sh_offset’的成员
img2srec.c:362: 错误:‘Elf32_Shdr’没有名为‘sh_offset’的成员
img2srec.c:369: 错误:‘Elf32_Shdr’没有名为‘sh_size’的成员
img2srec.c:370: 错误:‘Elf32_Shdr’没有名为‘sh_offset’的成员
img2srec.c:375: 警告:隐式声明与内建函数‘fprintf’不兼容
img2srec.c:378: 错误:‘loadOffset’未声明(在此函数内第一次使用)
img2srec.c: 在函数‘main’中:
img2srec.c:399: 错误:‘DWORD’未声明(在此函数内第一次使用)
img2srec.c:399: 错误:expected ‘;’ before ‘offset’
img2srec.c:402: 错误:提供给函数‘ConvertELF’的实参太多
img2srec.c:404: 警告:隐式声明函数‘strcmp’
img2srec.c:405: 警告:隐式声明函数‘ExtractNumber’
img2srec.c:405: 错误:‘offset’未声明(在此函数内第一次使用)
img2srec.c:406: 错误:提供给函数‘ConvertELF’的实参太多
img2srec.c:409: 警告:隐式声明与内建函数‘fprintf’不兼容
img2srec.c:409: 错误:‘stderr’未声明(在此函数内第一次使用)
make[1]: *** [img2srec.o] 错误 1
make[1]: 离开目录“/opt/FriendlyARM/mini6410/linux/u-boot-mini6410/tools”
make: *** [tools] 错误 2