Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Version History

« Previous Version 2 Next »

Building a custom Android 11 for SECO board is a simple operation.

In the following instructions, we consider the specific case of C31, SECO SBC based on RK339 from Rockchip. Therefore at the moment “C31” is the only valid value for <BOARD_CODE>.

Requirements:

  • a powerful PC HOST with Linux OS system (Ubuntu, Debian, ARCH Linux are valid options);

  • a docker environment installed and running;

  • a configured git and repo environment;

  • 250 GB of free space on storage drive;

Detailed procedure:

  • Configure git:

    • git config --global user.name "Your Name"

    • git config --global user.email "your.name@example.com"

  • Init and download Android 11 repository:

    • mkdir ANDROID_11

    • cd ANDROID_11

    • repo init -u ssh://git@git.seco.com/arm/rockchip/release/android_11.0.0/manifest.git

    • repo sync -j 20

  • Pull the latest SECO docker for Android building image:

    • sudo docker pull secodocker/android-builder:latest

  • Run SECO docker for Android build:

    • docker run --rm -it \
          --privileged \
          --volume="/etc/passwd:/etc/passwd:ro" \
          --volume="/etc/group:/etc/group:ro" \
          --volume="/etc/shadow:/etc/shadow:ro"  \
          --volume $PWD:/workdir \
          -v ~/.bash_history:${HOME}/.bash_history:rw \
          -v ~/.vimrc:${HOME}/.vimrc:rw \
          -v ~/.vim:${HOME}/.vim:rw \
          -v ~/.cache:${HOME}/.cache:rw \
          -e BOARDCODE=${boardcode} \
          --workdir="/workdir" \
          --user $(id -u "$(stat -c "%U" Android.bp)"):$(id -g) \
          secodocker/android-builder:latest

  • Set up the Android environment and run the build commands:

    • source setup<BOARD_CODE> # for example: source setupC31

    • ./build.sh -f

  • Wait until the end of the compilation process (build process can last 1 or more hours according to the speed of your system)

  • You can produce a tar.gz archive to be used for installation by running the following script:

    • prepare_distro.sh [<IMAGE_NAME>] # Where [<IMAGE_NAME>] is an optional text string for naming the image file (default to “Android_11_<BOARD_CODE>_Distro_<DATE>.tar.gz”)

  • You will find the results of the build process in the folder ANDROID_11/Distros/

The freshly created distro includes everything you need to flash the board:

  • system binaries (bootloader, kernel, support partition images, android system…)

  • flashing tool and script to launch it easily

  • otapackage to update an already working board

  • No labels