Download and Build

The Trusty repositories are available in the Android Open Source Project (AOSP).

Use these links to find the appropriate Trusty kernel branches in AOSP:

Installing Repo

To download Trusty, first download and install Repo.

After Repo has been successfully installed you can clone the Android Trusty repository.

mkdir trusty
cd trusty
repo init -u -b master
repo sync -j32


Use the following to build the generic arm64 image for Trusty.

./trusty/vendor/google/aosp/scripts/ generic-arm64

Build results will be under build-root/build-generic-arm64/. Look for lk.bin which is a TEE image with all apps compiled in:

ls build-root/build-generic-arm64/lk.bin


You can assemble lk.bin into a firmware image and flash it to the device. Generating firmware images varies depending on the board being used. Contact your board manufacturer for instructions.