Centos7 编译Android7.1_Industry烧录后启动错误
Centos7安装必要的开发环境后,执行./FFTools/make.sh-d rk3399-firefly-face-mipi8 -j8 -l rk3399_firefly_face-userdebug
./FFTools/mkupdate/mkupdate.sh -l rk3399_firefly_face-userdebug
完成编译,烧录固件后,启动失败,串口输出
#Boot ver: 2021-05-07#1.26
empty serial no.
normal boot.
checkKey
vbus = 1
no fuel gauge found
no fuel gauge found
read logo on state from dts
no fuel gauge found
got recovery cmd from misc.
load fdt from resouce.
hwversion: can't find dts node for version
Secure Boot state: 0
kernel @ 0x00280000 (0x01376808)
ramdisk@ 0x04bf0000 (0x00755a04)
bootrk: do_bootm_linux...
ERROR: image is not a fdt - must RESET the board to recover.
FDT creation failed! hanging...### ERROR ### Please RESET the board ###
提示fdt,error,使用官方镜像解包后的resource.img,单独下载,启动成功
请问,出现此问题原因是 hwversion: can't find dts node for version
是否同步sdk到最新 本帖最后由 szzhangzhen 于 2021-5-8 10:54 编辑
已经使用git clone https://gitlab.com/TeeFirefly/rk3399-industry-nougat-bundle.git .bundle
.bundle/update
git rebase FETCH_HEAD
同步至最新
单独编译kernel,发现dtb无法打包至resource
,
导致,resource.img只有2K
szzhangzhen 发表于 2021-5-8 10:48
已经使用git clone https://gitlab.com/TeeFirefly/rk3399-industry-nougat-bundle.git .bundle
.bundle ...
那应该是环境的问题导致,要么安装ubuntu进行编译试一下,要么在当前的编译环境下解决为什么resource.img出错的问题 又安装了一下编译依赖,问题解决,具体是哪个编译依赖导致,未知{:5_241:} 这个问题,在编译其他厂家提供的Android8.1,再一次出现,安装各种编译环境依赖仍无法解决,花了2天时间,终于定位到了问题所在,解决方法如下:
1、编译Kernel,出现:E/get_file_size(316): Failed to get size
E/get_file_size(316): Failed to get size:./arch/arm/boot/dts/pro-rk3288.dtb
E/get_file_size(316): Failed to get size:./arch/arm/boot/dts/pro-rk3288.dtb
E/get_file_size(316): Failed to get size:logo.bmp
E/get_file_size(316): Failed to get size:logo.bmp
E/get_file_size(316): Failed to get size:logo_kernel.bmp
E/get_file_size(316): Failed to get size:logo_kernel.bmp
追踪源码发现,为resource_tool.c下的stat函数获取文件长度失败导致
(原因:部分平台不支持stat64,需将gcc编译命令加上-D_FILE_OFFSET_BITS=64)
解决方法:
cd u-boot/tools/resource_tool
vim Makefile
- #CFLAGS = -fshort-wchar -m32 -ffunction-sections -Os
+ CFLAGS = -D_FILE_OFFSET_BITS=64 -fshort-wchar -m32 -ffunction-sections -Os
重新编译resource_tool,编译后的resource_tool替换kernel/scripts/resource_tool即可
然后./build.sh kernel重新编译内核
页:
[1]