Building uboot/kernel/test-application out of Yocto

Document created by Gopise Yuan Employee on Aug 19, 2015Last modified by Gopise Yuan Employee on Jan 12, 2016
Version 2Show Document
  • View in full screen mode

Before reading: only a personal works and sharing, not any form of "release". I didn't find any confidential information from the packages. So, I'm publishing it here.

This is only for testing purpose. Do NOT use it for building a product. Use it at your own risk!!


Yocto is flexible and powerful, and also, big and slow (when building). Sometimes we only need to build uboot or kernel or some piece of testing code. It's really a waste of time to build-up the whole Yocto environment which may cost over 50GB disk space and over 3 hours of building.

I've made some scripts and sum them up to form a toolset for building uboot, kernel and some testing code out of Yocto environment. It's only a simple container and expect to use with uboot and kernel source code from formal Freescale release and a SDK built from Yocto project.


Attachment in this post:

     "gopbuild-v1.2.tgz": The "container-only" package for this tool.

     "": A guide for how to integrating source code and SDK.

     "": A readme for this tool. Some basic introduction inside. The usage can also be found from it.


What’s made off (a full package, not only the container):

1.    Some scripts and configurations files.

2.    SDK built from Yocto.

3.    Uboot/kernel from specific version.

4.    A hello-world to demonstrate how to build app in this environment.

5.    A slimmed rootfs binary from specific BSP pre-built as base. Will customize base on the source under “rootfs” folder. Only a placeholder in the container-only version.


How to use it:

Several common used board configurations have been included in the script: 6qsabresd/6qsabreai/6qpsabreai. You can add more into the “gopbuild” script easily. The “sabresd” has been set as default.

     If you want to build all for sabresd (First of all, de-compress the package):

cd <de-compressed-folder>
source envsetup

     If you want to build specific module for default board, such as uboot:

gmk uboot

     Build kernel for sabreai board instead of default device:

gmk kernel sabreai

     Clean everything?

gmk all clean

After a successfully full build, you will get everything under “output” folder, including a log folder contains full build log:

     “u-boot.imx/zImage/rootfs.tar.bz2/*.dtb”, can be used with MFG.

     “fsl-image.sdcard”, can be burn into SD card directly.


"Ready-for-build" Package:

The "gopbuild-v1.2.tgz" attached in this post is a "container-only" package which doesn't contain any source or SDK.

I've also made some packages based on latest BSP release for i.MX6. These packages are "ready-for-build" package which you can de-compress and build it directly.



Password: 1b8c



     This is based on i.MX6 3.10.53-1.1.0-GA Yocto release.


     This is based on i.MX6 3.14.28-1.0.0-GA Yocto release.

All material (uboot/kernel/test code and SDK) are from official release. The SDK is built with: “core-image-minimal” + “kernel-dev imx-kobs-dev imx-lib-dev imx-vpu-dev" (enable access to kernel header and ipu/vpu/…”. No GPU support.



1 person found this helpful