03-Android_SDK_Compilation
SDK Overview
Version Information
Kernel version: 5.4
Android OS version: 12.0
Obtaining the SDK Source Code
Network Disk Download Directory:
Copy the source code archive to the compilation host:
Notes:
Do not compile the source code in a shared directory.
Do not use the ROOT account to log in to the compilation host.
Verify file integrity with MD5:
Extract the source code archive:
After extraction, only the
.git
folder will be visible. Proceed to the next step to fully restore the source code.
Restore the source code using Git:
Initial Compilation Environment Setup
First-time compilation requires environment configuration. Skip this step if the SDK location remains unchanged.
Select the following configurations:
Return to the previous directory:
Select the Target Board:
Note:
BoardConfig-kickpi-'board'-'desktop'
board
: Options includek2b
/k2c
desktop
: Options includetv
/tablet
Compile the Full Image
Output directory:
longan/out/h618_android12_p2_uart0.img
Troubleshooting: If the Android compilation fails without clear errors, reduce the parallel build processes in
build.sh
(e.g., changemake -j32
tomake -j8
based on your hardware).
Compile Partition Images Separately
Compile U-Boot Only:
Output directory:
longan/out/h618_android12_p2_uart0.img
Compile Kernel Only:
Output directory:
longan/out/h618_android12_p2_uart0.img
Compile Android Only:
Output directory:
longan/out/h618_android12_p2_uart0.img
Configure the Kernel
Notes
Ensure the compilation environment has sufficient disk space and memory.
Use
git pull
regularly to update the SDK source code.Generated images can be flashed to the target device using tools like
PhoenixSuit
orFastboot
.
Last updated