5.3.4. Running a Build on the Recipe

Creating a new recipe is usually an iterative process that requires using BitBake to process the recipe multiple times in order to progressively discover and add information to the recipe.

Assuming you have sourced a build environment setup script (i.e. oe-init-build-env or oe-init-build-env-memres) and you are in the Build Directory, use BitBake to process your recipe. All you need to provide is the <basename> of the recipe as described in the previous section:

     $ bitbake <basename>
                

During the build, the OpenEmbedded build system creates a temporary work directory for the recipe (${WORKDIR}) where it keeps extracted source files, log files, intermediate compilation and packaging files, and so forth.

The temporary work directory is constructed as follows and depends on several factors:

     ${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}
                

As an example, assume a Source Directory top-level folder named poky, a default Build Directory at poky/build, and a qemux86-poky-linux machine target system. Furthermore, suppose your recipe is named foo_1.3.0-r0.bb. In this case, the work directory the build system uses to build the package would be as follows:

     poky/build/tmp/work/qemux86-poky-linux/foo/1.3.0-r0
                

Inside this directory you can find sub-directories such as image, packages-split, and temp. After the build, you can examine these to determine how well the build went.

Note

You can find log files for each task in the recipe's temp directory (e.g. poky/build/tmp/work/qemux86-poky-linux/foo/1.3.0-r0/temp). Log files are named log.<taskname> (e.g. log.do_configure, log.do_fetch, and log.do_compile).

You can find more information about the build process in the "A Closer Look at the Yocto Project Development Environment" chapter of the Yocto Project Reference Manual.

You can also reference the following variables in the Yocto Project Reference Manual's glossary for more information: