During development process, you would typically use plain make with no particular target to compile Android sources. (See Build your custom Android images.) However, when you prepare for release, you must use the target dist to generate the proper release images. To do so, follow these steps:
-
Set up your environment and install the sources. If you have not already done so, see Set up your development computer.
-
Change to the directory where the source code is installed.
$ cd dea-8.0-r1
-
Initialize the build environment:
$ source build/envsetup.sh
-
Select a ConnectCore 6 target to build:
-
ccimx6sbc-eng creates development images with root access and additional debugging tools.
-
ccimx6sbc-user creates images with no root access, suitable for production.
Information about the selected target is displayed:
$ lunch ccimx6sbc-eng ============================================ PLATFORM_VERSION_CODENAME=REL PLATFORM_VERSION=8.0.0 TARGET_PRODUCT=ccimx6sbc TARGET_BUILD_VARIANT=eng TARGET_BUILD_TYPE=release TARGET_PLATFORM_VERSION=OPD1 TARGET_BUILD_APPS= TARGET_ARCH=arm TARGET_ARCH_VARIANT=armv7-a-neon TARGET_CPU_VARIANT=cortex-a9 TARGET_2ND_ARCH= TARGET_2ND_ARCH_VARIANT= TARGET_2ND_CPU_VARIANT= HOST_ARCH=x86_64 HOST_2ND_ARCH=x86 HOST_OS=linux HOST_OS_EXTRA=Linux-4.15.0-34-generic-x86_64-with-Ubuntu-18.04-bionic HOST_CROSS_OS=windows HOST_CROSS_ARCH=x86 HOST_CROSS_2ND_ARCH=x86_64 HOST_BUILD_TYPE=release BUILD_ID=dea-8.0-r1.1 OUT_DIR=out AUX_OS_VARIANT_LIST= ============================================ $
-
-
Use dist target to generate the release images:
$ make -j<Number_Of_Jobs> dist
It compiles the whole source tree, as a plain make does. Then it generates several zip files inside the out/dist folder of the dea-8.0-r1 directory:
-
ccimx6sbc-ota-<build_id>.zip is the update package that can be installed through recovery. The package contains all the files needed by system, boot, vendor, and recovery partition.
-
ccimx6sbc-target_files-<build_id>.zip contains all the target files (apk, binaries, libraries, etc.) that will go into the final release package.
-
ccimx6sbc-apps-<build_id>.zip contains all the apks.
-
ccimx6sbc-img-<build_id>.zip contains image files for system, boot, vendor, and recovery.
-
ccimx6sbc-symbols-<build_id>.zip contains all files in out/target/product/ccimx6sbc/symbols.
The file ccimx6sbc-img-<build_id>.zip includes the release system, boot, vendor and recovery images.
-
To program these files into your ConnectCore 6, follow the steps in Program the firmware from U-Boot using uSD. |