Rate This Document
Findability
Accuracy
Completeness
Readability

Downloading AOSP Source Code

The Kbox Android image is compiled using AOSP 11. Perform the following steps to download the AOSP source code.

  1. Create an aosp directory in the user directory and grant the read, write, and execute permissions to the directory owner.
    1
    2
    mkdir ~/aosp
    chmod -R 700 ~/aosp
    

    The remaining space of the user directory must be greater than 300 GB. The AOSP source code is approximately 130 GB and is close to 300 GB after compilation.

  2. Download and install the Repo tool following the official Google guide. Download AOSP source code (version: android-11.0.0_r48) and compile it.
    1
    2
    3
    cd ~/aosp
    repo init -u https://android.googlesource.com/platform/manifest -b android-11.0.0_r48
    repo sync
    
  3. In the aosp directory, delete the external/mesa3d, external/libdrm, and device/generic/arm64 folders from the source code.
    1
    2
    cd ~/aosp
    rm -rf external/mesa3d external/libdrm device/generic/arm64