zq9610 发表于 2015-1-21 21:32:11

求助:编译Linux3.4内核失败

本帖最后由 zq9610 于 2015-1-21 21:40 编辑

编译环境:Ubuntu12.04 LTS 64bit(运行于PD虚拟机上)
目标板:CB2
编译过程:
/lichee/linux-3.4$ make clean
/lichee/linux-3.4$ sudo cp arch/arm/configs/sun7ismp_android_defconfig .config
/lichee/linux-3.4$ cd ..
/lichee$ ./build.sh -p sun7i_android




我就没有成功编译出Android一次。。好忧桑

到底哪儿出问题了呢 大家帮忙看看

有两个错误的地方:OBJCOPY arch/arm/boot/zImage
Kernel: arch/arm/boot/zImage is ready
UIMAGEarch/arm/boot/uImage
/usr/bin/mkimage: Can't map arch/arm/boot/uImage: Invalid argument
make: *** 错误 1
make: *** 错误 2
make: *** 正在等待未完成的任务....
WARNING: modpost: Found 2 section mismatch(es).
To see full details build your kernel with:
'make CONFIG_DEBUG_SECTION_MISMATCH=y'LD drivers/net/wireless/rtl8189es/8189es.ko
arm-linux-gnueabi-ld: warning: drivers/net/wireless/bcm4330/bcm4330.mod.o uses 4-byte wchar_t yet the output is to use 2-byte wchar_t; use of wchar_t values across objects may fail
LD drivers/net/wireless/rtl8192cu/8192cu.ko
LD drivers/net/wireless/rtl8723as/8723as.ko
LD drivers/scsi/scsi_wait_scan.ko
LD drivers/video/sun7i/disp/disp.ko
LD drivers/video/sun7i/lcd/lcd.ko
ERROR: build kernel Failed

jiangdou 发表于 2015-1-21 21:46:28

本帖最后由 jiangdou 于 2015-1-21 21:54 编辑

/lichee/linux-3.4$ make mrproper
/lichee/linux-3.4$ cp arch/arm/configs/cubieboard_xxx .config
/lichee$./build.sh -p sun7i_android
再试试

zq9610 发表于 2015-1-21 23:08:54

jiangdou 发表于 2015-1-21 21:46 static/image/common/back.gif
/lichee/linux-3.4$ make mrproper
/lichee/linux-3.4$cp arch/arm/configs/cubieboard_xxx .config
/lic ...

忘了说了,我用的4.4的源码,你可以在这里下载:
http://yunpan.cn/cKgKC6uZmLUTk提取码 4dd3

把422的配置拷贝过来还是不行,依旧出错,arch/arm/mach-sun7i/core.c: In function ‘sun7i_reserve’:
arch/arm/mach-sun7i/core.c:164:34: error: ‘ION_CARVEOUT_MEM_BASE’ undeclared (first use in this function)
arch/arm/mach-sun7i/core.c:164:34: note: each undeclared identifier is reported only once for each function it appears in
make: *** 错误 1
make: *** 错误 2
make: *** 正在等待未完成的任务....
CC      arch/arm/kernel/armksyms.o
CC      arch/arm/mm/vmregion.o
CC      arch/arm/mm/rodata.o
CC      arch/arm/kernel/module.o
arch/arm/mm/rodata.c: In function ‘set_page_attributes’:
arch/arm/mm/rodata.c:91:4: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 4 has type ‘pmd_t’ [-Wformat]
页: [1]
查看完整版本: 求助:编译Linux3.4内核失败