“固件构建指南——环境搭建与编译步骤”的版本间的差异
第13行: | 第13行: | ||
(对于A133:Linux BSP更名为Longan,注意辨别!) | (对于A133:Linux BSP更名为Longan,注意辨别!) | ||
+ | |||
+ | ==源码结构== | ||
+ | 对于A33/A64/A40i: | ||
+ | |||
+ | SPL(底层引导代码):lichee/brandy | ||
+ | |||
+ | U-Boot:lichee/brandy/uboot-xxxx.xx | ||
+ | |||
+ | Linux内核:lichee/linux-3.x | ||
+ | |||
+ | 系统配置(env.txt和fex文件等):lichee/tools/pack/chips/sunxiwxpx/config | ||
+ | |||
+ | Android源码:android | ||
+ | |||
+ | |||
+ | 对于A133: | ||
+ | |||
+ | SPL(底层引导代码):longan/brandy | ||
+ | |||
+ | U-Boot:longan/brandy/uboot-xxxx.xx | ||
+ | |||
+ | Linux内核:longan/kernel/linux-4.9 | ||
+ | |||
+ | 系统配置(env.txt和fex文件等):longan/device/config/chips/a100/config | ||
+ | |||
+ | Android源码:android | ||
+ | |||
+ | ==编译U-Boot== | ||
+ | 默认无需编译。若要修改U-Boot,编译方法如下: | ||
+ | |||
+ | 在brandy/uboot-xxxx.xx目录下执行: | ||
+ | |||
+ | 对于A33:make distclean & make sun8iw5p1 -j16 | ||
+ | |||
+ | 对于A64:make distclean & make sun50iw1p1_config & make -j16 | ||
+ | |||
+ | 对于A40i:make distclean & make sun8iw11p1_config & make -j16 | ||
+ | |||
+ | 对于A133:make distclean & make sun50iw10p1_config & make -j16 | ||
+ | |||
+ | (编译生成的相关bin文件会自动拷贝到打包目录下) | ||
+ | |||
+ | ==编译Lichee/Longan== | ||
+ | 初次编译请先配置编译选项,在lichee/longan目录下执行: | ||
+ | |||
+ | $ ./build.sh config | ||
+ | |||
+ | 会依次显示若干选项,输入对应的数字按回车选择对应的选项,最终完成配置。 | ||
+ | |||
+ | 对于A33:依次选 | ||
+ | |||
+ | 对于A64:依次选 0.sun50iw1p1 -> 0.android -> 0.linux-3.10 -> 2.p2 | ||
+ | |||
+ | 对于A64:依次选 0.sun8iw11p1 -> 1.androidm -> 0.linux-3.10 -> 0.a40-p1 | ||
+ | |||
+ | 对于A133:依次选 0.android -> 0.a100 -> 2.c3 | ||
+ | |||
+ | ==编译Android并打包== | ||
+ | |||
=常见问题= | =常见问题= |
2021年12月5日 (日) 19:58的版本
编译环境搭建
编译步骤
解压源代码
解压Lichee(Linux BSP)部分到当前目录:
$ tar -zxvf lichee.tar.gz -C .
解压Android部分到当前目录:
$ tar -zxvf android.tar.gz -C .
(对于A133:Linux BSP更名为Longan,注意辨别!)
源码结构
对于A33/A64/A40i:
SPL(底层引导代码):lichee/brandy
U-Boot:lichee/brandy/uboot-xxxx.xx
Linux内核:lichee/linux-3.x
系统配置(env.txt和fex文件等):lichee/tools/pack/chips/sunxiwxpx/config
Android源码:android
对于A133:
SPL(底层引导代码):longan/brandy
U-Boot:longan/brandy/uboot-xxxx.xx
Linux内核:longan/kernel/linux-4.9
系统配置(env.txt和fex文件等):longan/device/config/chips/a100/config
Android源码:android
编译U-Boot
默认无需编译。若要修改U-Boot,编译方法如下:
在brandy/uboot-xxxx.xx目录下执行:
对于A33:make distclean & make sun8iw5p1 -j16
对于A64:make distclean & make sun50iw1p1_config & make -j16
对于A40i:make distclean & make sun8iw11p1_config & make -j16
对于A133:make distclean & make sun50iw10p1_config & make -j16
(编译生成的相关bin文件会自动拷贝到打包目录下)
编译Lichee/Longan
初次编译请先配置编译选项,在lichee/longan目录下执行:
$ ./build.sh config
会依次显示若干选项,输入对应的数字按回车选择对应的选项,最终完成配置。
对于A33:依次选
对于A64:依次选 0.sun50iw1p1 -> 0.android -> 0.linux-3.10 -> 2.p2
对于A64:依次选 0.sun8iw11p1 -> 1.androidm -> 0.linux-3.10 -> 0.a40-p1
对于A133:依次选 0.android -> 0.a100 -> 2.c3