开发环境
SDK版本0.1.0a
itx-3588j机器上编译
编译步骤:
-
更新代码
.repo/repo/repo sync -l
./repo/repo/repo start rk3588/firefly --all -
选择板卡
./build.sh itx-3588j-ubuntu.mk -
修改内核配置
先生成一个默认配置文件
make ARCH=arm64 rockchip_linux_defconfig firefly-linux.config
修改配置
make ARCH=arm64 menuconfig -
编译内核,生成img文件
./build.sh extboot
1)gcc编译报错
arch/arm64/Makefile:25: ld does not support --fix-cortex-a53-843419; kernel may be susceptible to erratum
scripts/gcc-version.sh: 20: printf:-E: expected numeric
scripts/gcc-version.sh: 20: printf;-x: expected numeric
0.1.0a版本SDK中自带的gcc编译器是x86上使用的交叉编译器,我的做法是直接把 prebuilts/gcc下的linux-x86挪到别的地方,然后编译的时候就会自动搜索系统中的gcc
2)/bin/sh: 1: ./scripts/lz4: Exec format error
把kernel/scripts下原本的lz4删除,重新下载一个lz4 链接到这个位置
比如:
ln -s /usr/bin/lz4 (原本sdk中lz4路径)/lz4
3)mkfs.ext4报错
同理 把原本device/rockchip/common中mkfs.ext4删除,并重新安装e2fsprogs,并链接到该位置
e2fsprogs源码包:
https://sourceforge.net/projects/e2fsprogs