Skip to content

Build Environment

Set up the environment on a PC to compile the Android/Linux SDK.

Preparation

Install Ubuntu on a PC for SDK compilation.

  • Hardware: PC with RAM ≥ 16 GB, CPU cores ≥ 4, Hard Drive ≥ 500GB
  • Software: Ubuntu 22.04, allocate ≥ 200GB disk space if you are using virtual machine ENV

Dependency Installation

  1. Open the Terminal, and switch to root user or use sudo.

  2. Enter the following commands sequentially to install the dependencies.

    sudo apt install git bc bison build-essential curl flex libsdl1.2-dev
    sudo apt install g++-multilib gcc-multilib gnupg gperf libncurses5-dev
    sudo apt install imagemagick lib32ncurses5-dev lib32readline-dev squashfs-tools
    sudo apt install lib32z1-dev liblz4-tool xsltproc libssl-dev libwxgtk3.0-gtk3-dev
    sudo apt install libxml2 libxml2-utils schedtool lzop pngcrush rsync
    sudo apt install yasm zip zlib1g-dev python3 device-tree-compiler
    sudo apt install python-pip gawk openjdk-8-jdk u-boot-tools patchelf expect
    sudo pip install pyelftools
    

Q&A

  • Cannot open Terminal in Ubuntu 22.04?

    Press ++Ctrl+Alt+F3++ on the virtual machine screen to enter the command line mode, then follow the operations shown in the diagram.

    cd /etc/default
    nano locale
    

    Change en_US to en_US.UTF-8, save and exit, then type reboot to restart.