Thursday, October 27, 2016

Build the Android Source for helios x20

  Image result for helio x20


Please refer to AOSP website and follow all the instruction mentioned there. Read and prepare carefully through the link, .

Pay attention to the following key points:

GUN/Linux distribution selecting: We strongly recommend you install Ubuntu 14.04 (Trusty) to  build the environment;
Java Development Kit (JDK): OpenJDK 7 for Android 6.0 (Marshmallow) on Ubuntu;
Device binaries: MediaTek X20 SLA source part including the device binaries;

Establishing a Build Environment

Refer to AOSP website ( ) and follow the below key points:

The Android build is routinely tested in house on recent versions of Ubuntu LTS (14.04)
Installing the JDK 7

$ sudo apt-get update
$ sudo apt-get install openjdk-7-jdk

Installing required packages

$ sudo apt-get install git-core gnupg flex bison gperf build-essential \
  zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 \
  lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev ccache \
  libgl1-mesa-dev libxml2-utils xsltproc unzip

Using a separate output directory

$ export OUT_DIR_COMMON_BASE=<path-to-your-out-directory>

Downloading the Source

Refer to AOSP website ( ) and follow the below key points:

Installing Repo

$ mkdir ~/bin
$ PATH=~/bin:$PATH
$ curl  > ~/bin/repo
$ chmod a+x ~/bin/repo

Downloading the AOSP

$ mkdir ~/develop/x20
$ cd ~/develop/x20
$ repo init -u  -b android-6.0.0_r1
$ epo sync –j8

Downloading Linux Kernel

$ cd ~/develop
$ git clone

Downloading MediaTek SLA

$ cd ~/develop
$ curl

 Merge the Source

$ cd ~/develop
$ mv linux ~/develop/x20/kernel-3.18
$ tar vxfz sla.tar.gz
$ cp –rf sla/* ~/develop/x20/

Build the Android Source

Refer to AOSP website ( ) and follow the below key points:

Clean up

$ make clobber

Set up environment

$ source build/

Choose a target

$ lunch full_amt6796_64_open-eng

Build the code

Build everything with make. GNU make can handle parallel tasks with a -jN argument, and it's common to use a number of tasks N that's between 1 and 2 times the number of hardware threads on the computer being used for the build. For example, on a dual-E5520 machine (2 CPUs, 4 cores per CPU, 2 threads per core), the fastest builds are made with commands between make -j16 and make -j32.

$ make -j8

or make one by one manually

$ make pl -j8
$ make lk -j8
$ make kernel -j8
$ make bootimage -j8
$ make systemimage -j8

Note that, the Android OS for x20 96Boards is open source, but excluding HAL part, and the preloader part.

So, there is no need to execute "$ make pl -j8".

Images in the out directory


Follow up with next blog to know how to install android on the board