The first stages of building a recipe are to fetch and unpack the source code:
The
do_fetch
and
do_unpack
tasks fetch the source files and unpack them into the work
directory.
file://
)
that is part of a recipe's
SRC_URI
statement, the OpenEmbedded build system takes a checksum
of the file for the recipe and inserts the checksum into
the signature for the do_fetch
.
If any local file has been modified, the
do_fetch
task and all tasks that
depend on it are re-executed.
By default, everything is accomplished in the
Build Directory,
which has a defined structure.
For additional general information on the Build Directory,
see the
"build/
"
section in the Yocto Project Reference Manual.
Unpacked source files are pointed to by the
S
variable.
Each recipe has an area in the Build Directory where the
unpacked source code resides.
The name of that directory for any given recipe is defined from
several different variables.
You can see the variables that define these directories
by looking at the figure:
TMPDIR
-
The base directory where the OpenEmbedded build system
performs all its work during the build.
PACKAGE_ARCH
-
The architecture of the built package or packages.
TARGET_OS
-
The operating system of the target device.
PN
-
The name of the built package.
PV
-
The version of the recipe used to build the package.
PR
-
The revision of the recipe used to build the package.
WORKDIR
-
The location within TMPDIR
where
a specific package is built.
S
-
Contains the unpacked source files for a given recipe.