Yocto 2.4
Move OpenBMC to Yocto 2.4(rocko)
Tested: Built and verified Witherspoon and Palmetto images
Change-Id: I12057b18610d6fb0e6903c60213690301e9b0c67
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/closer-look.xml b/import-layers/yocto-poky/documentation/ref-manual/closer-look.xml
deleted file mode 100644
index 923ed21..0000000
--- a/import-layers/yocto-poky/documentation/ref-manual/closer-look.xml
+++ /dev/null
@@ -1,1630 +0,0 @@
-<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
-"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
-[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
-
-<chapter id='closer-look'>
-<title>A Closer Look at the Yocto Project Development Environment</title>
-
- <para>
- This chapter takes a more detailed look at the Yocto Project
- development environment.
- The following diagram represents the development environment at a
- high level.
- The remainder of this chapter expands on the fundamental input, output,
- process, and
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>) blocks
- in the Yocto Project development environment.
- </para>
-
- <para id='general-yocto-environment-figure'>
- <imagedata fileref="figures/yocto-environment-ref.png" align="center" width="8in" depth="4.25in" />
- </para>
-
- <para>
- The generalized Yocto Project Development Environment consists of
- several functional areas:
- <itemizedlist>
- <listitem><para><emphasis>User Configuration:</emphasis>
- Metadata you can use to control the build process.
- </para></listitem>
- <listitem><para><emphasis>Metadata Layers:</emphasis>
- Various layers that provide software, machine, and
- distro Metadata.</para></listitem>
- <listitem><para><emphasis>Source Files:</emphasis>
- Upstream releases, local projects, and SCMs.</para></listitem>
- <listitem><para><emphasis>Build System:</emphasis>
- Processes under the control of
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>.
- This block expands on how BitBake fetches source, applies
- patches, completes compilation, analyzes output for package
- generation, creates and tests packages, generates images, and
- generates cross-development tools.</para></listitem>
- <listitem><para><emphasis>Package Feeds:</emphasis>
- Directories containing output packages (RPM, DEB or IPK),
- which are subsequently used in the construction of an image or
- SDK, produced by the build system.
- These feeds can also be copied and shared using a web server or
- other means to facilitate extending or updating existing
- images on devices at runtime if runtime package management is
- enabled.</para></listitem>
- <listitem><para><emphasis>Images:</emphasis>
- Images produced by the development process.
- </para></listitem>
- <listitem><para><emphasis>Application Development SDK:</emphasis>
- Cross-development tools that are produced along with an image
- or separately with BitBake.</para></listitem>
- </itemizedlist>
- </para>
-
- <section id="user-configuration">
- <title>User Configuration</title>
-
- <para>
- User configuration helps define the build.
- Through user configuration, you can tell BitBake the
- target architecture for which you are building the image,
- where to store downloaded source, and other build properties.
- </para>
-
- <para>
- The following figure shows an expanded representation of the
- "User Configuration" box of the
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>:
- </para>
-
- <para>
- <imagedata fileref="figures/user-configuration.png" align="center" />
- </para>
-
- <para>
- BitBake needs some basic configuration files in order to complete
- a build.
- These files are <filename>*.conf</filename> files.
- The minimally necessary ones reside as example files in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
- For simplicity, this section refers to the Source Directory as
- the "Poky Directory."
- </para>
-
- <para>
- When you clone the <filename>poky</filename> Git repository or you
- download and unpack a Yocto Project release, you can set up the
- Source Directory to be named anything you want.
- For this discussion, the cloned repository uses the default
- name <filename>poky</filename>.
- <note>
- The Poky repository is primarily an aggregation of existing
- repositories.
- It is not a canonical upstream source.
- </note>
- </para>
-
- <para>
- The <filename>meta-poky</filename> layer inside Poky contains
- a <filename>conf</filename> directory that has example
- configuration files.
- These example files are used as a basis for creating actual
- configuration files when you source the build environment
- script
- (i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
- </para>
-
- <para>
- Sourcing the build environment script creates a
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- if one does not already exist.
- BitBake uses the Build Directory for all its work during builds.
- The Build Directory has a <filename>conf</filename> directory that
- contains default versions of your <filename>local.conf</filename>
- and <filename>bblayers.conf</filename> configuration files.
- These default configuration files are created only if versions
- do not already exist in the Build Directory at the time you
- source the build environment setup script.
- </para>
-
- <para>
- Because the Poky repository is fundamentally an aggregation of
- existing repositories, some users might be familiar with running
- the <filename>&OE_INIT_FILE;</filename> or
- <filename>oe-init-build-env-memres</filename> script in the context
- of separate OpenEmbedded-Core and BitBake repositories rather than a
- single Poky repository.
- This discussion assumes the script is executed from within a cloned
- or unpacked version of Poky.
- </para>
-
- <para>
- Depending on where the script is sourced, different sub-scripts
- are called to set up the Build Directory (Yocto or OpenEmbedded).
- Specifically, the script
- <filename>scripts/oe-setup-builddir</filename> inside the
- poky directory sets up the Build Directory and seeds the directory
- (if necessary) with configuration files appropriate for the
- Yocto Project development environment.
- <note>
- The <filename>scripts/oe-setup-builddir</filename> script
- uses the <filename>$TEMPLATECONF</filename> variable to
- determine which sample configuration files to locate.
- </note>
- </para>
-
- <para>
- The <filename>local.conf</filename> file provides many
- basic variables that define a build environment.
- Here is a list of a few.
- To see the default configurations in a <filename>local.conf</filename>
- file created by the build environment script, see the
- <filename>local.conf.sample</filename> in the
- <filename>meta-poky</filename> layer:
- <itemizedlist>
- <listitem><para><emphasis>Parallelism Options:</emphasis>
- Controlled by the
- <link linkend='var-BB_NUMBER_THREADS'><filename>BB_NUMBER_THREADS</filename></link>,
- <link linkend='var-PARALLEL_MAKE'><filename>PARALLEL_MAKE</filename></link>,
- and
- <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_NUMBER_PARSE_THREADS'><filename>BB_NUMBER_PARSE_THREADS</filename></ulink>
- variables.</para></listitem>
- <listitem><para><emphasis>Target Machine Selection:</emphasis>
- Controlled by the
- <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
- variable.</para></listitem>
- <listitem><para><emphasis>Download Directory:</emphasis>
- Controlled by the
- <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
- variable.</para></listitem>
- <listitem><para><emphasis>Shared State Directory:</emphasis>
- Controlled by the
- <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>
- variable.</para></listitem>
- <listitem><para><emphasis>Build Output:</emphasis>
- Controlled by the
- <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
- variable.</para></listitem>
- </itemizedlist>
- <note>
- Configurations set in the <filename>conf/local.conf</filename>
- file can also be set in the
- <filename>conf/site.conf</filename> and
- <filename>conf/auto.conf</filename> configuration files.
- </note>
- </para>
-
- <para>
- The <filename>bblayers.conf</filename> file tells BitBake what
- layers you want considered during the build.
- By default, the layers listed in this file include layers
- minimally needed by the build system.
- However, you must manually add any custom layers you have created.
- You can find more information on working with the
- <filename>bblayers.conf</filename> file in the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#enabling-your-layer'>Enabling Your Layer</ulink>"
- section in the Yocto Project Development Manual.
- </para>
-
- <para>
- The files <filename>site.conf</filename> and
- <filename>auto.conf</filename> are not created by the environment
- initialization script.
- If you want the <filename>site.conf</filename> file, you need to
- create that yourself.
- The <filename>auto.conf</filename> file is typically created by
- an autobuilder:
- <itemizedlist>
- <listitem><para><emphasis><filename>site.conf</filename>:</emphasis>
- You can use the <filename>conf/site.conf</filename>
- configuration file to configure multiple build directories.
- For example, suppose you had several build environments and
- they shared some common features.
- You can set these default build properties here.
- A good example is perhaps the packaging format to use
- through the
- <link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>
- variable.</para>
- <para>One useful scenario for using the
- <filename>conf/site.conf</filename> file is to extend your
- <link linkend='var-BBPATH'><filename>BBPATH</filename></link>
- variable to include the path to a
- <filename>conf/site.conf</filename>.
- Then, when BitBake looks for Metadata using
- <filename>BBPATH</filename>, it finds the
- <filename>conf/site.conf</filename> file and applies your
- common configurations found in the file.
- To override configurations in a particular build directory,
- alter the similar configurations within that build
- directory's <filename>conf/local.conf</filename> file.
- </para></listitem>
- <listitem><para><emphasis><filename>auto.conf</filename>:</emphasis>
- The file is usually created and written to by
- an autobuilder.
- The settings put into the file are typically the same as
- you would find in the <filename>conf/local.conf</filename>
- or the <filename>conf/site.conf</filename> files.
- </para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- You can edit all configuration files to further define
- any particular build environment.
- This process is represented by the "User Configuration Edits"
- box in the figure.
- </para>
-
- <para>
- When you launch your build with the
- <filename>bitbake <replaceable>target</replaceable></filename>
- command, BitBake sorts out the configurations to ultimately
- define your build environment.
- It is important to understand that the OpenEmbedded build system
- reads the configuration files in a specific order:
- <filename>site.conf</filename>, <filename>auto.conf</filename>,
- and <filename>local.conf</filename>.
- And, the build system applies the normal assignment statement
- rules.
- Because the files are parsed in a specific order, variable
- assignments for the same variable could be affected.
- For example, if the <filename>auto.conf</filename> file and
- the <filename>local.conf</filename> set
- <replaceable>variable1</replaceable> to different values, because
- the build system parses <filename>local.conf</filename> after
- <filename>auto.conf</filename>,
- <replaceable>variable1</replaceable> is assigned the value from
- the <filename>local.conf</filename> file.
- </para>
- </section>
-
- <section id="metadata-machine-configuration-and-policy-configuration">
- <title>Metadata, Machine Configuration, and Policy Configuration</title>
-
- <para>
- The previous section described the user configurations that
- define BitBake's global behavior.
- This section takes a closer look at the layers the build system
- uses to further control the build.
- These layers provide Metadata for the software, machine, and
- policy.
- </para>
-
- <para>
- In general, three types of layer input exist:
- <itemizedlist>
- <listitem><para><emphasis>Policy Configuration:</emphasis>
- Distribution Layers provide top-level or general
- policies for the image or SDK being built.
- For example, this layer would dictate whether BitBake
- produces RPM or IPK packages.</para></listitem>
- <listitem><para><emphasis>Machine Configuration:</emphasis>
- Board Support Package (BSP) layers provide machine
- configurations.
- This type of information is specific to a particular
- target architecture.</para></listitem>
- <listitem><para><emphasis>Metadata:</emphasis>
- Software layers contain user-supplied recipe files,
- patches, and append files.
- </para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- The following figure shows an expanded representation of the
- Metadata, Machine Configuration, and Policy Configuration input
- (layers) boxes of the
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>:
- </para>
-
- <para>
- <imagedata fileref="figures/layer-input.png" align="center" width="8in" depth="7.5in" />
- </para>
-
- <para>
- In general, all layers have a similar structure.
- They all contain a licensing file
- (e.g. <filename>COPYING</filename>) if the layer is to be
- distributed, a <filename>README</filename> file as good practice
- and especially if the layer is to be distributed, a
- configuration directory, and recipe directories.
- </para>
-
- <para>
- The Yocto Project has many layers that can be used.
- You can see a web-interface listing of them on the
- <ulink url="http://git.yoctoproject.org/">Source Repositories</ulink>
- page.
- The layers are shown at the bottom categorized under
- "Yocto Metadata Layers."
- These layers are fundamentally a subset of the
- <ulink url="http://layers.openembedded.org/layerindex/layers/">OpenEmbedded Metadata Index</ulink>,
- which lists all layers provided by the OpenEmbedded community.
- <note>
- Layers exist in the Yocto Project Source Repositories that
- cannot be found in the OpenEmbedded Metadata Index.
- These layers are either deprecated or experimental in nature.
- </note>
- </para>
-
- <para>
- BitBake uses the <filename>conf/bblayers.conf</filename> file,
- which is part of the user configuration, to find what layers it
- should be using as part of the build.
- </para>
-
- <para>
- For more information on layers, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and Creating Layers</ulink>"
- section in the Yocto Project Development Manual.
- </para>
-
- <section id="distro-layer">
- <title>Distro Layer</title>
-
- <para>
- The distribution layer provides policy configurations for your
- distribution.
- Best practices dictate that you isolate these types of
- configurations into their own layer.
- Settings you provide in
- <filename>conf/distro/<replaceable>distro</replaceable>.conf</filename> override
- similar
- settings that BitBake finds in your
- <filename>conf/local.conf</filename> file in the Build
- Directory.
- </para>
-
- <para>
- The following list provides some explanation and references
- for what you typically find in the distribution layer:
- <itemizedlist>
- <listitem><para><emphasis>classes:</emphasis>
- Class files (<filename>.bbclass</filename>) hold
- common functionality that can be shared among
- recipes in the distribution.
- When your recipes inherit a class, they take on the
- settings and functions for that class.
- You can read more about class files in the
- "<link linkend='ref-classes'>Classes</link>" section.
- </para></listitem>
- <listitem><para><emphasis>conf:</emphasis>
- This area holds configuration files for the
- layer (<filename>conf/layer.conf</filename>),
- the distribution
- (<filename>conf/distro/<replaceable>distro</replaceable>.conf</filename>),
- and any distribution-wide include files.
- </para></listitem>
- <listitem><para><emphasis>recipes-*:</emphasis>
- Recipes and append files that affect common
- functionality across the distribution.
- This area could include recipes and append files
- to add distribution-specific configuration,
- initialization scripts, custom image recipes,
- and so forth.</para></listitem>
- </itemizedlist>
- </para>
- </section>
-
- <section id="bsp-layer">
- <title>BSP Layer</title>
-
- <para>
- The BSP Layer provides machine configurations.
- Everything in this layer is specific to the machine for which
- you are building the image or the SDK.
- A common structure or form is defined for BSP layers.
- You can learn more about this structure in the
- <ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>.
- <note>
- In order for a BSP layer to be considered compliant with the
- Yocto Project, it must meet some structural requirements.
- </note>
- </para>
-
- <para>
- The BSP Layer's configuration directory contains
- configuration files for the machine
- (<filename>conf/machine/<replaceable>machine</replaceable>.conf</filename>) and,
- of course, the layer (<filename>conf/layer.conf</filename>).
- </para>
-
- <para>
- The remainder of the layer is dedicated to specific recipes
- by function: <filename>recipes-bsp</filename>,
- <filename>recipes-core</filename>,
- <filename>recipes-graphics</filename>, and
- <filename>recipes-kernel</filename>.
- Metadata can exist for multiple formfactors, graphics
- support systems, and so forth.
- <note>
- While the figure shows several <filename>recipes-*</filename>
- directories, not all these directories appear in all
- BSP layers.
- </note>
- </para>
- </section>
-
- <section id="software-layer">
- <title>Software Layer</title>
-
- <para>
- The software layer provides the Metadata for additional
- software packages used during the build.
- This layer does not include Metadata that is specific to the
- distribution or the machine, which are found in their
- respective layers.
- </para>
-
- <para>
- This layer contains any new recipes that your project needs
- in the form of recipe files.
- </para>
- </section>
- </section>
-
- <section id="sources-dev-environment">
- <title>Sources</title>
-
- <para>
- In order for the OpenEmbedded build system to create an image or
- any target, it must be able to access source files.
- The
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
- represents source files using the "Upstream Project Releases",
- "Local Projects", and "SCMs (optional)" boxes.
- The figure represents mirrors, which also play a role in locating
- source files, with the "Source Mirror(s)" box.
- </para>
-
- <para>
- The method by which source files are ultimately organized is
- a function of the project.
- For example, for released software, projects tend to use tarballs
- or other archived files that can capture the state of a release
- guaranteeing that it is statically represented.
- On the other hand, for a project that is more dynamic or
- experimental in nature, a project might keep source files in a
- repository controlled by a Source Control Manager (SCM) such as
- Git.
- Pulling source from a repository allows you to control
- the point in the repository (the revision) from which you want to
- build software.
- Finally, a combination of the two might exist, which would give the
- consumer a choice when deciding where to get source files.
- </para>
-
- <para>
- BitBake uses the
- <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
- variable to point to source files regardless of their location.
- Each recipe must have a <filename>SRC_URI</filename> variable
- that points to the source.
- </para>
-
- <para>
- Another area that plays a significant role in where source files
- come from is pointed to by the
- <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
- variable.
- This area is a cache that can hold previously downloaded source.
- You can also instruct the OpenEmbedded build system to create
- tarballs from Git repositories, which is not the default behavior,
- and store them in the <filename>DL_DIR</filename> by using the
- <link linkend='var-BB_GENERATE_MIRROR_TARBALLS'><filename>BB_GENERATE_MIRROR_TARBALLS</filename></link>
- variable.
- </para>
-
- <para>
- Judicious use of a <filename>DL_DIR</filename> directory can
- save the build system a trip across the Internet when looking
- for files.
- A good method for using a download directory is to have
- <filename>DL_DIR</filename> point to an area outside of your
- Build Directory.
- Doing so allows you to safely delete the Build Directory
- if needed without fear of removing any downloaded source file.
- </para>
-
- <para>
- The remainder of this section provides a deeper look into the
- source files and the mirrors.
- Here is a more detailed look at the source file area of the
- base figure:
- <imagedata fileref="figures/source-input.png" align="center" width="7in" depth="7.5in" />
- </para>
-
- <section id='upstream-project-releases'>
- <title>Upstream Project Releases</title>
-
- <para>
- Upstream project releases exist anywhere in the form of an
- archived file (e.g. tarball or zip file).
- These files correspond to individual recipes.
- For example, the figure uses specific releases each for
- BusyBox, Qt, and Dbus.
- An archive file can be for any released product that can be
- built using a recipe.
- </para>
- </section>
-
- <section id='local-projects'>
- <title>Local Projects</title>
-
- <para>
- Local projects are custom bits of software the user provides.
- These bits reside somewhere local to a project - perhaps
- a directory into which the user checks in items (e.g.
- a local directory containing a development source tree
- used by the group).
- </para>
-
- <para>
- The canonical method through which to include a local project
- is to use the
- <link linkend='ref-classes-externalsrc'><filename>externalsrc</filename></link>
- class to include that local project.
- You use either the <filename>local.conf</filename> or a
- recipe's append file to override or set the
- recipe to point to the local directory on your disk to pull
- in the whole source tree.
- </para>
-
- <para>
- For information on how to use the
- <filename>externalsrc</filename> class, see the
- "<link linkend='ref-classes-externalsrc'><filename>externalsrc.bbclass</filename></link>"
- section.
- </para>
- </section>
-
- <section id='scms'>
- <title>Source Control Managers (Optional)</title>
-
- <para>
- Another place the build system can get source files from is
- through an SCM such as Git or Subversion.
- In this case, a repository is cloned or checked out.
- The
- <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
- task inside BitBake uses
- the <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
- variable and the argument's prefix to determine the correct
- fetcher module.
- </para>
-
- <note>
- For information on how to have the OpenEmbedded build system
- generate tarballs for Git repositories and place them in the
- <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
- directory, see the
- <link linkend='var-BB_GENERATE_MIRROR_TARBALLS'><filename>BB_GENERATE_MIRROR_TARBALLS</filename></link>
- variable.
- </note>
-
- <para>
- When fetching a repository, BitBake uses the
- <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
- variable to determine the specific revision from which to
- build.
- </para>
- </section>
-
- <section id='source-mirrors'>
- <title>Source Mirror(s)</title>
-
- <para>
- Two kinds of mirrors exist: pre-mirrors and regular mirrors.
- The <link linkend='var-PREMIRRORS'><filename>PREMIRRORS</filename></link>
- and
- <link linkend='var-MIRRORS'><filename>MIRRORS</filename></link>
- variables point to these, respectively.
- BitBake checks pre-mirrors before looking upstream for any
- source files.
- Pre-mirrors are appropriate when you have a shared directory
- that is not a directory defined by the
- <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
- variable.
- A Pre-mirror typically points to a shared directory that is
- local to your organization.
- </para>
-
- <para>
- Regular mirrors can be any site across the Internet that is
- used as an alternative location for source code should the
- primary site not be functioning for some reason or another.
- </para>
- </section>
- </section>
-
- <section id="package-feeds-dev-environment">
- <title>Package Feeds</title>
-
- <para>
- When the OpenEmbedded build system generates an image or an SDK,
- it gets the packages from a package feed area located in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
- The
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
- shows this package feeds area in the upper-right corner.
- </para>
-
- <para>
- This section looks a little closer into the package feeds area used
- by the build system.
- Here is a more detailed look at the area:
- <imagedata fileref="figures/package-feeds.png" align="center" width="7in" depth="6in" />
- </para>
-
- <para>
- Package feeds are an intermediary step in the build process.
- The OpenEmbedded build system provides classes to generate
- different package types, and you specify which classes to enable
- through the
- <link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>
- variable.
- Before placing the packages into package feeds,
- the build process validates them with generated output quality
- assurance checks through the
- <link linkend='ref-classes-insane'><filename>insane</filename></link>
- class.
- </para>
-
- <para>
- The package feed area resides in the Build Directory.
- The directory the build system uses to temporarily store packages
- is determined by a combination of variables and the particular
- package manager in use.
- See the "Package Feeds" box in the illustration and note the
- information to the right of that area.
- In particular, the following defines where package files are
- kept:
- <itemizedlist>
- <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
- Defined as <filename>tmp/deploy</filename> in the Build
- Directory.
- </para></listitem>
- <listitem><para><filename>DEPLOY_DIR_*</filename>:
- Depending on the package manager used, the package type
- sub-folder.
- Given RPM, IPK, or DEB packaging and tarball creation, the
- <link linkend='var-DEPLOY_DIR_RPM'><filename>DEPLOY_DIR_RPM</filename></link>,
- <link linkend='var-DEPLOY_DIR_IPK'><filename>DEPLOY_DIR_IPK</filename></link>,
- <link linkend='var-DEPLOY_DIR_DEB'><filename>DEPLOY_DIR_DEB</filename></link>,
- or
- <link linkend='var-DEPLOY_DIR_TAR'><filename>DEPLOY_DIR_TAR</filename></link>,
- variables are used, respectively.
- </para></listitem>
- <listitem><para><link linkend='var-PACKAGE_ARCH'><filename>PACKAGE_ARCH</filename></link>:
- Defines architecture-specific sub-folders.
- For example, packages could exist for the i586 or qemux86
- architectures.
- </para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- BitBake uses the <filename>do_package_write_*</filename> tasks to
- generate packages and place them into the package holding area (e.g.
- <filename>do_package_write_ipk</filename> for IPK packages).
- See the
- "<link linkend='ref-tasks-package_write_deb'><filename>do_package_write_deb</filename></link>",
- "<link linkend='ref-tasks-package_write_ipk'><filename>do_package_write_ipk</filename></link>",
- "<link linkend='ref-tasks-package_write_rpm'><filename>do_package_write_rpm</filename></link>",
- and
- "<link linkend='ref-tasks-package_write_tar'><filename>do_package_write_tar</filename></link>"
- sections for additional information.
- As an example, consider a scenario where an IPK packaging manager
- is being used and package architecture support for both i586
- and qemux86 exist.
- Packages for the i586 architecture are placed in
- <filename>build/tmp/deploy/ipk/i586</filename>, while packages for
- the qemux86 architecture are placed in
- <filename>build/tmp/deploy/ipk/qemux86</filename>.
- </para>
- </section>
-
- <section id='bitbake-dev-environment'>
- <title>BitBake</title>
-
- <para>
- The OpenEmbedded build system uses
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>
- to produce images.
- You can see from the
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>,
- the BitBake area consists of several functional areas.
- This section takes a closer look at each of those areas.
- </para>
-
- <para>
- Separate documentation exists for the BitBake tool.
- See the
- <ulink url='&YOCTO_DOCS_BB_URL;#bitbake-user-manual'>BitBake User Manual</ulink>
- for reference material on BitBake.
- </para>
-
- <section id='source-fetching-dev-environment'>
- <title>Source Fetching</title>
-
- <para>
- The first stages of building a recipe are to fetch and unpack
- the source code:
- <imagedata fileref="figures/source-fetching.png" align="center" width="6.5in" depth="5in" />
- </para>
-
- <para>
- The
- <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
- and
- <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
- tasks fetch the source files and unpack them into the work
- directory.
- <note>
- For every local file (e.g. <filename>file://</filename>)
- that is part of a recipe's
- <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
- statement, the OpenEmbedded build system takes a checksum
- of the file for the recipe and inserts the checksum into
- the signature for the <filename>do_fetch</filename>.
- If any local file has been modified, the
- <filename>do_fetch</filename> task and all tasks that
- depend on it are re-executed.
- </note>
- By default, everything is accomplished in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>,
- which has a defined structure.
- For additional general information on the Build Directory,
- see the
- "<link linkend='structure-core-build'><filename>build/</filename></link>"
- section.
- </para>
-
- <para>
- Unpacked source files are pointed to by the
- <link linkend='var-S'><filename>S</filename></link> 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:
- <itemizedlist>
- <listitem><para><link linkend='var-TMPDIR'><filename>TMPDIR</filename></link> -
- The base directory where the OpenEmbedded build system
- performs all its work during the build.
- </para></listitem>
- <listitem><para><link linkend='var-PACKAGE_ARCH'><filename>PACKAGE_ARCH</filename></link> -
- The architecture of the built package or packages.
- </para></listitem>
- <listitem><para><link linkend='var-TARGET_OS'><filename>TARGET_OS</filename></link> -
- The operating system of the target device.
- </para></listitem>
- <listitem><para><link linkend='var-PN'><filename>PN</filename></link> -
- The name of the built package.
- </para></listitem>
- <listitem><para><link linkend='var-PV'><filename>PV</filename></link> -
- The version of the recipe used to build the package.
- </para></listitem>
- <listitem><para><link linkend='var-PR'><filename>PR</filename></link> -
- The revision of the recipe used to build the package.
- </para></listitem>
- <listitem><para><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link> -
- The location within <filename>TMPDIR</filename> where
- a specific package is built.
- </para></listitem>
- <listitem><para><link linkend='var-S'><filename>S</filename></link> -
- Contains the unpacked source files for a given recipe.
- </para></listitem>
- </itemizedlist>
- </para>
- </section>
-
- <section id='patching-dev-environment'>
- <title>Patching</title>
-
- <para>
- Once source code is fetched and unpacked, BitBake locates
- patch files and applies them to the source files:
- <imagedata fileref="figures/patching.png" align="center" width="6in" depth="5in" />
- </para>
-
- <para>
- The
- <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
- task processes recipes by
- using the
- <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
- variable to locate applicable patch files, which by default
- are <filename>*.patch</filename> or
- <filename>*.diff</filename> files, or any file if
- "apply=yes" is specified for the file in
- <filename>SRC_URI</filename>.
- </para>
-
- <para>
- BitBake finds and applies multiple patches for a single recipe
- in the order in which it finds the patches.
- Patches are applied to the recipe's source files located in the
- <link linkend='var-S'><filename>S</filename></link> directory.
- </para>
-
- <para>
- For more information on how the source directories are
- created, see the
- "<link linkend='source-fetching-dev-environment'>Source Fetching</link>"
- section.
- </para>
- </section>
-
- <section id='configuration-and-compilation-dev-environment'>
- <title>Configuration and Compilation</title>
-
- <para>
- After source code is patched, BitBake executes tasks that
- configure and compile the source code:
- <imagedata fileref="figures/configuration-compile-autoreconf.png" align="center" width="7in" depth="5in" />
- </para>
-
- <para>
- This step in the build process consists of three tasks:
- <itemizedlist>
- <listitem><para>
- <emphasis><link linkend='ref-tasks-prepare_recipe_sysroot'><filename>do_prepare_recipe_sysroot</filename></link>:</emphasis>
- This task sets up the two sysroots in
- <filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}</filename>
- (i.e. <filename>recipe-sysroot</filename> and
- <filename>recipe-sysroot-native</filename>) so that
- the sysroots contain the contents of the
- <link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>
- tasks of the recipes on which the recipe
- containing the tasks depends.
- A sysroot exists for both the target and for the native
- binaries, which run on the host system.
- </para></listitem>
- <listitem><para><emphasis><filename>do_configure</filename>:</emphasis>
- This task configures the source by enabling and
- disabling any build-time and configuration options for
- the software being built.
- Configurations can come from the recipe itself as well
- as from an inherited class.
- Additionally, the software itself might configure itself
- depending on the target for which it is being built.
- </para>
-
- <para>The configurations handled by the
- <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
- task are specific
- to source code configuration for the source code
- being built by the recipe.</para>
-
- <para>If you are using the
- <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
- class,
- you can add additional configuration options by using
- the <link linkend='var-EXTRA_OECONF'><filename>EXTRA_OECONF</filename></link>
- or
- <link linkend='var-PACKAGECONFIG_CONFARGS'><filename>PACKAGECONFIG_CONFARGS</filename></link>
- variables.
- For information on how this variable works within
- that class, see the
- <filename>meta/classes/autotools.bbclass</filename> file.
- </para></listitem>
- <listitem><para><emphasis><filename>do_compile</filename>:</emphasis>
- Once a configuration task has been satisfied, BitBake
- compiles the source using the
- <link linkend='ref-tasks-compile'><filename>do_compile</filename></link>
- task.
- Compilation occurs in the directory pointed to by the
- <link linkend='var-B'><filename>B</filename></link>
- variable.
- Realize that the <filename>B</filename> directory is, by
- default, the same as the
- <link linkend='var-S'><filename>S</filename></link>
- directory.</para></listitem>
- <listitem><para><emphasis><filename>do_install</filename>:</emphasis>
- Once compilation is done, BitBake executes the
- <link linkend='ref-tasks-install'><filename>do_install</filename></link>
- task.
- This task copies files from the <filename>B</filename>
- directory and places them in a holding area pointed to
- by the
- <link linkend='var-D'><filename>D</filename></link>
- variable.</para></listitem>
- </itemizedlist>
- </para>
- </section>
-
- <section id='package-splitting-dev-environment'>
- <title>Package Splitting</title>
-
- <para>
- After source code is configured and compiled, the
- OpenEmbedded build system analyzes
- the results and splits the output into packages:
- <imagedata fileref="figures/analysis-for-package-splitting.png" align="center" width="7in" depth="7in" />
- </para>
-
- <para>
- The
- <link linkend='ref-tasks-package'><filename>do_package</filename></link>
- and
- <link linkend='ref-tasks-packagedata'><filename>do_packagedata</filename></link>
- tasks combine to analyze
- the files found in the
- <link linkend='var-D'><filename>D</filename></link> directory
- and split them into subsets based on available packages and
- files.
- The analyzing process involves the following as well as other
- items: splitting out debugging symbols,
- looking at shared library dependencies between packages,
- and looking at package relationships.
- The <filename>do_packagedata</filename> task creates package
- metadata based on the analysis such that the
- OpenEmbedded build system can generate the final packages.
- Working, staged, and intermediate results of the analysis
- and package splitting process use these areas:
- <itemizedlist>
- <listitem><para><link linkend='var-PKGD'><filename>PKGD</filename></link> -
- The destination directory for packages before they are
- split.
- </para></listitem>
- <listitem><para><link linkend='var-PKGDATA_DIR'><filename>PKGDATA_DIR</filename></link> -
- A shared, global-state directory that holds data
- generated during the packaging process.
- </para></listitem>
- <listitem><para><link linkend='var-PKGDESTWORK'><filename>PKGDESTWORK</filename></link> -
- A temporary work area used by the
- <filename>do_package</filename> task.
- </para></listitem>
- <listitem><para><link linkend='var-PKGDEST'><filename>PKGDEST</filename></link> -
- The parent directory for packages after they have
- been split.
- </para></listitem>
- </itemizedlist>
- The <link linkend='var-FILES'><filename>FILES</filename></link>
- variable defines the files that go into each package in
- <link linkend='var-PACKAGES'><filename>PACKAGES</filename></link>.
- If you want details on how this is accomplished, you can
- look at the
- <link linkend='ref-classes-package'><filename>package</filename></link>
- class.
- </para>
-
- <para>
- Depending on the type of packages being created (RPM, DEB, or
- IPK), the <filename>do_package_write_*</filename> task
- creates the actual packages and places them in the
- Package Feed area, which is
- <filename>${TMPDIR}/deploy</filename>.
- You can see the
- "<link linkend='package-feeds-dev-environment'>Package Feeds</link>"
- section for more detail on that part of the build process.
- <note>
- Support for creating feeds directly from the
- <filename>deploy/*</filename> directories does not exist.
- Creating such feeds usually requires some kind of feed
- maintenance mechanism that would upload the new packages
- into an official package feed (e.g. the
- Ångström distribution).
- This functionality is highly distribution-specific
- and thus is not provided out of the box.
- </note>
- </para>
- </section>
-
- <section id='image-generation-dev-environment'>
- <title>Image Generation</title>
-
- <para>
- Once packages are split and stored in the Package Feeds area,
- the OpenEmbedded build system uses BitBake to generate the
- root filesystem image:
- <imagedata fileref="figures/image-generation.png" align="center" width="6in" depth="7in" />
- </para>
-
- <para>
- The image generation process consists of several stages and
- depends on several tasks and variables.
- The
- <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
- task creates the root filesystem (file and directory structure)
- for an image.
- This task uses several key variables to help create the list
- of packages to actually install:
- <itemizedlist>
- <listitem><para><link linkend='var-IMAGE_INSTALL'><filename>IMAGE_INSTALL</filename></link>:
- Lists out the base set of packages to install from
- the Package Feeds area.</para></listitem>
- <listitem><para><link linkend='var-PACKAGE_EXCLUDE'><filename>PACKAGE_EXCLUDE</filename></link>:
- Specifies packages that should not be installed.
- </para></listitem>
- <listitem><para><link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>:
- Specifies features to include in the image.
- Most of these features map to additional packages for
- installation.</para></listitem>
- <listitem><para><link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>:
- Specifies the package backend to use and consequently
- helps determine where to locate packages within the
- Package Feeds area.</para></listitem>
- <listitem><para><link linkend='var-IMAGE_LINGUAS'><filename>IMAGE_LINGUAS</filename></link>:
- Determines the language(s) for which additional
- language support packages are installed.
- </para></listitem>
- <listitem><para><link linkend='var-PACKAGE_INSTALL'><filename>PACKAGE_INSTALL</filename></link>:
- The final list of packages passed to the package manager
- for installation into the image.
- </para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- With
- <link linkend='var-IMAGE_ROOTFS'><filename>IMAGE_ROOTFS</filename></link>
- pointing to the location of the filesystem under construction and
- the <filename>PACKAGE_INSTALL</filename> variable providing the
- final list of packages to install, the root file system is
- created.
- </para>
-
- <para>
- Package installation is under control of the package manager
- (e.g. dnf/rpm, opkg, or apt/dpkg) regardless of whether or
- not package management is enabled for the target.
- At the end of the process, if package management is not
- enabled for the target, the package manager's data files
- are deleted from the root filesystem.
- As part of the final stage of package installation, postinstall
- scripts that are part of the packages are run.
- Any scripts that fail to run
- on the build host are run on the target when the target system
- is first booted.
- If you are using a
- <ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-read-only-root-filesystem'>read-only root filesystem</ulink>,
- all the post installation scripts must succeed during the
- package installation phase since the root filesystem is
- read-only.
- </para>
-
- <para>
- The final stages of the <filename>do_rootfs</filename> task
- handle post processing.
- Post processing includes creation of a manifest file and
- optimizations.
- </para>
-
- <para>
- The manifest file (<filename>.manifest</filename>) resides
- in the same directory as the root filesystem image.
- This file lists out, line-by-line, the installed packages.
- The manifest file is useful for the
- <link linkend='ref-classes-testimage*'><filename>testimage</filename></link>
- class, for example, to determine whether or not to run
- specific tests.
- See the
- <link linkend='var-IMAGE_MANIFEST'><filename>IMAGE_MANIFEST</filename></link>
- variable for additional information.
- </para>
-
- <para>
- Optimizing processes run across the image include
- <filename>mklibs</filename>, <filename>prelink</filename>,
- and any other post-processing commands as defined by the
- <link linkend='var-ROOTFS_POSTPROCESS_COMMAND'><filename>ROOTFS_POSTPROCESS_COMMAND</filename></link>
- variable.
- The <filename>mklibs</filename> process optimizes the size
- of the libraries, while the
- <filename>prelink</filename> process optimizes the dynamic
- linking of shared libraries to reduce start up time of
- executables.
- </para>
-
- <para>
- After the root filesystem is built, processing begins on
- the image through the <filename>do_image</filename> task.
- The build system runs any pre-processing commands as defined
- by the
- <link linkend='var-IMAGE_PREPROCESS_COMMAND'><filename>IMAGE_PREPROCESS_COMMAND</filename></link>
- variable.
- This variable specifies a list of functions to call before
- the OpenEmbedded build system creates the final image output
- files.
- </para>
-
- <para>
- The <filename>do_image</filename> task dynamically creates
- other <filename>do_image_*</filename> tasks as needed, which
- include compressing the root filesystem image to reduce the
- overall size of the image.
- The process turns everything into an image file or a set of
- image files.
- The formats used for the root filesystem depend on the
- <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
- variable.
- </para>
-
- <para>
- The final task involved in image creation is the
- <filename>do_image_complete</filename> task.
- This task completes the image by applying any image
- post processing as defined through the
- <link linkend='var-IMAGE_POSTPROCESS_COMMAND'><filename>IMAGE_POSTPROCESS_COMMAND</filename></link>
- variable.
- The variable specifies a list of functions to call once the
- OpenEmbedded build system has created the final image output
- files.
- </para>
-
- <note>
- The entire image generation process is run under Pseudo.
- Running under Pseudo ensures that the files in the root
- filesystem have correct ownership.
- </note>
- </section>
-
- <section id='sdk-generation-dev-environment'>
- <title>SDK Generation</title>
-
- <para>
- The OpenEmbedded build system uses BitBake to generate the
- Software Development Kit (SDK) installer script for both the
- standard and extensible SDKs:
- <imagedata fileref="figures/sdk-generation.png" align="center" />
- </para>
-
- <note>
- For more information on the cross-development toolchain
- generation, see the
- "<link linkend='cross-development-toolchain-generation'>Cross-Development Toolchain Generation</link>"
- section.
- For information on advantages gained when building a
- cross-development toolchain using the
- <link linkend='ref-tasks-populate_sdk'><filename>do_populate_sdk</filename></link>
- task, see the
- "<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
- section in the Yocto Project Software Development Kit (SDK)
- Developer's Guide.
- </note>
-
- <para>
- Like image generation, the SDK script process consists of
- several stages and depends on many variables.
- The <filename>do_populate_sdk</filename> and
- <filename>do_populate_sdk_ext</filename> tasks use these
- key variables to help create the list of packages to actually
- install.
- For information on the variables listed in the figure, see the
- "<link linkend='sdk-dev-environment'>Application Development SDK</link>"
- section.
- </para>
-
- <para>
- The <filename>do_populate_sdk</filename> task helps create
- the standard SDK and handles two parts: a target part and a
- host part.
- The target part is the part built for the target hardware and
- includes libraries and headers.
- The host part is the part of the SDK that runs on the
- <link linkend='var-SDKMACHINE'><filename>SDKMACHINE</filename></link>.
- </para>
-
- <para>
- The <filename>do_populate_sdk_ext</filename> task helps create
- the extensible SDK and handles host and target parts
- differently than its counter part does for the standard SDK.
- For the extensible SDK, the task encapsulates the build system,
- which includes everything needed (host and target) for the SDK.
- </para>
-
- <para>
- Regardless of the type of SDK being constructed, the
- tasks perform some cleanup after which a cross-development
- environment setup script and any needed configuration files
- are created.
- The final output is the Cross-development
- toolchain installation script (<filename>.sh</filename> file),
- which includes the environment setup script.
- </para>
- </section>
-
- <section id='stamp-files-and-the-rerunning-of-tasks'>
- <title>Stamp Files and the Rerunning of Tasks</title>
-
- <para>
- For each task that completes successfully, BitBake writes a
- stamp file into the
- <link linkend='var-STAMPS_DIR'><filename>STAMPS_DIR</filename></link>
- directory.
- The beginning of the stamp file's filename is determined by the
- <link linkend='var-STAMP'><filename>STAMP</filename></link>
- variable, and the end of the name consists of the task's name
- and current
- <ulink url='&YOCTO_DOCS_BB_URL;#checksums'>input checksum</ulink>.
- <note>
- This naming scheme assumes that
- <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_SIGNATURE_HANDLER'><filename>BB_SIGNATURE_HANDLER</filename></ulink>
- is "OEBasicHash", which is almost always the case in
- current OpenEmbedded.
- </note>
- To determine if a task needs to be rerun, BitBake checks if a
- stamp file with a matching input checksum exists for the task.
- If such a stamp file exists, the task's output is assumed to
- exist and still be valid.
- If the file does not exist, the task is rerun.
- <note>
- <para>The stamp mechanism is more general than the shared
- state (sstate) cache mechanism described in the
- "<link linkend='setscene-tasks-and-shared-state'>Setscene Tasks and Shared State</link>"
- section.
- BitBake avoids rerunning any task that has a valid
- stamp file, not just tasks that can be accelerated through
- the sstate cache.</para>
- <para>However, you should realize that stamp files only
- serve as a marker that some work has been done and that
- these files do not record task output.
- The actual task output would usually be somewhere in
- <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
- (e.g. in some recipe's
- <link linkend='var-WORKDIR'><filename>WORKDIR</filename></link>.)
- What the sstate cache mechanism adds is a way to cache task
- output that can then be shared between build machines.
- </para>
- </note>
- Since <filename>STAMPS_DIR</filename> is usually a subdirectory
- of <filename>TMPDIR</filename>, removing
- <filename>TMPDIR</filename> will also remove
- <filename>STAMPS_DIR</filename>, which means tasks will
- properly be rerun to repopulate <filename>TMPDIR</filename>.
- </para>
-
- <para>
- If you want some task to always be considered "out of date",
- you can mark it with the
- <ulink url='&YOCTO_DOCS_BB_URL;#variable-flags'><filename>nostamp</filename></ulink>
- varflag.
- If some other task depends on such a task, then that task will
- also always be considered out of date, which might not be what
- you want.
- </para>
-
- <para>
- For details on how to view information about a task's
- signature, see the
- "<link linkend='usingpoky-viewing-task-variable-dependencies'>Viewing Task Variable Dependencies</link>"
- section.
- </para>
- </section>
-
- <section id='setscene-tasks-and-shared-state'>
- <title>Setscene Tasks and Shared State</title>
-
- <para>
- The description of tasks so far assumes that BitBake needs to
- build everything and there are no prebuilt objects available.
- BitBake does support skipping tasks if prebuilt objects are
- available.
- These objects are usually made available in the form of a
- shared state (sstate) cache.
- <note>
- For information on variables affecting sstate, see the
- <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>
- and
- <link linkend='var-SSTATE_MIRRORS'><filename>SSTATE_MIRRORS</filename></link>
- variables.
- </note>
- </para>
-
- <para>
- The idea of a setscene task (i.e
- <filename>do_</filename><replaceable>taskname</replaceable><filename>_setscene</filename>)
- is a version of the task where
- instead of building something, BitBake can skip to the end
- result and simply place a set of files into specific locations
- as needed.
- In some cases, it makes sense to have a setscene task variant
- (e.g. generating package files in the
- <filename>do_package_write_*</filename> task).
- In other cases, it does not make sense, (e.g. a
- <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
- task or
- <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
- task) since the work involved would be equal to or greater than
- the underlying task.
- </para>
-
- <para>
- In the OpenEmbedded build system, the common tasks that have
- setscene variants are <link linkend='ref-tasks-package'><filename>do_package</filename></link>,
- <filename>do_package_write_*</filename>,
- <link linkend='ref-tasks-deploy'><filename>do_deploy</filename></link>,
- <link linkend='ref-tasks-packagedata'><filename>do_packagedata</filename></link>,
- and
- <link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>.
- Notice that these are most of the tasks whose output is an
- end result.
- </para>
-
- <para>
- The OpenEmbedded build system has knowledge of the relationship
- between these tasks and other tasks that precede them.
- For example, if BitBake runs
- <filename>do_populate_sysroot_setscene</filename> for
- something, there is little point in running any of the
- <filename>do_fetch</filename>, <filename>do_unpack</filename>,
- <filename>do_patch</filename>,
- <filename>do_configure</filename>,
- <filename>do_compile</filename>, and
- <filename>do_install</filename> tasks.
- However, if <filename>do_package</filename> needs to be run,
- BitBake would need to run those other tasks.
- </para>
-
- <para>
- It becomes more complicated if everything can come from an
- sstate cache because some objects are simply not required at
- all.
- For example, you do not need a compiler or native tools, such
- as quilt, if there is nothing to compile or patch.
- If the <filename>do_package_write_*</filename> packages are
- available from sstate, BitBake does not need the
- <filename>do_package</filename> task data.
- </para>
-
- <para>
- To handle all these complexities, BitBake runs in two phases.
- The first is the "setscene" stage.
- During this stage, BitBake first checks the sstate cache for
- any targets it is planning to build.
- BitBake does a fast check to see if the object exists rather
- than a complete download.
- If nothing exists, the second phase, which is the setscene
- stage, completes and the main build proceeds.
- </para>
-
- <para>
- If objects are found in the sstate cache, the OpenEmbedded
- build system works backwards from the end targets specified
- by the user.
- For example, if an image is being built, the OpenEmbedded build
- system first looks for the packages needed for that image and
- the tools needed to construct an image.
- If those are available, the compiler is not needed.
- Thus, the compiler is not even downloaded.
- If something was found to be unavailable, or the download or
- setscene task fails, the OpenEmbedded build system then tries
- to install dependencies, such as the compiler, from the cache.
- </para>
-
- <para>
- The availability of objects in the sstate cache is handled by
- the function specified by the
- <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_HASHCHECK_FUNCTION'><filename>BB_HASHCHECK_FUNCTION</filename></ulink>
- variable and returns a list of the objects that are available.
- The function specified by the
- <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_SETSCENE_DEPVALID'><filename>BB_SETSCENE_DEPVALID</filename></ulink>
- variable is the function that determines whether a given
- dependency needs to be followed, and whether for any given
- relationship the function needs to be passed.
- The function returns a True or False value.
- </para>
- </section>
- </section>
-
- <section id='images-dev-environment'>
- <title>Images</title>
-
- <para>
- The images produced by the OpenEmbedded build system
- are compressed forms of the
- root filesystem that are ready to boot on a target device.
- You can see from the
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
- that BitBake output, in part, consists of images.
- This section is going to look more closely at this output:
- <imagedata fileref="figures/images.png" align="center" width="5.5in" depth="5.5in" />
- </para>
-
- <para>
- For a list of example images that the Yocto Project provides,
- see the
- "<link linkend='ref-images'>Images</link>" chapter.
- </para>
-
- <para>
- Images are written out to the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- inside the <filename>tmp/deploy/images/<replaceable>machine</replaceable>/</filename>
- folder as shown in the figure.
- This folder contains any files expected to be loaded on the
- target device.
- The
- <link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>
- variable points to the <filename>deploy</filename> directory,
- while the
- <link linkend='var-DEPLOY_DIR_IMAGE'><filename>DEPLOY_DIR_IMAGE</filename></link>
- variable points to the appropriate directory containing images for
- the current configuration.
- <itemizedlist>
- <listitem><para><filename><replaceable>kernel-image</replaceable></filename>:
- A kernel binary file.
- The <link linkend='var-KERNEL_IMAGETYPE'><filename>KERNEL_IMAGETYPE</filename></link>
- variable setting determines the naming scheme for the
- kernel image file.
- Depending on that variable, the file could begin with
- a variety of naming strings.
- The <filename>deploy/images/<replaceable>machine</replaceable></filename>
- directory can contain multiple image files for the
- machine.</para></listitem>
- <listitem><para><filename><replaceable>root-filesystem-image</replaceable></filename>:
- Root filesystems for the target device (e.g.
- <filename>*.ext3</filename> or <filename>*.bz2</filename>
- files).
- The <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
- variable setting determines the root filesystem image
- type.
- The <filename>deploy/images/<replaceable>machine</replaceable></filename>
- directory can contain multiple root filesystems for the
- machine.</para></listitem>
- <listitem><para><filename><replaceable>kernel-modules</replaceable></filename>:
- Tarballs that contain all the modules built for the kernel.
- Kernel module tarballs exist for legacy purposes and
- can be suppressed by setting the
- <link linkend='var-MODULE_TARBALL_DEPLOY'><filename>MODULE_TARBALL_DEPLOY</filename></link>
- variable to "0".
- The <filename>deploy/images/<replaceable>machine</replaceable></filename>
- directory can contain multiple kernel module tarballs
- for the machine.</para></listitem>
- <listitem><para><filename><replaceable>bootloaders</replaceable></filename>:
- Bootloaders supporting the image, if applicable to the
- target machine.
- The <filename>deploy/images/<replaceable>machine</replaceable></filename>
- directory can contain multiple bootloaders for the
- machine.</para></listitem>
- <listitem><para><filename><replaceable>symlinks</replaceable></filename>:
- The <filename>deploy/images/<replaceable>machine</replaceable></filename>
- folder contains
- a symbolic link that points to the most recently built file
- for each machine.
- These links might be useful for external scripts that
- need to obtain the latest version of each file.
- </para></listitem>
- </itemizedlist>
- </para>
- </section>
-
- <section id='sdk-dev-environment'>
- <title>Application Development SDK</title>
-
- <para>
- In the
- <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>,
- the output labeled "Application Development SDK" represents an
- SDK.
- The SDK generation process differs depending on whether you build
- a standard SDK
- (e.g. <filename>bitbake -c populate_sdk</filename> <replaceable>imagename</replaceable>)
- or an extensible SDK
- (e.g. <filename>bitbake -c populate_sdk_ext</filename> <replaceable>imagename</replaceable>).
- This section is going to take a closer look at this output:
- <imagedata fileref="figures/sdk.png" align="center" width="9in" depth="7.25in" />
- </para>
-
- <para>
- The specific form of this output is a self-extracting
- SDK installer (<filename>*.sh</filename>) that, when run,
- installs the SDK, which consists of a cross-development
- toolchain, a set of libraries and headers, and an SDK
- environment setup script.
- Running this installer essentially sets up your
- cross-development environment.
- You can think of the cross-toolchain as the "host"
- part because it runs on the SDK machine.
- You can think of the libraries and headers as the "target"
- part because they are built for the target hardware.
- The environment setup script is added so that you can initialize
- the environment before using the tools.
- </para>
-
- <note><title>Notes</title>
- <itemizedlist>
- <listitem><para>
- The Yocto Project supports several methods by which you can
- set up this cross-development environment.
- These methods include downloading pre-built SDK installers
- or building and installing your own SDK installer.
- </para></listitem>
- <listitem><para>
- For background information on cross-development toolchains
- in the Yocto Project development environment, see the
- "<link linkend='cross-development-toolchain-generation'>Cross-Development Toolchain Generation</link>"
- section.
- </para></listitem>
- <listitem><para>
- For information on setting up a cross-development
- environment, see the
- <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
- </para></listitem>
- </itemizedlist>
- </note>
-
- <para>
- Once built, the SDK installers are written out to the
- <filename>deploy/sdk</filename> folder inside the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- as shown in the figure at the beginning of this section.
- Depending on the type of SDK, several variables exist that help
- configure these files.
- The following list shows the variables associated with a standard
- SDK:
- <itemizedlist>
- <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
- Points to the <filename>deploy</filename>
- directory.</para></listitem>
- <listitem><para><link linkend='var-SDKMACHINE'><filename>SDKMACHINE</filename></link>:
- Specifies the architecture of the machine
- on which the cross-development tools are run to
- create packages for the target hardware.
- </para></listitem>
- <listitem><para><link linkend='var-SDKIMAGE_FEATURES'><filename>SDKIMAGE_FEATURES</filename></link>:
- Lists the features to include in the "target" part
- of the SDK.
- </para></listitem>
- <listitem><para><link linkend='var-TOOLCHAIN_HOST_TASK'><filename>TOOLCHAIN_HOST_TASK</filename></link>:
- Lists packages that make up the host
- part of the SDK (i.e. the part that runs on
- the <filename>SDKMACHINE</filename>).
- When you use
- <filename>bitbake -c populate_sdk <replaceable>imagename</replaceable></filename>
- to create the SDK, a set of default packages
- apply.
- This variable allows you to add more packages.
- </para></listitem>
- <listitem><para><link linkend='var-TOOLCHAIN_TARGET_TASK'><filename>TOOLCHAIN_TARGET_TASK</filename></link>:
- Lists packages that make up the target part
- of the SDK (i.e. the part built for the
- target hardware).
- </para></listitem>
- <listitem><para><link linkend='var-SDKPATH'><filename>SDKPATH</filename></link>:
- Defines the default SDK installation path offered by the
- installation script.
- </para></listitem>
- </itemizedlist>
- This next list, shows the variables associated with an extensible
- SDK:
- <itemizedlist>
- <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
- Points to the <filename>deploy</filename> directory.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_EXT_TYPE'><filename>SDK_EXT_TYPE</filename></link>:
- Controls whether or not shared state artifacts are copied
- into the extensible SDK.
- By default, all required shared state artifacts are copied
- into the SDK.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_INCLUDE_PKGDATA'><filename>SDK_INCLUDE_PKGDATA</filename></link>:
- Specifies whether or not packagedata will be included in
- the extensible SDK for all recipes in the "world" target.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_INCLUDE_TOOLCHAIN'><filename>SDK_INCLUDE_TOOLCHAIN</filename></link>:
- Specifies whether or not the toolchain will be included
- when building the extensible SDK.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_LOCAL_CONF_WHITELIST'><filename>SDK_LOCAL_CONF_WHITELIST</filename></link>:
- A list of variables allowed through from the build system
- configuration into the extensible SDK configuration.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_LOCAL_CONF_BLACKLIST'><filename>SDK_LOCAL_CONF_BLACKLIST</filename></link>:
- A list of variables not allowed through from the build
- system configuration into the extensible SDK configuration.
- </para></listitem>
- <listitem><para><link linkend='var-SDK_INHERIT_BLACKLIST'><filename>SDK_INHERIT_BLACKLIST</filename></link>:
- A list of classes to remove from the
- <link linkend='var-INHERIT'><filename>INHERIT</filename></link>
- value globally within the extensible SDK configuration.
- </para></listitem>
- </itemizedlist>
- </para>
- </section>
-
-</chapter>
-<!--
-vim: expandtab tw=80 ts=4
--->
diff --git a/import-layers/yocto-poky/documentation/ref-manual/faq.xml b/import-layers/yocto-poky/documentation/ref-manual/faq.xml
index 5f3f173..11dfc5b 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/faq.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/faq.xml
@@ -13,11 +13,11 @@
</question>
<answer>
<para>
- The term "<ulink url='&YOCTO_DOCS_DEV_URL;#poky'>Poky</ulink>"
+ The term "<link link='poky'>Poky</link>"
refers to the specific reference build system that
the Yocto Project provides.
- Poky is based on <ulink url='&YOCTO_DOCS_DEV_URL;#oe-core'>OE-Core</ulink>
- and <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>.
+ Poky is based on <link linkend='oe-core'>OE-Core</link>
+ and <link linkend='bitbake-term'>BitBake</link>.
Thus, the generic term used here for the build system is
the "OpenEmbedded build system."
Development in the Yocto Project using Poky is closely tied to OpenEmbedded, with
@@ -60,7 +60,7 @@
There are three areas that help with stability;
<itemizedlist>
<listitem><para>The Yocto Project team keeps
- <ulink url='&YOCTO_DOCS_DEV_URL;#oe-core'>OE-Core</ulink> small
+ <link linkend='oe-core'>OE-Core</link> small
and focused, containing around 830 recipes as opposed to the thousands
available in other OpenEmbedded community layers.
Keeping it small makes it easy to test and maintain.</para></listitem>
@@ -86,7 +86,7 @@
Board Support Package (BSP) layer for it.
For more information on how to create a BSP layer, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and Creating Layers</ulink>"
- section in the Yocto Project Development Manual and the
+ section in the Yocto Project Development Tasks Manual and the
<ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>.
</para>
<para>
@@ -143,7 +143,7 @@
To add a package, you need to create a BitBake recipe.
For information on how to create a BitBake recipe, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-writing-a-new-recipe'>Writing a New Recipe</ulink>"
- in the Yocto Project Development Manual.
+ in the Yocto Project Development Tasks Manual.
</para>
</answer>
</qandaentry>
@@ -235,8 +235,9 @@
<qandaentry>
<question>
<para>
- I see lots of 404 responses for files on
- <filename>&YOCTO_HOME_URL;/sources/*</filename>. Is something wrong?
+ I see lots of 404 responses for files when the OpenEmbedded
+ build system is trying to download sources.
+ Is something wrong?
</para>
</question>
<answer>
@@ -416,9 +417,9 @@
<para>
You can find more information on licensing in the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#licensing'>Licensing</ulink>"
- and "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
- sections, both of which are in the Yocto Project Development
+ "<link linkend='licensing'>Licensing</link>" section and in the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
+ section, which is in the Yocto Project Development Tasks
Manual.
</para>
</answer>
@@ -547,7 +548,7 @@
file to include from the
<filename>meta/conf/distro/include</filename> directory within
the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
<para>
@@ -699,10 +700,9 @@
When you use BitBake to build an image, all the build output
goes into the directory created when you run the
build environment setup script (i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
- By default, this <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
+ By default, this
+ <link linkend='build-directory'>Build Directory</link>
is named <filename>build</filename> but can be named
anything you want.
</para>
@@ -765,7 +765,7 @@
<para>
Meanwhile, <filename>DESTDIR</filename> is a path within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
However, when the recipe builds a native program (i.e. one
that is intended to run on the build machine), that program
is never installed directly to the build machine's root
@@ -810,7 +810,7 @@
<para>
This situation results when a build system does
not recognize the environment variables supplied to it by
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>.
+ <link linkend='bitbake-term'>BitBake</link>.
The incident that prompted this FAQ entry involved a Makefile
that used an environment variable named
<filename>BINDIR</filename> instead of the more standard
diff --git a/import-layers/yocto-poky/documentation/ref-manual/figures/YP-flow-diagram.png b/import-layers/yocto-poky/documentation/ref-manual/figures/YP-flow-diagram.png
new file mode 100644
index 0000000..8264410
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/figures/YP-flow-diagram.png
Binary files differ
diff --git a/import-layers/yocto-poky/documentation/ref-manual/figures/git-workflow.png b/import-layers/yocto-poky/documentation/ref-manual/figures/git-workflow.png
new file mode 100644
index 0000000..e401330
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/figures/git-workflow.png
Binary files differ
diff --git a/import-layers/yocto-poky/documentation/ref-manual/figures/index-downloads.png b/import-layers/yocto-poky/documentation/ref-manual/figures/index-downloads.png
new file mode 100644
index 0000000..96303b8
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/figures/index-downloads.png
Binary files differ
diff --git a/import-layers/yocto-poky/documentation/ref-manual/figures/source-repos.png b/import-layers/yocto-poky/documentation/ref-manual/figures/source-repos.png
new file mode 100644
index 0000000..e9cff16
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/figures/source-repos.png
Binary files differ
diff --git a/import-layers/yocto-poky/documentation/ref-manual/figures/yp-download.png b/import-layers/yocto-poky/documentation/ref-manual/figures/yp-download.png
new file mode 100644
index 0000000..5770be6
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/figures/yp-download.png
Binary files differ
diff --git a/import-layers/yocto-poky/documentation/ref-manual/introduction.xml b/import-layers/yocto-poky/documentation/ref-manual/introduction.xml
index eec6cb3..29ef2d5 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/introduction.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/introduction.xml
@@ -5,119 +5,160 @@
<chapter id='ref-manual-intro'>
<title>Introduction</title>
-<section id='intro-welcome'>
- <title>Introduction</title>
+<section id='ref-welcome'>
+ <title>Welcome</title>
<para>
+ Welcome to the Yocto Project Reference Manual.
This manual provides reference information for the current release
of the Yocto Project.
- The Yocto Project is an open-source collaboration project focused
- on embedded Linux developers.
- Amongst other things, the Yocto Project uses the OpenEmbedded build
- system, which is based on the Poky project, to construct complete
- Linux images.
- You can find complete introductory and getting started information
- on the Yocto Project by reading the
+ This manual is best used after you have an understanding
+ of the basics of the Yocto Project.
+ The manual is neither meant to be read as a starting point to the
+ Yocto Project nor read from start to finish.
+ Use this manual to find concepts, variable definitions, class
+ descriptions, and so forth as needed during the course of using
+ the Yocto Project.
+ </para>
+
+ <para>
+ For introductory information on the Yocto Project, see the
+ <ulink url='&YOCTO_HOME_URL;'>Yocto Project Website</ulink> and the
+ "<link linkend='yp-intro'>Introducing the Yocto Project Development Environment</link>"
+ section.
+ </para>
+
+ <para>
+ If you want to use the Yocto Project to test run building an image
+ without having to understand concepts, work through the
<ulink url='&YOCTO_DOCS_QS_URL;'>Yocto Project Quick Start</ulink>.
- </para>
-
- <para>
- For task-based information using the Yocto Project, see the
- <ulink url='&YOCTO_DOCS_DEV_URL;'>Yocto Project Development Manual</ulink>
- and the <ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;'>Yocto Project Linux Kernel Development Manual</ulink>.
- For Board Support Package (BSP) structure information, see the
- <ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>.
- For information on how to use a Software Development Kit, (SDK), see the
- <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
- You can find information on tracing and profiling in the
- <ulink url='&YOCTO_DOCS_PROF_URL;'>Yocto Project Profiling and Tracing Manual</ulink>.
- For information on BitBake, which is the task execution tool the
- OpenEmbedded build system is based on, see the
- <ulink url='&YOCTO_DOCS_BB_URL;#bitbake-user-manual'>BitBake User Manual</ulink>.
- Finally, you can also find lots of Yocto Project information on the
- <ulink url="&YOCTO_HOME_URL;">Yocto Project website</ulink>.
+ You can find "how-to" information in the
+ <ulink url='&YOCTO_DOCS_DEV_URL;'>Yocto Project Development Tasks Manual</ulink>.
+ <note><title>Tip</title>
+ For more information about the Yocto Project Documentation set,
+ see the
+ "<link linkend='resources-links-and-related-documentation'>Links and Related Documentation</link>"
+ section.
+ </note>
</para>
</section>
-<section id='intro-manualoverview'>
- <title>Documentation Overview</title>
+<section id='yp-intro'>
+ <title>Introducing the Yocto Project Development Environment</title>
+
<para>
- This reference manual consists of the following:
- <itemizedlist>
- <listitem><para><emphasis>
- <link linkend='usingpoky'>Using the Yocto Project</link>:</emphasis>
- Provides an overview of the components that make up the Yocto Project
- followed by information about debugging images created in the Yocto Project.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='closer-look'>A Closer Look at the Yocto Project Development Environment</link>:</emphasis>
- Provides a more detailed look at the Yocto Project development
- environment within the context of development.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='technical-details'>Technical Details</link>:</emphasis>
- Describes fundamental Yocto Project components as well as an explanation
- behind how the Yocto Project uses shared state (sstate) cache to speed build time.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='migration'>Migrating to a Newer Yocto Project Release</link>:</emphasis>
- Describes release-specific information that helps you move from
- one Yocto Project Release to another.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-structure'>Directory Structure</link>:</emphasis>
- Describes the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink> created
- either by unpacking a released Yocto Project tarball on your host development system,
- or by cloning the upstream
- <ulink url='&YOCTO_DOCS_DEV_URL;#poky'>Poky</ulink> Git repository.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-classes'>Classes</link>:</emphasis>
- Describes the classes used in the Yocto Project.</para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-tasks'>Tasks</link>:</emphasis>
- Describes the tasks defined by the OpenEmbedded build system.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-devtool-reference'><filename>devtool</filename> Quick Reference</link>:</emphasis>
- Provides a quick reference for the <filename>devtool</filename>
- command.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-qa-checks'>QA Error and Warning Messages</link>:</emphasis>
- Lists and describes QA warning and error messages.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-images'>Images</link>:</emphasis>
- Describes the standard images that the Yocto Project supports.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-features'>Features</link>:</emphasis>
- Describes mechanisms for creating distribution, machine, and image
- features during the build process using the OpenEmbedded build system.</para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-variables-glos'>Variables Glossary</link>:</emphasis>
- Presents most variables used by the OpenEmbedded build system, which
- uses BitBake.
- Entries describe the function of the variable and how to apply them.
- </para></listitem>
- <listitem><para><emphasis>
- <link linkend='ref-varlocality'>Variable Context</link>:</emphasis>
- Provides variable locality or context.</para></listitem>
- <listitem><para><emphasis>
- <link linkend='faq'>FAQ</link>:</emphasis>
- Provides answers for commonly asked questions in the Yocto Project
- development environment.</para></listitem>
- <listitem><para><emphasis>
- <link linkend='resources'>Contributing to the Yocto Project</link>:</emphasis>
- Provides guidance on how you can contribute back to the Yocto
- Project.</para></listitem>
- </itemizedlist>
+ The Yocto Project is an open-source collaboration project whose
+ focus is for developers of embedded Linux systems.
+ Among other things, the Yocto Project uses an
+ <link linkend='build-system-term'>OpenEmbedded build system</link>.
+ The build system, which is based on the OpenEmbedded (OE) project and
+ uses the
+ <link linkend='bitbake-term'>BitBake</link> tool, constructs complete
+ Linux images for architectures based on ARM, MIPS, PowerPC, x86 and
+ x86-64.
+ <note>
+ Historically, the OpenEmbedded build system, which is the
+ combination of BitBake and OE components, formed a reference
+ build host that was known as
+ "<link linkend='poky'>Poky</link>" (<emphasis>Pah</emphasis>-kee).
+ The term "Poky", as used throughout the Yocto Project Documentation
+ set, can have different meanings.
+ </note>
+ The Yocto Project provides various ancillary tools for the embedded
+ developer and also features the Sato reference User Interface, which
+ is optimized for stylus-driven, low-resolution screens.
+ </para>
+
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="figures/YP-flow-diagram.png"
+ format="PNG" align='center' width="8in"/>
+ </imageobject>
+ </mediaobject>
+
+ <para>
+ Here are some highlights for the Yocto Project:
+ </para>
+
+ <itemizedlist>
+ <listitem><para>
+ Provides a recent Linux kernel along with a set of system
+ commands and libraries suitable for the embedded
+ environment.
+ </para></listitem>
+ <listitem><para>
+ Makes available system components such as X11, GTK+, Qt,
+ Clutter, and SDL (among others) so you can create a rich user
+ experience on devices that have display hardware.
+ For devices that do not have a display or where you wish to
+ use alternative UI frameworks, these components need not be
+ installed.
+ </para></listitem>
+ <listitem><para>
+ Creates a focused and stable core compatible with the
+ OpenEmbedded project with which you can easily and reliably
+ build and develop.
+ </para></listitem>
+ <listitem><para>
+ Fully supports a wide range of hardware and device emulation
+ through the Quick EMUlator (QEMU).
+ </para></listitem>
+ <listitem><para>
+ Provides a layer mechanism that allows you to easily extend
+ the system, make customizations, and keep them organized.
+ </para></listitem>
+ </itemizedlist>
+
+ <para>
+ You can use the Yocto Project to generate images for many kinds
+ of devices.
+ As mentioned earlier, the Yocto Project supports creation of
+ reference images that you can boot within and emulate using QEMU.
+ The standard example machines target QEMU full-system
+ emulation for 32-bit and 64-bit variants of x86, ARM, MIPS, and
+ PowerPC architectures.
+ Beyond emulation, you can use the layer mechanism to extend
+ support to just about any platform that Linux can run on and that
+ a toolchain can target.
+ </para>
+
+ <para>
+ Another Yocto Project feature is the Sato reference User
+ Interface.
+ This optional UI that is based on GTK+ is intended for devices with
+ restricted screen sizes and is included as part of the
+ OpenEmbedded Core layer so that developers can test parts of the
+ software stack.
+ </para>
+
+ <para>
+ While the Yocto Project does not provide a strict testing framework,
+ it does provide or generate for you artifacts that let you perform
+ target-level and emulated testing and debugging.
+ Additionally, if you are an
+ <trademark class='trade'>Eclipse</trademark> IDE user, you can
+ install an Eclipse Yocto Plug-in to allow you to develop within that
+ familiar environment.
+ </para>
+
+ <para>
+ By default, using the Yocto Project to build an image creates a Poky
+ distribution.
+ However, you can create your own distribution by providing key
+ <link link='metadata'>Metadata</link>.
+ A good example is Angstrom, which has had a distribution
+ based on the Yocto Project since its inception.
+ Other examples include commercial distributions like
+ <ulink url='https://www.yoctoproject.org/organization/wind-river-systems'>Wind River Linux</ulink>,
+ <ulink url='https://www.yoctoproject.org/organization/mentor-graphics'>Mentor Embedded Linux</ulink>,
+ <ulink url='https://www.yoctoproject.org/organization/enea-ab'>ENEA Linux</ulink>
+ and <ulink url='https://www.yoctoproject.org/ecosystem/member-organizations'>others</ulink>.
+ See the "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-your-own-distribution'>Creating Your Own Distribution</ulink>"
+ section in the Yocto Project Development Tasks Manual for more
+ information.
</para>
</section>
-
<section id='intro-requirements'>
<title>System Requirements</title>
<para>
@@ -163,12 +204,12 @@
<listitem><para>Ubuntu 10.04</para></listitem>
<listitem><para>Ubuntu 11.10</para></listitem>
<listitem><para>Ubuntu 12.04 (LTS)</para></listitem>
- <listitem><para>Ubuntu 13.10</para></listitem> -->
- <listitem><para>Ubuntu 14.04 (LTS)</para></listitem>
+ <listitem><para>Ubuntu 13.10</para></listitem>
+ <listitem><para>Ubuntu 14.04 (LTS)</para></listitem> -->
<listitem><para>Ubuntu 14.10</para></listitem>
<listitem><para>Ubuntu 15.04</para></listitem>
<listitem><para>Ubuntu 15.10</para></listitem>
- <listitem><para>Ubuntu 16.04</para></listitem>
+ <listitem><para>Ubuntu 16.04 (LTS)</para></listitem>
<!-- <listitem><para>Fedora 16 (Verne)</para></listitem>
<listitem><para>Fedora 17 (Spherical)</para></listitem>
<listitem><para>Fedora release 19 (Schrödinger's Cat)</para></listitem>
@@ -185,6 +226,7 @@
<!-- <listitem><para>Debian GNU/Linux 6.0 (Squeeze)</para></listitem>
<listitem><para>Debian GNU/Linux 7.x (Wheezy)</para></listitem> -->
<listitem><para>Debian GNU/Linux 8.x (Jessie)</para></listitem>
+ <listitem><para>Debian GNU/Linux 9.x (Stretch)</para></listitem>
<!-- <listitem><para>Debian GNU/Linux 7.1 (Wheezy)</para></listitem>
<listitem><para>Debian GNU/Linux 7.2 (Wheezy)</para></listitem>
<listitem><para>Debian GNU/Linux 7.3 (Wheezy)</para></listitem>
@@ -413,7 +455,7 @@
Python:
<itemizedlist>
<listitem><para>Git 1.8.3.1 or greater</para></listitem>
- <listitem><para>tar 1.24 or greater</para></listitem>
+ <listitem><para>tar 1.27 or greater</para></listitem>
<listitem><para>Python 3.4.0 or greater</para></listitem>
</itemizedlist>
</para>
@@ -492,9 +534,7 @@
On the machine that is able to run BitBake,
be sure you have set up your build environment with
the setup script
- (<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ (<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
</para></listitem>
<listitem><para>
Run the BitBake command to build the tarball:
@@ -512,7 +552,7 @@
<filename>.sh</filename> file that installs
the tools in the <filename>tmp/deploy/sdk</filename>
subdirectory of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
The installer file has the string "buildtools"
in the name.
</para></listitem>
@@ -600,12 +640,441 @@
<title>Development Checkouts</title>
<para>
Development using the Yocto Project requires a local
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You can set up the Source Directory by cloning a copy of the upstream
- <ulink url='&YOCTO_DOCS_DEV_URL;#poky'>poky</ulink> Git repository.
+ <link linkend='poky'>poky</link> Git repository.
For information on how to do this, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#getting-setup'>Getting Set Up</ulink>"
- section in the Yocto Project Development Manual.
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-yocto-project-source-files'>Working With Yocto Project Source Files</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+</section>
+
+<section id='yocto-project-terms'>
+ <title>Yocto Project Terms</title>
+
+ <para>
+ Following is a list of terms and definitions users new to the Yocto
+ Project development environment might find helpful.
+ While some of these terms are universal, the list includes them
+ just in case:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis>Append Files:</emphasis>
+ Files that append build information to a recipe file.
+ Append files are known as BitBake append files and
+ <filename>.bbappend</filename> files.
+ The OpenEmbedded build system expects every append file to have
+ a corresponding recipe (<filename>.bb</filename>) file.
+ Furthermore, the append file and corresponding recipe file
+ must use the same root filename.
+ The filenames can differ only in the file type suffix used
+ (e.g.
+ <filename>formfactor_0.0.bb</filename> and
+ <filename>formfactor_0.0.bbappend</filename>).</para>
+
+ <para>Information in append files extends or overrides the
+ information in the similarly-named recipe file.
+ For an example of an append file in use, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#using-bbappend-files'>Using .bbappend Files in Your Layer</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ <note>
+ Append files can also use wildcard patterns in their
+ version numbers so they can be applied to more than one
+ version of the underlying recipe file.
+ </note>
+ </para></listitem>
+ <listitem><para id='bitbake-term'>
+ <emphasis>BitBake:</emphasis>
+ The task executor and scheduler used by the OpenEmbedded build
+ system to build images.
+ For more information on BitBake, see the
+ <ulink url='&YOCTO_DOCS_BB_URL;'>BitBake User Manual</ulink>.
+ </para></listitem>
+ <listitem><para id='board-support-package-bsp-term'>
+ <emphasis>Board Support Package (BSP):</emphasis>
+ A group of drivers, definitions, and other components that
+ provide support for a specific hardware configuration.
+ For more information on BSPs, see the
+ <ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>.
+ </para></listitem>
+ <listitem>
+ <para id='build-directory'>
+ <emphasis>Build Directory:</emphasis>
+ This term refers to the area used by the OpenEmbedded build
+ system for builds.
+ The area is created when you <filename>source</filename> the
+ setup environment script that is found in the Source Directory
+ (i.e. <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
+ The
+ <link linkend='var-TOPDIR'><filename>TOPDIR</filename></link>
+ variable points to the Build Directory.</para>
+
+ <para>You have a lot of flexibility when creating the Build
+ Directory.
+ Following are some examples that show how to create the
+ directory.
+ The examples assume your
+ <link linkend='source-directory'>Source Directory</link> is
+ named <filename>poky</filename>:
+ <itemizedlist>
+ <listitem><para>Create the Build Directory inside your
+ Source Directory and let the name of the Build
+ Directory default to <filename>build</filename>:
+ <literallayout class='monospaced'>
+ $ cd $HOME/poky
+ $ source &OE_INIT_FILE;
+ </literallayout>
+ </para></listitem>
+ <listitem><para>Create the Build Directory inside your
+ home directory and specifically name it
+ <filename>test-builds</filename>:
+ <literallayout class='monospaced'>
+ $ cd $HOME
+ $ source poky/&OE_INIT_FILE; test-builds
+ </literallayout>
+ </para></listitem>
+ <listitem><para>
+ Provide a directory path and specifically name the
+ Build Directory.
+ Any intermediate folders in the pathname must exist.
+ This next example creates a Build Directory named
+ <filename>YP-&POKYVERSION;</filename>
+ in your home directory within the existing
+ directory <filename>mybuilds</filename>:
+ <literallayout class='monospaced'>
+ $cd $HOME
+ $ source $HOME/poky/&OE_INIT_FILE; $HOME/mybuilds/YP-&POKYVERSION;
+ </literallayout>
+ </para></listitem>
+ </itemizedlist>
+ <note>
+ By default, the Build Directory contains
+ <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>,
+ which is a temporary directory the build system uses for
+ its work.
+ <filename>TMPDIR</filename> cannot be under NFS.
+ Thus, by default, the Build Directory cannot be under NFS.
+ However, if you need the Build Directory to be under NFS,
+ you can set this up by setting <filename>TMPDIR</filename>
+ in your <filename>local.conf</filename> file
+ to use a local drive.
+ Doing so effectively separates <filename>TMPDIR</filename>
+ from <filename>TOPDIR</filename>, which is the Build
+ Directory.
+ </note>
+ </para></listitem>
+ <listitem><para id='hardware-build-system-term'>
+ <emphasis>Build System:</emphasis>
+ The system used to build images in a Yocto Project
+ Development environment.
+ The build system is sometimes referred to as the
+ development host.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Classes:</emphasis>
+ Files that provide for logic encapsulation and inheritance so
+ that commonly used patterns can be defined once and then
+ easily used in multiple recipes.
+ For reference information on the Yocto Project classes, see the
+ "<link linkend='ref-classes'>Classes</link>" chapter.
+ Class files end with the <filename>.bbclass</filename>
+ filename extension.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Configuration File:</emphasis>
+ Configuration information in various <filename>.conf</filename>
+ files provides global definitions of variables.
+ The <filename>conf/local.conf</filename> configuration file in
+ the
+ <link linkend='build-directory'>Build Directory</link>
+ contains user-defined variables that affect every build.
+ The <filename>meta-poky/conf/distro/poky.conf</filename>
+ configuration file defines Yocto "distro" configuration
+ variables used only when building with this policy.
+ Machine configuration files, which
+ are located throughout the
+ <link linkend='source-directory'>Source Directory</link>, define
+ variables for specific hardware and are only used when building
+ for that target (e.g. the
+ <filename>machine/beaglebone.conf</filename> configuration
+ file defines variables for the Texas Instruments ARM Cortex-A8
+ development board).
+ Configuration files end with a <filename>.conf</filename>
+ filename extension.
+ </para></listitem>
+ <listitem><para id='cross-development-toolchain'>
+ <emphasis>Cross-Development Toolchain:</emphasis>
+ In general, a cross-development toolchain is a collection of
+ software development tools and utilities that run on one
+ architecture and allow you to develop software for a
+ different, or targeted, architecture.
+ These toolchains contain cross-compilers, linkers, and
+ debuggers that are specific to the target architecture.</para>
+
+ <para>The Yocto Project supports two different cross-development
+ toolchains:
+ <itemizedlist>
+ <listitem><para>
+ A toolchain only used by and within
+ BitBake when building an image for a target
+ architecture.
+ </para></listitem>
+ <listitem><para>A relocatable toolchain used outside of
+ BitBake by developers when developing applications
+ that will run on a targeted device.
+ </para></listitem>
+ </itemizedlist></para>
+
+ <para>Creation of these toolchains is simple and automated.
+ For information on toolchain concepts as they apply to the
+ Yocto Project, see the
+ "<link linkend='cross-development-toolchain-generation'>Cross-Development Toolchain Generation</link>"
+ section.
+ You can also find more information on using the
+ relocatable toolchain in the
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Image:</emphasis>
+ An image is an artifact of the BitBake build process given
+ a collection of recipes and related Metadata.
+ Images are the binary output that run on specific hardware or
+ QEMU and are used for specific use-cases.
+ For a list of the supported image types that the Yocto Project
+ provides, see the
+ "<link linkend='ref-images'>Images</link>"
+ chapter.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Layer:</emphasis>
+ A collection of recipes representing the core,
+ a BSP, or an application stack.
+ For a discussion specifically on BSP Layers, see the
+ "<ulink url='&YOCTO_DOCS_BSP_URL;#bsp-layers'>BSP Layers</ulink>"
+ section in the Yocto Project Board Support Packages (BSP)
+ Developer's Guide.
+ </para></listitem>
+ <listitem><para id='metadata'>
+ <emphasis>Metadata:</emphasis>
+ The files that BitBake parses when building an image.
+ In general, Metadata includes recipes, classes, and
+ configuration files.
+ In the context of the kernel ("kernel Metadata"), the
+ term refers to the kernel config fragments and features
+ contained in the
+ <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi/yocto-kernel-cache'><filename>yocto-kernel-cache</filename></ulink>
+ Git repository.
+ </para></listitem>
+ <listitem><para id='oe-core'>
+ <emphasis>OE-Core:</emphasis>
+ A core set of Metadata originating with OpenEmbedded (OE)
+ that is shared between OE and the Yocto Project.
+ This Metadata is found in the <filename>meta</filename>
+ directory of the
+ <link linkend='source-directory'>Source Directory</link>.
+ </para></listitem>
+ <listitem><para id='build-system-term'>
+ <emphasis>OpenEmbedded Build System:</emphasis>
+ The build system specific to the Yocto Project.
+ The OpenEmbedded build system is based on another project known
+ as "Poky", which uses
+ <link linkend='bitbake-term'>BitBake</link> as the task
+ executor.
+ Throughout the Yocto Project documentation set, the
+ OpenEmbedded build system is sometimes referred to simply
+ as "the build system".
+ If other build systems, such as a host or target build system
+ are referenced, the documentation clearly states the
+ difference.
+ <note>
+ For some historical information about Poky, see the
+ <link linkend='poky'>Poky</link> term.
+ </note>
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Package:</emphasis>
+ In the context of the Yocto Project, this term refers to a
+ recipe's packaged output produced by BitBake (i.e. a
+ "baked recipe").
+ A package is generally the compiled binaries produced from the
+ recipe's sources.
+ You "bake" something by running it through BitBake.</para>
+
+ <para>It is worth noting that the term "package" can,
+ in general, have subtle meanings.
+ For example, the packages referred to in the
+ "<ulink url='&YOCTO_DOCS_QS_URL;#packages'>The Build Host Packages</ulink>"
+ section in the Yocto Project Quick Start are compiled binaries
+ that, when installed, add functionality to your Linux
+ distribution.</para>
+
+ <para>Another point worth noting is that historically within
+ the Yocto Project, recipes were referred to as packages - thus,
+ the existence of several BitBake variables that are seemingly
+ mis-named,
+ (e.g. <link linkend='var-PR'><filename>PR</filename></link>,
+ <link linkend='var-PV'><filename>PV</filename></link>, and
+ <link linkend='var-PE'><filename>PE</filename></link>).
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Package Groups:</emphasis>
+ Arbitrary groups of software Recipes.
+ You use package groups to hold recipes that, when built,
+ usually accomplish a single task.
+ For example, a package group could contain the recipes for a
+ company’s proprietary or value-add software.
+ Or, the package group could contain the recipes that enable
+ graphics.
+ A package group is really just another recipe.
+ Because package group files are recipes, they end with the
+ <filename>.bb</filename> filename extension.
+ </para></listitem>
+ <listitem><para id='poky'>
+ <emphasis>Poky:</emphasis>
+ The term "poky", which is pronounced
+ <emphasis>Pah</emphasis>-kee, can mean several things:
+ <itemizedlist>
+ <listitem><para>
+ In its most general sense, poky is an open-source
+ project that was initially developed by OpenedHand.
+ OpenedHand developed poky off of the existing
+ OpenEmbedded build system to create a commercially
+ supportable build system for embedded Linux.
+ After Intel Corporation acquired OpenedHand, the
+ poky project became the basis for the Yocto Project's
+ build system.
+ </para></listitem>
+ <listitem><para>
+ Within the Yocto Project
+ <ulink url='&YOCTO_GIT_URL;'>Source Repositories</ulink>,
+ "poky" exists as a separate Git
+ repository from which you can clone to yield a local
+ Git repository that is a copy on your host system.
+ Thus, "poky" can refer to the upstream or
+ local copy of the files used for development within
+ the Yocto Project.
+ </para></listitem>
+ <listitem><para>
+ Finally, "poky" can refer to the default
+ <link linkend='var-DISTRO'><filename>DISTRO</filename></link>
+ (i.e. distribution) created when you use the Yocto
+ Project in conjunction with the
+ <filename>poky</filename> repository to build an image.
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Recipe:</emphasis>
+ A set of instructions for building packages.
+ A recipe describes where you get source code, which patches
+ to apply, how to configure the source, how to compile it and so on.
+ Recipes also describe dependencies for libraries or for other
+ recipes.
+ Recipes represent the logical unit of execution, the software
+ to build, the images to build, and use the
+ <filename>.bb</filename> file extension.
+ </para></listitem>
+ <listitem><para id='reference-kit-term'>
+ <emphasis>Reference Kit:</emphasis>
+ A working example of a system, which includes a
+ <link linkend='board-support-package-bsp-term'>BSP</link>
+ as well as a
+ <link linkend='hardware-build-system-term'>build system</link>
+ and other components, that can work on specific hardware.
+ </para></listitem>
+ <listitem>
+ <para id='source-directory'>
+ <emphasis>Source Directory:</emphasis>
+ This term refers to the directory structure created as a result
+ of creating a local copy of the <filename>poky</filename> Git
+ repository <filename>git://git.yoctoproject.org/poky</filename>
+ or expanding a released <filename>poky</filename> tarball.
+ <note>
+ Creating a local copy of the <filename>poky</filename>
+ Git repository is the recommended method for setting up
+ your Source Directory.
+ </note>
+ Sometimes you might hear the term "poky directory" used to refer
+ to this directory structure.
+ <note>
+ The OpenEmbedded build system does not support file or
+ directory names that contain spaces.
+ Be sure that the Source Directory you use does not contain
+ these types of names.
+ </note></para>
+
+ <para>The Source Directory contains BitBake, Documentation,
+ Metadata and other files that all support the Yocto Project.
+ Consequently, you must have the Source Directory in place on
+ your development system in order to do any development using
+ the Yocto Project.</para>
+
+ <para>When you create a local copy of the Git repository, you
+ can name the repository anything you like.
+ Throughout much of the documentation, "poky"
+ is used as the name of the top-level folder of the local copy of
+ the poky Git repository.
+ So, for example, cloning the <filename>poky</filename> Git
+ repository results in a local Git repository whose top-level
+ folder is also named "poky".</para>
+
+ <para>While it is not recommended that you use tarball expansion
+ to set up the Source Directory, if you do, the top-level
+ directory name of the Source Directory is derived from the
+ Yocto Project release tarball.
+ For example, downloading and unpacking
+ <filename>&YOCTO_POKY_TARBALL;</filename> results in a
+ Source Directory whose root folder is named
+ <filename>&YOCTO_POKY;</filename>.</para>
+
+ <para>It is important to understand the differences between the
+ Source Directory created by unpacking a released tarball as
+ compared to cloning
+ <filename>git://git.yoctoproject.org/poky</filename>.
+ When you unpack a tarball, you have an exact copy of the files
+ based on the time of release - a fixed release point.
+ Any changes you make to your local files in the Source Directory
+ are on top of the release and will remain local only.
+ On the other hand, when you clone the <filename>poky</filename>
+ Git repository, you have an active development repository with
+ access to the upstream repository's branches and tags.
+ In this case, any local changes you make to the local
+ Source Directory can be later applied to active development
+ branches of the upstream <filename>poky</filename> Git
+ repository.</para>
+
+ <para>For more information on concepts related to Git
+ repositories, branches, and tags, see the
+ "<link linkend='repositories-tags-and-branches'>Repositories, Tags, and Branches</link>"
+ section.
+ </para></listitem>
+ <listitem><para><emphasis>Task:</emphasis>
+ A unit of execution for BitBake (e.g.
+ <link linkend='ref-tasks-compile'><filename>do_compile</filename></link>,
+ <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>,
+ <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>,
+ and so forth).
+ </para></listitem>
+ <listitem><para id='toaster-term'><emphasis>Toaster:</emphasis>
+ A web interface to the Yocto Project's
+ <link linkend='build-system-term'>OpenEmbedded Build System</link>.
+ The interface enables you to configure and run your builds.
+ Information about builds is collected and stored in a database.
+ For information on Toaster, see the
+ <ulink url='&YOCTO_DOCS_TOAST_URL;'>Yocto Project Toaster Manual</ulink>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Upstream:</emphasis>
+ A reference to source code or repositories
+ that are not local to the development system but located in a
+ master area that is controlled by the maintainer of the source
+ code.
+ For example, in order for a developer to work on a particular
+ piece of code, they need to first get a copy of it from an
+ "upstream" source.
+ </para></listitem>
+ </itemizedlist>
</para>
</section>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/migration.xml b/import-layers/yocto-poky/documentation/ref-manual/migration.xml
index 7ca929c..811577b 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/migration.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/migration.xml
@@ -251,7 +251,7 @@
The following recipes have been removed.
For most of them, it is unlikely that you would have any
references to them in your own
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>.
+ <link linkend='metadata'>Metadata</link>.
However, you should check your metadata against this list to be sure:
<itemizedlist>
<listitem><para><emphasis><filename>libx11-trim</filename></emphasis>:
@@ -293,7 +293,7 @@
For the remainder, you can now find them in the
<filename>meta-extras</filename> repository, which is in the
Yocto Project
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-repositories'>Source Repositories</ulink>.
+ <link linkend='source-repositories'>Source Repositories</link>.
</para>
</section>
</section>
@@ -438,11 +438,11 @@
you now need to create an append file for the
<filename>init-ifupdown</filename> recipe instead, which you can
find in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
at <filename>meta/recipes-core/init-ifupdown</filename>.
For information on how to use append files, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#using-bbappend-files'>Using .bbappend Files</ulink>"
- in the Yocto Project Development Manual.
+ in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -821,7 +821,7 @@
<listitem><para>
When buildhistory is enabled, its output is now written
under the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
rather than
<link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>.
Doing so makes it easier to delete
@@ -992,7 +992,7 @@
<para>
You can learn more about performing automated image tests in the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -1173,7 +1173,7 @@
class has been rewritten and its configuration has been simplified.
For more details on the source archiver, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -1218,7 +1218,7 @@
<para>
The following changes have been made to
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>.
+ <link linkend='bitbake-term'>BitBake</link>.
</para>
<section id='migration-1.6-matching-branch-requirement-for-git-fetching'>
@@ -1362,7 +1362,7 @@
increments on changes, use the PR service instead.
You can find out more about this service in the
"<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-a-pr-service'>Working With a PR Service</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -1453,7 +1453,7 @@
Package Tests (ptest) are built but not installed by default.
For information on using Package Tests, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#testing-packages-with-ptest'>Setting up and running package test (ptest)</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
For information on the <filename>ptest</filename> class, see the
"<link linkend='ref-classes-ptest'><filename>ptest.bbclass</filename></link>"
section.
@@ -1525,7 +1525,7 @@
<para>
The top-level <filename>LICENSE</filename> file has been changed
to better describe the license of the various components of
- OE-Core.
+ <link linkend='oe-core'>OE-Core</link>.
However, the licensing itself remains unchanged.
</para>
@@ -1748,7 +1748,7 @@
<para>
The minimum
- <ulink url='&YOCTO_DOCS_DEV_URL;#git'>Git</ulink> version required
+ <link linkend='git'>Git</link> version required
on the build host is now 1.7.8 because the
<filename>--list</filename> option is now required by
BitBake's Git fetcher.
@@ -2572,7 +2572,8 @@
<para>
Maintenance tracking data for recipes that was previously part
- of <filename>meta-yocto</filename> has been moved to OE-Core.
+ of <filename>meta-yocto</filename> has been moved to
+ <link linkend='oe-core'>OE-Core</link>.
The change includes <filename>package_regex.inc</filename> and
<filename>distro_alias.inc</filename>, which are typically enabled
when using the
@@ -3000,8 +3001,7 @@
from <filename>autotools</filename> instead.
</para></listitem>
<listitem><para><filename>boot-directdisk</filename>:
- Merged into the
- <link linkend='ref-classes-image-vm'><filename>image-vm</filename></link>
+ Merged into the <filename>image-vm</filename>
class.
The <filename>boot-directdisk</filename> class was rarely
directly used.
@@ -3210,7 +3210,8 @@
You can enable, disable, and test the generation of this data.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#enabling-gobject-introspection-support'>Enabling GObject Introspection Support</ulink>"
- section for more information.
+ section in the Yocto Project Development Tasks Manual
+ for more information.
</para>
</section>
@@ -3419,7 +3420,8 @@
For help preparing metadata, see any of the many Python 3 porting
guides available.
Alternatively, you can reference the conversion commits for Bitbake
- and you can use OE-Core as a guide for changes.
+ and you can use
+ <link linkend='oe-core'>OE-Core</link> as a guide for changes.
Following are particular areas of interest:
<literallayout class='monospaced'>
* subprocess command-line pipes needing locale decoding
@@ -3508,7 +3510,8 @@
hard-coding any knowledge about different machines.
Using a configuration file is particularly convenient when trying
to use QEMU with machines other than the
- <filename>qemu*</filename> machines in OE-Core.
+ <filename>qemu*</filename> machines in
+ <link linkend='oe-core'>OE-Core</link>.
The <filename>qemuboot.conf</filename> file is generated by the
<filename>qemuboot</filename>
class when the root filesystem is being build (i.e.
@@ -4035,7 +4038,7 @@
<para>For an example, see the
<filename>pixbufcache</filename> class in
<filename>meta/classes/</filename> in the Yocto Project
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-repositories'>Source Repositories</ulink>.
+ <link linkend='source-repositories'>Source Repositories</link>.
<note>
The <filename>SSTATEPOSTINSTFUNCS</filename> variable
itself is now deprecated in favor of the
@@ -4478,7 +4481,8 @@
needed by current hardware.
Thus, GStreamer's ivorbis plugin has been disabled
by default eliminating the need for the
- <filename>tremor</filename> recipe in OE-Core.
+ <filename>tremor</filename> recipe in
+ <link linkend='oe-core'>OE-Core</link>.
</para></listitem>
<listitem><para>
<emphasis><filename>gummiboot:</filename></emphasis>
@@ -4495,8 +4499,8 @@
The following changes have been made to Wic:
<note>
For more information on Wic, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-partitioned-images'>Creating Partitioned Images</ulink>"
- section in the Yocto Project Development Manual.
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-partitioned-images-using-wic'>Creating Partitioned Images Using Wic</ulink>"
+ section in the Yocto Project Development Tasks Manual.
</note>
<itemizedlist>
<listitem><para>
@@ -4717,6 +4721,523 @@
</para>
</section>
</section>
+
+<section id='moving-to-the-yocto-project-2.4-release'>
+ <title>Moving to the Yocto Project 2.4 Release</title>
+
+ <para>
+ This section provides migration information for moving to the
+ Yocto Project 2.4 Release from the prior release.
+ </para>
+
+ <section id='migration-2.4-memory-resident-mode'>
+ <title>Memory Resident Mode</title>
+
+ <para>
+ A persistent mode is now available in BitBake's default operation,
+ replacing its previous "memory resident mode" (i.e.
+ <filename>oe-init-build-env-memres</filename>).
+ Now you only need to set
+ <filename>BB_SERVER_TIMEOUT</filename> to a timeout
+ (in seconds) and BitBake's server stays resident for that
+ amount of time between invocations.
+ The <filename>oe-init-build-env-memres</filename> script has been
+ removed since a separate environment setup script is no longer
+ needed.
+ </para>
+ </section>
+
+ <section id='migration-2.4-packaging-changes'>
+ <title>Packaging Changes</title>
+
+ <para>
+ This section provides information about packaging changes that have
+ ocurred:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>python3</filename> Changes:</emphasis>
+ <itemizedlist>
+ <listitem><para>
+ The main "python3" package now brings in all of the
+ standard Python 3 distribution rather than a subset.
+ This behavior matches what is expected based on
+ traditional Linux distributions.
+ If you wish to install a subset of Python 3, specify
+ <filename>python-core</filename> plus one or more of
+ the individual packages that are still produced.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python3</filename>:</emphasis>
+ The <filename>bz2.py</filename>,
+ <filename>lzma.py</filename>, and
+ <filename>_compression.py</filename> scripts have
+ been moved from the
+ <filename>python3-misc</filename> package to
+ the <filename>python3-compression</filename> package.
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>binutils</filename>:</emphasis>
+ The <filename>libbfd</filename> library is now packaged in
+ a separate "libbfd" package.
+ This packaging saves space when certain tools
+ (e.g. <filename>perf</filename>) are installed.
+ In such cases, the tools only need
+ <filename>libbfd</filename> rather than all the packages in
+ <filename>binutils</filename>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>util-linux</filename> Changes:</emphasis>
+ <itemizedlist>
+ <listitem><para>
+ The <filename>su</filename> program is now packaged
+ in a separate "util-linux-su" package, which is only
+ built when "pam" is listed in the
+ <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
+ variable.
+ <filename>util-linux</filename> should not be
+ installed unless it is needed because
+ <filename>su</filename> is normally provided through
+ the shadow file format.
+ The main <filename>util-linux</filename> package has
+ runtime dependencies (i.e.
+ <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>)
+ on the <filename>util-linux-su</filename> package
+ when "pam" is in
+ <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
+ </para></listitem>
+ <listitem><para>
+ The <filename>switch_root</filename> program is now
+ packaged in a separate "util-linux-switch-root"
+ package for small initramfs images that do not need
+ the whole <filename>util-linux</filename> package or
+ the busybox binary, which are both much larger than
+ <filename>switch_root</filename>.
+ The main <filename>util-linux</filename> package has
+ a recommended runtime dependency (i.e.
+ <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
+ on the <filename>util-linux-switch-root</filename> package.
+ </para></listitem>
+ <listitem><para>
+ The <filename>ionice</filename> program is now
+ packaged in a separate "util-linux-ionice" package.
+ The main <filename>util-linux</filename> package has
+ a recommended runtime dependency (i.e.
+ <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
+ on the <filename>util-linux-ionice</filename> package.
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>initscripts</filename>:</emphasis>
+ The <filename>sushell</filename> program is now packaged in
+ a separate "initscripts-sushell" package.
+ This packaging change allows systems to pull
+ <filename>sushell</filename> in when
+ <filename>selinux</filename> is enabled.
+ The change also eliminates needing to pull in the entire
+ <filename>initscripts</filename> package.
+ The main <filename>initscripts</filename> package has a
+ runtime dependency (i.e.
+ <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>)
+ on the <filename>sushell</filename> package when
+ "selinux" is in
+ <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>glib-2.0</filename>:</emphasis>
+ The <filename>glib-2.0</filename> package now has a
+ recommended runtime dependency (i.e.
+ <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
+ on the
+ <filename>shared-mime-info</filename> package, since large
+ portions of GIO are not useful without the MIME database.
+ You can remove the dependency by using the
+ <link linkend='var-BAD_RECOMMENDATIONS'><filename>BAD_RECOMMENDATIONS</filename></link>
+ variable if <filename>shared-mime-info</filename> is too
+ large and is not required.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Go Standard Runtime:</emphasis>
+ The Go standard runtime has been split out from the main
+ <filename>go</filename> recipe into a separate
+ <filename>go-runtime</filename> recipe.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='migration-2.4-removed-recipes'>
+ <title>Removed Recipes</title>
+
+ <para>
+ The following recipes have been removed:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>acpitests</filename>:</emphasis>
+ This recipe is not maintained.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>autogen-native</filename>:</emphasis>
+ No longer required by Grub, oe-core, or meta-oe.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>bdwgc</filename>:</emphasis>
+ Nothing in OpenEmbedded-Core requires this recipe.
+ It has moved to meta-oe.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>byacc</filename>:</emphasis>
+ This recipe was only needed by rpm 5.x and has moved to
+ meta-oe.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>gcc (5.4)</filename>:</emphasis>
+ The 5.4 series dropped the recipe in favor of 6.3 / 7.2.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>gnome-common</filename>:</emphasis>
+ Deprecated upstream and no longer needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>go-bootstrap-native</filename>:</emphasis>
+ Go 1.9 does its own bootstrapping so this recipe has been
+ removed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>guile</filename>:</emphasis>
+ This recipe was only needed by
+ <filename>autogen-native</filename> and
+ <filename>remake</filename>.
+ The recipe is no longer needed by either of these programs.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libclass-isa-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libdumpvalue-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libenv-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libfile-checktree-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libi18n-collate-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libiconv</filename>:</emphasis>
+ This recipe was only needed for <filename>uclibc</filename>,
+ which was removed in the previous release.
+ <filename>glibc</filename> and <filename>musl</filename>
+ have their own implementations.
+ <filename>meta-mingw</filename> still needs
+ <filename>libiconv</filename>, so it has
+ been moved to <filename>meta-mingw</filename>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libpng12</filename>:</emphasis>
+ This recipe was previously needed for LSB. The current
+ <filename>libpng</filename> is 1.6.x.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>libpod-plainer-perl</filename>:</emphasis>
+ This recipe was previously needed for LSB 4, no longer
+ needed.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>linux-yocto (4.1)</filename>:</emphasis>
+ This recipe was removed in favor of 4.4, 4.9, 4.10 and 4.12.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>mailx</filename>:</emphasis>
+ This recipe was previously only needed for LSB
+ compatibility, and upstream is defunct.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>mesa (git version only)</filename>:</emphasis>
+ The git version recipe was stale with respect to the release
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>ofono (git version only)</filename>:</emphasis>
+ The git version recipe was stale with respect to the release
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>portmap</filename>:</emphasis>
+ This recipe is obsolete and is superseded by
+ <filename>rpcbind</filename>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python3-pygpgme</filename>:</emphasis>
+ This recipe is old and unmaintained. It was previously
+ required by <filename>dnf</filename>, which has switched
+ to official <filename>gpgme</filename> Python bindings.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-async</filename>:</emphasis>
+ This recipe has been removed in favor of the Python 3
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-gitdb</filename>:</emphasis>
+ This recipe has been removed in favor of the Python 3
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-git</filename>:</emphasis>
+ This recipe was removed in favor of the Python 3
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-mako</filename>:</emphasis>
+ This recipe was removed in favor of the Python 3
+ version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-pexpect</filename>:</emphasis>
+ This recipe was removed in favor of the Python 3 version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-ptyprocess</filename>:</emphasis>
+ This recipe was removed in favor of Python the 3 version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-pycurl</filename>:</emphasis>
+ Nothing is using this recipe in OpenEmbedded-Core
+ (i.e. <filename>meta-oe</filename>).
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-six</filename>:</emphasis>
+ This recipe was removed in favor of the Python 3 version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>python-smmap</filename>:</emphasis>
+ This recipe was removed in favor of the Python 3 version.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>remake</filename>:</emphasis>
+ Using <filename>remake</filename> as the provider of
+ <filename>virtual/make</filename> is broken.
+ Consequently, this recipe is not needed in OpenEmbedded-Core.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='migration-2.4-kernel-device-tree-move'>
+ <title>Kernel Device Tree Move</title>
+
+ <para>
+ Kernel Device Tree support is now easier to enable in a kernel
+ recipe.
+ The Device Tree code has moved to a
+ <filename>kernel-devicetree</filename> class.
+ Functionality is automatically enabled for any recipe that inherits
+ the
+ <link linkend='ref-classes-kernel'><filename>kernel</filename></link>
+ class and sets the
+ <link linkend='var-KERNEL_DEVICETREE'><filename>KERNEL_DEVICETREE</filename></link>
+ variable.
+ The previous mechanism for doing this,
+ <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>,
+ is still available to avoid breakage, but triggers a
+ deprecation warning.
+ Future releases of the Yocto Project will remove
+ <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>.
+ It is advisable to remove any <filename>require</filename>
+ statements that request
+ <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>
+ from any custom kernel recipes you might have.
+ This will avoid breakage in post 2.4 releases.
+ </para>
+ </section>
+
+ <section id='migration-2.4-package-qa-changes'>
+ <title>Package QA Changes</title>
+
+ <para>
+ The following package QA changes took place:
+ <itemizedlist>
+ <listitem><para>
+ The "unsafe-references-in-scripts" QA check has been
+ removed.
+ </para></listitem>
+ <listitem><para>
+ If you refer to <filename>${COREBASE}/LICENSE</filename>
+ within
+ <link linkend='var-LIC_FILES_CHKSUM'><filename>LIC_FILES_CHKSUM</filename></link>
+ you receive a warning because this file is a description of
+ the license for OE-Core.
+ Use <filename>${COMMON_LICENSE_DIR}/MIT</filename>
+ if your recipe is MIT-licensed and you cannot use the
+ preferred method of referring to a file within the source
+ tree.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='migration-2.4-readme-changes'>
+ <title><filename>README</filename> File Changes</title>
+
+ <para>
+ The following are changes to <filename>README</filename> files:
+ <itemizedlist>
+ <listitem><para>
+ The main Poky <filename>README</filename> file has been
+ moved to the <filename>meta-poky</filename> layer and
+ has been renamed <filename>README.poky</filename>.
+ A symlink has been created so that references to the old
+ location work.
+ </para></listitem>
+ <listitem><para>
+ The <filename>README.hardware</filename> file has been moved
+ to <filename>meta-yocto-bsp</filename>.
+ A symlink has been created so that references to the old
+ location work.
+ </para></listitem>
+ <listitem><para>
+ A <filename>README.qemu</filename> file has been created
+ with coverage of the <filename>qemu*</filename> machines.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='migration-2.4-miscellaneous-changes'>
+ <title>Miscellaneous Changes</title>
+
+ <para>
+ The following are additional changes:
+ <itemizedlist>
+ <listitem><para>
+ The <filename>ROOTFS_PKGMANAGE_BOOTSTRAP</filename>
+ variable and any references to it have been removed.
+ You should remove this variable from any custom recipes.
+ </para></listitem>
+ <listitem><para>
+ The <filename>meta-yocto</filename> directory has been
+ removed.
+ <note>
+ In the Yocto Project 2.1 release
+ <filename>meta-yocto</filename> was renamed to
+ <filename>meta-poky</filename> and the
+ <filename>meta-yocto</filename> subdirectory remained
+ to avoid breaking existing configurations.
+ </note>
+ </para></listitem>
+ <listitem><para>
+ The <filename>maintainers.inc</filename> file, which tracks
+ maintainers by listing a primary person responsible for each
+ recipe in OE-Core, has been moved from
+ <filename>meta-poky</filename> to OE-Core (i.e. from
+ <filename>meta-poky/conf/distro/include</filename> to
+ <filename>meta/conf/distro/include</filename>).
+ </para></listitem>
+ <listitem><para>
+ The
+ <link linkend='ref-classes-buildhistory'><filename>buildhistory</filename></link>
+ class now makes a single commit per build rather than one
+ commit per subdirectory in the repository.
+ This behavior assumes the commits are enabled with
+ <link linkend='var-BUILDHISTORY_COMMIT'><filename>BUILDHISTORY_COMMIT</filename></link>
+ = "1", which is typical.
+ Previously, the <filename>buildhistory</filename> class made
+ one commit per subdirectory in the repository in order to
+ make it easier to see the changes for a particular
+ subdirectory.
+ To view a particular change, specify that subdirectory as
+ the last parameter on the <filename>git show</filename>
+ or <filename>git diff</filename> commands.
+ </para></listitem>
+ <listitem><para>
+ The <filename>x86-base.inc</filename> file, which is
+ included by all x86-based machine configurations, now sets
+ <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
+ using <filename>?=</filename> to "live" rather than
+ appending with <filename>+=</filename>.
+ This change makes the default easier to override.
+ </para></listitem>
+ <listitem><para>
+ BitBake fires multiple "BuildStarted" events when
+ multiconfig is enabled (one per configuration).
+ For more information, see the
+ "<ulink url='&YOCTO_DOCS_BB_URL;#events'>Events</ulink>"
+ in the BitBake User Manual.
+ </para></listitem>
+ <listitem><para>
+ By default, the <filename>security_flags.inc</filename> file
+ sets a <filename>GCCPIE</filename> variable with an option
+ to enable Position Independent Executables (PIE) within
+ <filename>gcc</filename>.
+ Enabling PIE in the GNU C Compiler (GCC), makes Return
+ Oriented Programming (ROP) attacks much more difficult to
+ execute.
+ </para></listitem>
+ <listitem><para>
+ OE-Core now provides a
+ <filename>bitbake-layers</filename> plugin that implements
+ a "create-layer" subcommand.
+ The implementation of this subcommand has resulted in the
+ <filename>yocto-layer</filename> script being deprecated and
+ will likely be removed in the next Yocto Project release.
+ </para></listitem>
+ <listitem><para>
+ The <filename>vmdk</filename>, <filename>vdi</filename>,
+ and <filename>qcow2</filename> image file types are now
+ used in conjunction with the "wic" image type through
+ <filename>CONVERSION_CMD</filename>.
+ Consequently, the equivalent image types are now
+ <filename>wic.vmdk</filename>, <filename>wic.vdi</filename>,
+ and <filename>wic.qcow2</filename>, respectively.
+ </para></listitem>
+ <listitem><para>
+ <filename>do_image_<type>[depends]</filename> has
+ replaced <filename>IMAGE_DEPENDS_<type></filename>.
+ If you have your own classes that implement custom image
+ types, then you need to update them.
+ </para></listitem>
+ <listitem><para>
+ OpenSSL 1.1 has been introduced.
+ However, the default is still 1.0.x through the
+ <link linkend='var-PREFERRED_VERSION'><filename>PREFERRED_VERSION</filename></link>
+ variable.
+ This preference is set is due to the remaining compatibility
+ issues with other software.
+ The
+ <link linkend='var-PROVIDES'><filename>PROVIDES</filename></link>
+ variable in the openssl 1.0 recipe now includes "openssl10"
+ as a marker that can be used in
+ <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>
+ within recipes that build software that still depend on
+ OpenSSL 1.0.
+ </para></listitem>
+ <listitem><para>
+ To ensure consistent behavior, BitBake's "-r" and "-R"
+ options (i.e. prefile and postfile), which are used to
+ read or post-read additional configuration files from the
+ command line, now only affect the current BitBake command.
+ Before these BitBake changes, these options would "stick"
+ for future executions.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+</section>
</chapter>
<!--
vim: expandtab tw=80 ts=4
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-bitbake.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-bitbake.xml
index 2f36e16..17f4c54 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-bitbake.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-bitbake.xml
@@ -8,7 +8,7 @@
<para>
BitBake is a program written in Python that interprets the
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink> used by
+ <link linkend='metadata'>Metadata</link> used by
the OpenEmbedded build system.
At some point, developers wonder what actually happens when you enter:
<literallayout class='monospaced'>
@@ -24,7 +24,7 @@
BitBake strives to be a generic "task" executor that is capable of handling complex dependency relationships.
As such, it has no real knowledge of what the tasks being executed actually do.
BitBake just considers a list of tasks with dependencies and handles
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
consisting of variables in a certain format that get passed to the tasks.
</note>
@@ -36,9 +36,10 @@
</para>
<para>
- The first thing BitBake does is look for the <filename>bitbake.conf</filename> file.
+ The first thing BitBake does is look for the
+ <filename>bitbake.conf</filename> file.
This file resides in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
within the <filename>meta/conf/</filename> directory.
BitBake finds it by examining its
<link linkend='var-BBPATH'><filename>BBPATH</filename></link> environment
@@ -92,8 +93,8 @@
<filename>meta/recipes-*/</filename> directory within Poky.
Adding extra content to <filename>BBFILES</filename> is best achieved through the use of
BitBake layers as described in the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and
- Creating Layers</ulink>" section of the Yocto Project Development Manual.
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and Creating Layers</ulink>"
+ section of the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -227,13 +228,14 @@
<para>
Dependencies are defined through several variables.
- You can find information about variables BitBake uses in the BitBake documentation,
- which is found in the <filename>bitbake/doc/manual</filename> directory within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ You can find information about variables BitBake uses in the
+ BitBake documentation, which is found in the
+ <filename>bitbake/doc/manual</filename> directory within the
+ <link linkend='source-directory'>Source Directory</link>.
At a basic level, it is sufficient to know that BitBake uses the
<filename><link linkend='var-DEPENDS'>DEPENDS</link></filename> and
- <filename><link linkend='var-RDEPENDS'>RDEPENDS</link></filename> variables when
- calculating dependencies.
+ <filename><link linkend='var-RDEPENDS'>RDEPENDS</link></filename>
+ variables when calculating dependencies.
</para>
</section>
@@ -448,20 +450,23 @@
You can find information about the options and formats of entries for specific
fetchers in the BitBake manual located in the
<filename>bitbake/doc/manual</filename> directory of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
<para>
- One useful feature for certain Source Code Manager (SCM) fetchers is the ability to
- "auto-update" when the upstream SCM changes version.
- Since this ability requires certain functionality from the SCM, not all
- systems support it.
- Currently Subversion, Bazaar and to a limited extent, Git support the ability to "auto-update".
+ One useful feature for certain Source Code Manager (SCM) fetchers
+ is the ability to "auto-update" when the upstream SCM changes
+ version.
+ Since this ability requires certain functionality from the SCM,
+ not all systems support it.
+ Currently Subversion, Bazaar and to a limited extent, Git support
+ the ability to "auto-update".
This feature works using the <filename><link linkend='var-SRCREV'>SRCREV</link></filename>
variable.
See the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-srcrev'>Using an External SCM</ulink>" section
- in the Yocto Project Development Manual for more information.
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-srcrev'>Using an External SCM</ulink>"
+ section in the Yocto Project Development Tasks Manual for more
+ information.
</para>
</section>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-classes.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-classes.xml
index c88162b..5961d3e 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-classes.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-classes.xml
@@ -16,12 +16,12 @@
</para>
<para>
- Any <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink> usually
+ Any <link linkend='metadata'>Metadata</link> usually
found in a recipe can also be placed in a class file.
Class files are identified by the extension <filename>.bbclass</filename>
and are usually placed in a <filename>classes/</filename> directory beneath
the <filename>meta*/</filename> directory found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
Class files can also be pointed to by
<link linkend='var-BUILDDIR'><filename>BUILDDIR</filename></link>
(e.g. <filename>build/</filename>) in the same way as
@@ -36,7 +36,7 @@
This chapter discusses only the most useful and important classes.
Other classes do exist within the <filename>meta/classes</filename>
directory in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You can reference the <filename>.bbclass</filename> files directly
for more information.
</para>
@@ -94,7 +94,7 @@
<para>
For more details on the source archiver, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
You can also see the
<link linkend='var-ARCHIVER_MODE'><filename>ARCHIVER_MODE</filename></link>
variable for information about the variable flags (varflags)
@@ -122,7 +122,7 @@
These classes can also work with software that emulates Autotools.
For more information, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-autotooled-package'>Autotooled Package</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -333,7 +333,7 @@
For details on how the class works, see the
<filename>meta/classes/bluetooth.bbclass</filename> file in the Yocto
Project
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
</section>
@@ -641,7 +641,7 @@
Distribution policy dictates whether to include this class.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devshell'>Using a Development Shell</ulink>" section
- in the Yocto Project Development Manual for more information about
+ in the Yocto Project Development Tasks Manual for more information about
using <filename>devshell</filename>.
</para>
</section>
@@ -816,11 +816,11 @@
For more information on the
<filename>externalsrc</filename> class, see the comments in
<filename>meta/classes/externalsrc.bbclass</filename> in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
For information on how to use the <filename>externalsrc</filename>
class, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-software-from-an-external-source'>Building Software from an External Source</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -1247,7 +1247,7 @@
</itemizedlist>
For information on customizing images, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#usingpoky-extend-customimage'>Customizing Images</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
For information on how images are created, see the
"<link linkend='images-dev-environment'>Images</link>" section elsewhere
in this manual.
@@ -1286,14 +1286,15 @@
<filename>image_types</filename> must also appear in
<filename>IMAGE_CLASSES</filename>.
</para>
-</section>
-
-<section id='ref-classes-image_types_uboot'>
- <title><filename>image_types_uboot.bbclass</filename></title>
<para>
- The <filename>image_types_uboot</filename> class
- defines additional image types specifically for the U-Boot bootloader.
+ This class also handles conversion and compression of images.
+ <note>
+ To build a VMware VMDK image, you need to add "wic.vmdk" to
+ <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>.
+ This would also be similar for Virtual Box Virtual Disk Image
+ ("vdi") and QEMU Copy On Write Version 2 ("qcow2") images.
+ </note>
</para>
</section>
@@ -1370,27 +1371,6 @@
</para>
</section>
-<section id='ref-classes-image-vm'>
- <title><filename>image-vm.bbclass</filename></title>
-
- <para>
- The <filename>image-vm</filename> class supports building VM
- images.
- </para>
-</section>
-
-<section id='ref-classes-image-vmdk'>
- <title><filename>image-vmdk.bbclass</filename></title>
-
- <para>
- The <filename>image-vmdk</filename> class supports building VMware
- VMDK images.
- Normally, you do not use this class directly.
- Instead, you add "vmdk" to
- <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>.
- </para>
-</section>
-
<section id='ref-classes-insane'>
<title><filename>insane.bbclass</filename></title>
@@ -1788,27 +1768,6 @@
</note>
</para></listitem>
-->
- <listitem><para><emphasis><filename>unsafe-references-in-scripts:</filename></emphasis>
- Reports when a script file installed in
- <filename>${base_libdir}</filename>,
- <filename>${base_bindir}</filename>, or
- <filename>${base_sbindir}</filename>, depends on files
- installed under <filename>${exec_prefix}</filename>.
- This dependency is a concern if you want the system to remain
- basically operable if <filename>/usr</filename> is mounted
- separately and is not mounted.
- <note>
- Defaults for binaries installed in
- <filename>${base_libdir}</filename>,
- <filename>${base_bindir}</filename>, and
- <filename>${base_sbindir}</filename> are
- <filename>/lib</filename>, <filename>/bin</filename>, and
- <filename>/sbin</filename>, respectively.
- The default for a binary installed
- under <filename>${exec_prefix}</filename> is
- <filename>/usr</filename>.
- </note>
- </para></listitem>
<listitem><para><emphasis><filename>useless-rpaths:</filename></emphasis>
Checks for dynamic library load paths (rpaths) in the binaries that
by default on a standard system are searched by the linker (e.g.
@@ -1900,7 +1859,7 @@
you build the kernel image.
For information on how to build an initramfs, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -2194,7 +2153,7 @@
<para>
For more information on using the Multilib feature, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#combining-multiple-versions-library-files-into-one-image'>Combining Multiple Versions of Library Files into One Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -2328,7 +2287,7 @@
The <filename>oelint</filename> class is an
obsolete lint checking tool that exists in
<filename>meta/classes</filename> in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
<para>
@@ -2393,7 +2352,7 @@
<filename><link linkend='var-PACKAGE_CLASSES'>PACKAGE_CLASSES</link></filename>
variable defined in your <filename>conf/local.conf</filename>
configuration file, which is located in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
When defining the variable, you can specify one or more package types.
Since images are generated from packages, a packaging class is
needed to enable image generation.
@@ -2407,7 +2366,7 @@
on the target (i.e. runtime installation of packages).
For more information, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#using-runtime-package-management'>Using Runtime Package Management</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -2419,7 +2378,7 @@
all dependencies previously built.
The reason for this discrepancy is because the RPM package manager
creates and processes more
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink> than the
+ <link linkend='metadata'>Metadata</link> than the
IPK package manager.
Consequently, you might consider setting
<filename>PACKAGE_CLASSES</filename> to "package_ipk" if you are
@@ -2587,7 +2546,7 @@
<para>
For information on how to use this class, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#usingpoky-extend-customimage-customtasks'>Customizing Images Using Custom Package Groups</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -2676,7 +2635,8 @@
<link linkend='ref-tasks-populate_sdk'><filename>do_populate_sdk</filename></link>
task, see the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</para>
</section>
@@ -2756,8 +2716,8 @@
<link linkend='ref-tasks-populate_sdk'><filename>do_populate_sdk</filename></link>
task, see the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's
- Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</para>
</section>
@@ -2830,8 +2790,8 @@
<link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#testing-packages-with-ptest'>Testing Packages With ptest</ulink>"
- section in the Yocto Project Development Manual for more information
- on ptest.
+ section in the Yocto Project Development Tasks Manual for more
+ information on ptest.
</para>
</section>
@@ -2847,7 +2807,7 @@
<para>
For information on setting up and running ptests, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#testing-packages-with-ptest'>Testing Packages With ptest</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -2988,7 +2948,7 @@
as the build progresses, you can enable <filename>rm_work</filename>
by adding the following to your <filename>local.conf</filename> file,
which is found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
<literallayout class='monospaced'>
INHERIT += "rm_work"
</literallayout>
@@ -3455,7 +3415,7 @@
<para>
For more information on <filename>systemd</filename>, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#selecting-an-initialization-manager'>Selecting an Initialization Manager</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -3555,7 +3515,7 @@
<para>
For information on how to enable, run, and create new tests, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -3737,7 +3697,8 @@
provide pathnames for links, default links for targets, and
so forth.
For details on how to use this class, see the comments in the
- <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi/poky/tree/meta/classes/update-alternatives.bbclass'><filename>update-alternatives.bbclass</filename></ulink>.
+ <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi/poky/tree/meta/classes/update-alternatives.bbclass'><filename>update-alternatives.bbclass</filename></ulink>
+ file.
</para>
<note>
@@ -3777,8 +3738,9 @@
For example, if you have packages that contain system services that
should be run under their own user or group, you can use these classes
to enable creation of the user or group.
- The <filename>meta-skeleton/recipes-skeleton/useradd/useradd-example.bb</filename>
- recipe in the <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ The
+ <filename>meta-skeleton/recipes-skeleton/useradd/useradd-example.bb</filename>
+ recipe in the <link linkend='source-directory'>Source Directory</link>
provides a simple example that shows how to add three
users and groups to two packages.
See the <filename>useradd-example.bb</filename> recipe for more
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-development-environment.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-development-environment.xml
new file mode 100644
index 0000000..52197d1
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-development-environment.xml
@@ -0,0 +1,2761 @@
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
+[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
+
+<chapter id='ref-development-environment'>
+<title>The Yocto Project Development Environment</title>
+
+<para>
+ This chapter takes a look at the Yocto Project development
+ environment and also provides a detailed look at what goes on during
+ development in that environment.
+ The chapter provides Yocto Project Development environment concepts that
+ help you understand how work is accomplished in an open source environment,
+ which is very different as compared to work accomplished in a closed,
+ proprietary environment.
+</para>
+
+<para>
+ Specifically, this chapter addresses open source philosophy, workflows,
+ Git, source repositories, licensing, recipe syntax, and development
+ syntax.
+</para>
+
+<section id='open-source-philosophy'>
+ <title>Open Source Philosophy</title>
+
+ <para>
+ Open source philosophy is characterized by software development
+ directed by peer production and collaboration through an active
+ community of developers.
+ Contrast this to the more standard centralized development models
+ used by commercial software companies where a finite set of developers
+ produces a product for sale using a defined set of procedures that
+ ultimately result in an end product whose architecture and source
+ material are closed to the public.
+ </para>
+
+ <para>
+ Open source projects conceptually have differing concurrent agendas,
+ approaches, and production.
+ These facets of the development process can come from anyone in the
+ public (community) that has a stake in the software project.
+ The open source environment contains new copyright, licensing, domain,
+ and consumer issues that differ from the more traditional development
+ environment.
+ In an open source environment, the end product, source material,
+ and documentation are all available to the public at no cost.
+ </para>
+
+ <para>
+ A benchmark example of an open source project is the Linux kernel,
+ which was initially conceived and created by Finnish computer science
+ student Linus Torvalds in 1991.
+ Conversely, a good example of a non-open source project is the
+ <trademark class='registered'>Windows</trademark> family of operating
+ systems developed by
+ <trademark class='registered'>Microsoft</trademark> Corporation.
+ </para>
+
+ <para>
+ Wikipedia has a good historical description of the Open Source
+ Philosophy
+ <ulink url='http://en.wikipedia.org/wiki/Open_source'>here</ulink>.
+ You can also find helpful information on how to participate in the
+ Linux Community
+ <ulink url='http://ldn.linuxfoundation.org/book/how-participate-linux-community'>here</ulink>.
+ </para>
+</section>
+
+<section id='workflows'>
+ <title>Workflows</title>
+
+ <para>
+ This section provides workflow concepts using the Yocto Project and
+ Git.
+ In particular, the information covers basic practices that describe
+ roles and actions in a collaborative development environment.
+ <note>
+ If you are familiar with this type of development environment, you
+ might not want to read this section.
+ </note>
+ </para>
+
+ <para>
+ The Yocto Project files are maintained using Git in "master"
+ branches whose Git histories track every change and whose structures
+ provides branches for all diverging functionality.
+ Although there is no need to use Git, many open source projects do so.
+ <para>
+
+ </para>
+ For the Yocto Project, a key individual called the "maintainer" is
+ responsible for the "master" branch of a given Git repository.
+ The "master" branch is the “upstream” repository from which final or
+ most recent builds of the project occur.
+ The maintainer is responsible for accepting changes from other
+ developers and for organizing the underlying branch structure to
+ reflect release strategies and so forth.
+ <note>For information on finding out who is responsible for (maintains)
+ a particular area of code, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#how-to-submit-a-change'>Submitting a Change to the Yocto Project</ulink>"
+ section of the Yocto Project Development Tasks Manual.
+ </note>
+ </para>
+
+ <para>
+ The Yocto Project <filename>poky</filename> Git repository also has an
+ upstream contribution Git repository named
+ <filename>poky-contrib</filename>.
+ You can see all the branches in this repository using the web interface
+ of the
+ <ulink url='&YOCTO_GIT_URL;'>Source Repositories</ulink> organized
+ within the "Poky Support" area.
+ These branches temporarily hold changes to the project that have been
+ submitted or committed by the Yocto Project development team and by
+ community members who contribute to the project.
+ The maintainer determines if the changes are qualified to be moved
+ from the "contrib" branches into the "master" branch of the Git
+ repository.
+ </para>
+
+ <para>
+ Developers (including contributing community members) create and
+ maintain cloned repositories of the upstream "master" branch.
+ The cloned repositories are local to their development platforms and
+ are used to develop changes.
+ When a developer is satisfied with a particular feature or change,
+ they "push" the changes to the appropriate "contrib" repository.
+ </para>
+
+ <para>
+ Developers are responsible for keeping their local repository
+ up-to-date with "master".
+ They are also responsible for straightening out any conflicts that
+ might arise within files that are being worked on simultaneously by
+ more than one person.
+ All this work is done locally on the developer’s machine before
+ anything is pushed to a "contrib" area and examined at the maintainer’s
+ level.
+ </para>
+
+ <para>
+ A somewhat formal method exists by which developers commit changes
+ and push them into the "contrib" area and subsequently request that
+ the maintainer include them into "master".
+ This process is called “submitting a patch” or "submitting a change."
+ For information on submitting patches and changes, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#how-to-submit-a-change'>Submitting a Change to the Yocto Project</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+
+ <para>
+ To summarize the development workflow: a single point of entry
+ exists for changes into the project’s "master" branch of the
+ Git repository, which is controlled by the project’s maintainer.
+ And, a set of developers exist who independently develop, test, and
+ submit changes to "contrib" areas for the maintainer to examine.
+ The maintainer then chooses which changes are going to become a
+ permanent part of the project.
+ </para>
+
+ <para>
+ <imagedata fileref="figures/git-workflow.png" width="6in" depth="3in" align="left" scalefit="1" />
+ </para>
+
+ <para>
+ While each development environment is unique, there are some best
+ practices or methods that help development run smoothly.
+ The following list describes some of these practices.
+ For more information about Git workflows, see the workflow topics in
+ the
+ <ulink url='http://book.git-scm.com'>Git Community Book</ulink>.
+ <itemizedlist>
+ <listitem><para>
+ <emphasis>Make Small Changes:</emphasis>
+ It is best to keep the changes you commit small as compared to
+ bundling many disparate changes into a single commit.
+ This practice not only keeps things manageable but also allows
+ the maintainer to more easily include or refuse changes.</para>
+
+ <para>It is also good practice to leave the repository in a
+ state that allows you to still successfully build your project.
+ In other words, do not commit half of a feature,
+ then add the other half as a separate, later commit.
+ Each commit should take you from one buildable project state
+ to another buildable state.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Use Branches Liberally:</emphasis>
+ It is very easy to create, use, and delete local branches in
+ your working Git repository.
+ You can name these branches anything you like.
+ It is helpful to give them names associated with the particular
+ feature or change on which you are working.
+ Once you are done with a feature or change and have merged it
+ into your local master branch, simply discard the temporary
+ branch.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Merge Changes:</emphasis>
+ The <filename>git merge</filename> command allows you to take
+ the changes from one branch and fold them into another branch.
+ This process is especially helpful when more than a single
+ developer might be working on different parts of the same
+ feature.
+ Merging changes also automatically identifies any collisions
+ or "conflicts" that might happen as a result of the same lines
+ of code being altered by two different developers.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Manage Branches:</emphasis>
+ Because branches are easy to use, you should use a system
+ where branches indicate varying levels of code readiness.
+ For example, you can have a "work" branch to develop in, a
+ "test" branch where the code or change is tested, a "stage"
+ branch where changes are ready to be committed, and so forth.
+ As your project develops, you can merge code across the
+ branches to reflect ever-increasing stable states of the
+ development.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Use Push and Pull:</emphasis>
+ The push-pull workflow is based on the concept of developers
+ "pushing" local commits to a remote repository, which is
+ usually a contribution repository.
+ This workflow is also based on developers "pulling" known
+ states of the project down into their local development
+ repositories.
+ The workflow easily allows you to pull changes submitted by
+ other developers from the upstream repository into your
+ work area ensuring that you have the most recent software
+ on which to develop.
+ The Yocto Project has two scripts named
+ <filename>create-pull-request</filename> and
+ <filename>send-pull-request</filename> that ship with the
+ release to facilitate this workflow.
+ You can find these scripts in the <filename>scripts</filename>
+ folder of the
+ <link linkend='source-directory'>Source Directory</link>.
+ For information on how to use these scripts, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#pushing-a-change-upstream'>Using Scripts to Push a Change Upstream and Request a Pull</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Patch Workflow:</emphasis>
+ This workflow allows you to notify the maintainer through an
+ email that you have a change (or patch) you would like
+ considered for the "master" branch of the Git repository.
+ To send this type of change, you format the patch and then
+ send the email using the Git commands
+ <filename>git format-patch</filename> and
+ <filename>git send-email</filename>.
+ For information on how to use these scripts, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#how-to-submit-a-change'>Submitting a Change to the Yocto Project</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+</section>
+
+<section id='git'>
+ <title>Git</title>
+
+ <para>
+ The Yocto Project makes extensive use of Git, which is a
+ free, open source distributed version control system.
+ Git supports distributed development, non-linear development,
+ and can handle large projects.
+ It is best that you have some fundamental understanding
+ of how Git tracks projects and how to work with Git if
+ you are going to use the Yocto Project for development.
+ This section provides a quick overview of how Git works and
+ provides you with a summary of some essential Git commands.
+ <note><title>Notes</title>
+ <itemizedlist>
+ <listitem><para>
+ For more information on Git, see
+ <ulink url='http://git-scm.com/documentation'></ulink>.
+ </para></listitem>
+ <listitem><para>
+ If you need to download Git, it is recommended that you add
+ Git to your system through your distribution's "software
+ store" (e.g. for Ubuntu, use the Ubuntu Software feature).
+ For the Git download page, see
+ <ulink url='http://git-scm.com/download'></ulink>.
+ </para></listitem>
+ <listitem><para>
+ For examples beyond the limited few in this section on how
+ to use Git with the Yocto Project, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-yocto-project-source-files'>Working With Yocto Project Source Files</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ </itemizedlist>
+ </note>
+ </para>
+
+ <section id='repositories-tags-and-branches'>
+ <title>Repositories, Tags, and Branches</title>
+
+ <para>
+ As mentioned briefly in the previous section and also in the
+ "<link linkend='workflows'>Workflows</link>" section,
+ the Yocto Project maintains source repositories at
+ <ulink url='&YOCTO_GIT_URL;/cgit.cgi'></ulink>.
+ If you look at this web-interface of the repositories, each item
+ is a separate Git repository.
+ </para>
+
+ <para>
+ Git repositories use branching techniques that track content
+ change (not files) within a project (e.g. a new feature or updated
+ documentation).
+ Creating a tree-like structure based on project divergence allows
+ for excellent historical information over the life of a project.
+ This methodology also allows for an environment from which you can
+ do lots of local experimentation on projects as you develop
+ changes or new features.
+ </para>
+
+ <para>
+ A Git repository represents all development efforts for a given
+ project.
+ For example, the Git repository <filename>poky</filename> contains
+ all changes and developments for Poky over the course of its
+ entire life.
+ That means that all changes that make up all releases are captured.
+ The repository maintains a complete history of changes.
+ </para>
+
+ <para>
+ You can create a local copy of any repository by "cloning" it
+ with the <filename>git clone</filename> command.
+ When you clone a Git repository, you end up with an identical
+ copy of the repository on your development system.
+ Once you have a local copy of a repository, you can take steps to
+ develop locally.
+ For examples on how to clone Git repositories, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-yocto-project-source-files'>Working With Yocto Project Source Files</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+
+ <para>
+ It is important to understand that Git tracks content change and
+ not files.
+ Git uses "branches" to organize different development efforts.
+ For example, the <filename>poky</filename> repository has
+ several branches that include the current "&DISTRO_NAME_NO_CAP;"
+ branch, the "master" branch, and many branches for past
+ Yocto Project releases.
+ You can see all the branches by going to
+ <ulink url='&YOCTO_GIT_URL;/cgit.cgi/poky/'></ulink> and
+ clicking on the
+ <filename><ulink url='&YOCTO_GIT_URL;/cgit.cgi/poky/refs/heads'>[...]</ulink></filename>
+ link beneath the "Branch" heading.
+ </para>
+
+ <para>
+ Each of these branches represents a specific area of development.
+ The "master" branch represents the current or most recent
+ development.
+ All other branches represent offshoots of the "master" branch.
+ </para>
+
+ <para>
+ When you create a local copy of a Git repository, the copy has
+ the same set of branches as the original.
+ This means you can use Git to create a local working area
+ (also called a branch) that tracks a specific development branch
+ from the upstream source Git repository.
+ in other words, you can define your local Git environment to
+ work on any development branch in the repository.
+ To help illustrate, consider the following example Git commands:
+ <literallayout class='monospaced'>
+ $ cd ~
+ $ git clone git://git.yoctoproject.org/poky
+ $ cd poky
+ $ git checkout -b &DISTRO_NAME_NO_CAP; origin/&DISTRO_NAME_NO_CAP;
+ </literallayout>
+ In the previous example after moving to the home directory, the
+ <filename>git clone</filename> command creates a
+ local copy of the upstream <filename>poky</filename> Git repository.
+ By default, Git checks out the "master" branch for your work.
+ After changing the working directory to the new local repository
+ (i.e. <filename>poky</filename>), the
+ <filename>git checkout</filename> command creates
+ and checks out a local branch named "&DISTRO_NAME_NO_CAP;", which
+ tracks the upstream "origin/&DISTRO_NAME_NO_CAP;" branch.
+ Changes you make while in this branch would ultimately affect
+ the upstream "&DISTRO_NAME_NO_CAP;" branch of the
+ <filename>poky</filename> repository.
+ </para>
+
+ <para>
+ It is important to understand that when you create and checkout a
+ local working branch based on a branch name,
+ your local environment matches the "tip" of that particular
+ development branch at the time you created your local branch,
+ which could be different from the files in the "master" branch
+ of the upstream repository.
+ In other words, creating and checking out a local branch based on
+ the "&DISTRO_NAME_NO_CAP;" branch name is not the same as
+ cloning and checking out the "master" branch if the repository.
+ Keep reading to see how you create a local snapshot of a Yocto
+ Project Release.
+ </para>
+
+ <para>
+ Git uses "tags" to mark specific changes in a repository.
+ Typically, a tag is used to mark a special point such as the final
+ change before a project is released.
+ You can see the tags used with the <filename>poky</filename> Git
+ repository by going to
+ <ulink url='&YOCTO_GIT_URL;/cgit.cgi/poky/'></ulink> and
+ clicking on the
+ <filename><ulink url='&YOCTO_GIT_URL;/cgit.cgi/poky/refs/tags'>[...]</ulink></filename>
+ link beneath the "Tag" heading.
+ </para>
+
+ <para>
+ Some key tags for the <filename>poky</filename> are
+ <filename>jethro-14.0.3</filename>,
+ <filename>morty-16.0.1</filename>,
+ <filename>pyro-17.0.0</filename>, and
+ <filename>&DISTRO_NAME_NO_CAP;-&POKYVERSION;</filename>.
+ These tags represent Yocto Project releases.
+ </para>
+
+ <para>
+ When you create a local copy of the Git repository, you also
+ have access to all the tags in the upstream repository.
+ Similar to branches, you can create and checkout a local working
+ Git branch based on a tag name.
+ When you do this, you get a snapshot of the Git repository that
+ reflects the state of the files when the change was made associated
+ with that tag.
+ The most common use is to checkout a working branch that matches
+ a specific Yocto Project release.
+ Here is an example:
+ <literallayout class='monospaced'>
+ $ cd ~
+ $ git clone git://git.yoctoproject.org/poky
+ $ cd poky
+ $ git fetch --all --tags --prune
+ $ git checkout tags/pyro-17.0.0 -b my-pyro-17.0.0
+ </literallayout>
+ In this example, the name of the top-level directory of your
+ local Yocto Project repository is <filename>poky</filename>.
+ After moving to the <filename>poky</filename> directory, the
+ <filename>git fetch</filename> command makes all the upstream
+ tags available locally in your repository.
+ Finally, the <filename>git checkout</filename> command
+ creates and checks out a branch named "my-pyro-17.0.0" that is
+ based on the specific change upstream in the repository
+ associated with the "pyro-17.0.0" tag.
+ The files in your repository now exactly match that particular
+ Yocto Project release as it is tagged in the upstream Git
+ repository.
+ It is important to understand that when you create and
+ checkout a local working branch based on a tag, your environment
+ matches a specific point in time and not the entire development
+ branch (i.e. the "tip" of the branch).
+ </para>
+ </section>
+
+ <section id='basic-commands'>
+ <title>Basic Commands</title>
+
+ <para>
+ Git has an extensive set of commands that lets you manage changes
+ and perform collaboration over the life of a project.
+ Conveniently though, you can manage with a small set of basic
+ operations and workflows once you understand the basic
+ philosophy behind Git.
+ You do not have to be an expert in Git to be functional.
+ A good place to look for instruction on a minimal set of Git
+ commands is
+ <ulink url='http://git-scm.com/documentation'>here</ulink>.
+ </para>
+
+ <para>
+ If you do not know much about Git, you should educate
+ yourself by visiting the links previously mentioned.
+ </para>
+
+ <para>
+ The following list of Git commands briefly describes some basic
+ Git operations as a way to get started.
+ As with any set of commands, this list (in most cases) simply shows
+ the base command and omits the many arguments they support.
+ See the Git documentation for complete descriptions and strategies
+ on how to use these commands:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>git init</filename>:</emphasis>
+ Initializes an empty Git repository.
+ You cannot use Git commands unless you have a
+ <filename>.git</filename> repository.
+ </para></listitem>
+ <listitem><para id='git-commands-clone'>
+ <emphasis><filename>git clone</filename>:</emphasis>
+ Creates a local clone of a Git repository that is on
+ equal footing with a fellow developer’s Git repository
+ or an upstream repository.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git add</filename>:</emphasis>
+ Locally stages updated file contents to the index that
+ Git uses to track changes.
+ You must stage all files that have changed before you
+ can commit them.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git commit</filename>:</emphasis>
+ Creates a local "commit" that documents the changes you
+ made.
+ Only changes that have been staged can be committed.
+ Commits are used for historical purposes, for determining
+ if a maintainer of a project will allow the change,
+ and for ultimately pushing the change from your local
+ Git repository into the project’s upstream repository.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git status</filename>:</emphasis>
+ Reports any modified files that possibly need to be
+ staged and gives you a status of where you stand regarding
+ local commits as compared to the upstream repository.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git checkout</filename> <replaceable>branch-name</replaceable>:</emphasis>
+ Changes your working branch.
+ This command is analogous to "cd".
+ </para></listitem>
+ <listitem><para><emphasis><filename>git checkout –b</filename> <replaceable>working-branch</replaceable>:</emphasis>
+ Creates and checks out a working branch on your local
+ machine that you can use to isolate your work.
+ It is a good idea to use local branches when adding
+ specific features or changes.
+ Using isolated branches facilitates easy removal of
+ changes if they do not work out.
+ </para></listitem>
+ <listitem><para><emphasis><filename>git branch</filename>:</emphasis>
+ Displays the existing local branches associated with your
+ local repository.
+ The branch that you have currently checked out is noted
+ with an asterisk character.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git branch -D</filename> <replaceable>branch-name</replaceable>:</emphasis>
+ Deletes an existing local branch.
+ You need to be in a local branch other than the one you
+ are deleting in order to delete
+ <replaceable>branch-name</replaceable>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git pull</filename>:</emphasis>
+ Retrieves information from an upstream Git repository
+ and places it in your local Git repository.
+ You use this command to make sure you are synchronized with
+ the repository from which you are basing changes
+ (.e.g. the "master" branch).
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git push</filename>:</emphasis>
+ Sends all your committed local changes to the upstream Git
+ repository that your local repository is tracking
+ (e.g. a contribution repository).
+ The maintainer of the project draws from these repositories
+ to merge changes (commits) into the appropriate branch
+ of project's upstream repository.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git merge</filename>:</emphasis>
+ Combines or adds changes from one
+ local branch of your repository with another branch.
+ When you create a local Git repository, the default branch
+ is named "master".
+ A typical workflow is to create a temporary branch that is
+ based off "master" that you would use for isolated work.
+ You would make your changes in that isolated branch,
+ stage and commit them locally, switch to the "master"
+ branch, and then use the <filename>git merge</filename>
+ command to apply the changes from your isolated branch
+ into the currently checked out branch (e.g. "master").
+ After the merge is complete and if you are done with
+ working in that isolated branch, you can safely delete
+ the isolated branch.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git cherry-pick</filename>:</emphasis>
+ Choose and apply specific commits from one branch
+ into another branch.
+ There are times when you might not be able to merge
+ all the changes in one branch with
+ another but need to pick out certain ones.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>gitk</filename>:</emphasis>
+ Provides a GUI view of the branches and changes in your
+ local Git repository.
+ This command is a good way to graphically see where things
+ have diverged in your local repository.
+ <note>
+ You need to install the <filename>gitk</filename>
+ package on your development system to use this
+ command.
+ </note>
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git log</filename>:</emphasis>
+ Reports a history of your commits to the repository.
+ This report lists all commits regardless of whether you
+ have pushed them upstream or not.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>git diff</filename>:</emphasis>
+ Displays line-by-line differences between a local
+ working file and the same file as understood by Git.
+ This command is useful to see what you have changed
+ in any given file.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+</section>
+
+<section id='yocto-project-repositories'>
+ <title>Yocto Project Source Repositories</title>
+
+ <para>
+ The Yocto Project team maintains complete source repositories for all
+ Yocto Project files at
+ <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi'></ulink>.
+ This web-based source code browser is organized into categories by
+ function such as IDE Plugins, Matchbox, Poky, Yocto Linux Kernel, and
+ so forth.
+ From the interface, you can click on any particular item in the "Name"
+ column and see the URL at the bottom of the page that you need to clone
+ a Git repository for that particular item.
+ Having a local Git repository of the
+ <link linkend='source-directory'>Source Directory</link>, which is
+ usually named "poky", allows
+ you to make changes, contribute to the history, and ultimately enhance
+ the Yocto Project's tools, Board Support Packages, and so forth.
+ </para>
+
+ <para>
+ For any supported release of Yocto Project, you can also go to the
+ <ulink url='&YOCTO_HOME_URL;'>Yocto Project Website</ulink> and
+ select the "Downloads" tab and get a released tarball of the
+ <filename>poky</filename> repository or any supported BSP tarballs.
+ Unpacking these tarballs gives you a snapshot of the released
+ files.
+ <note><title>Notes</title>
+ <itemizedlist>
+ <listitem><para>
+ The recommended method for setting up the Yocto Project
+ <link linkend='source-directory'>Source Directory</link>
+ and the files for supported BSPs
+ (e.g., <filename>meta-intel</filename>) is to use
+ <link linkend='git'>Git</link> to create a local copy of
+ the upstream repositories.
+ </para></listitem>
+ <listitem><para>
+ Be sure to always work in matching branches for both
+ the selected BSP repository and the
+ <link linkend='source-directory'>Source Directory</link>
+ (i.e. <filename>poky</filename>) repository.
+ For example, if you have checked out the "master" branch
+ of <filename>poky</filename> and you are going to use
+ <filename>meta-intel</filename>, be sure to checkout the
+ "master" branch of <filename>meta-intel</filename>.
+ </para></listitem>
+ </itemizedlist>
+ </note>
+ </para>
+
+ <para>
+ In summary, here is where you can get the project files needed for
+ development:
+ <itemizedlist>
+ <listitem><para id='source-repositories'>
+ <emphasis>
+ <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi'>Source Repositories:</ulink>
+ </emphasis>
+ This area contains IDE Plugins, Matchbox, Poky, Poky Support,
+ Tools, Yocto Linux Kernel, and Yocto Metadata Layers.
+ You can create local copies of Git repositories for each of
+ these areas.</para>
+
+ <para>
+ <imagedata fileref="figures/source-repos.png" align="center" width="6in" depth="4in" />
+ For steps on how to view and access these upstream Git
+ repositories, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#accessing-source-repositories'>Accessing Source Repositories</ulink>"
+ Section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ <listitem><para><anchor id='index-downloads' />
+ <emphasis>
+ <ulink url='&YOCTO_DL_URL;/releases/'>Index of /releases:</ulink>
+ </emphasis>
+ This is an index of releases such as
+ the <trademark class='trade'>Eclipse</trademark>
+ Yocto Plug-in, miscellaneous support, Poky, Pseudo, installers
+ for cross-development toolchains, and all released versions of
+ Yocto Project in the form of images or tarballs.
+ Downloading and extracting these files does not produce a local
+ copy of the Git repository but rather a snapshot of a
+ particular release or image.</para>
+
+ <para>
+ <imagedata fileref="figures/index-downloads.png" align="center" width="6in" depth="3.5in" />
+ For steps on how to view and access these files, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#accessing-index-of-releases'>Accessing Index of Releases</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ <listitem><para id='downloads-page'>
+ <emphasis>"Downloads" page for the
+ <ulink url='&YOCTO_HOME_URL;'>Yocto Project Website</ulink>:
+ </emphasis></para>
+
+ <para role="writernotes">This section will change due to
+ reworking of the YP Website.</para>
+
+ <para>The Yocto Project website includes a "Downloads" tab
+ that allows you to download any Yocto Project
+ release and Board Support Package (BSP) in tarball form.
+ The tarballs are similar to those found in the
+ <ulink url='&YOCTO_DL_URL;/releases/'>Index of /releases:</ulink> area.</para>
+
+ <para>
+ <imagedata fileref="figures/yp-download.png" align="center" width="6in" depth="4in" />
+ For steps on how to use the "Downloads" page, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#using-the-downloads-page'>Using the Downloads Page</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+</section>
+
+<section id='licensing'>
+ <title>Licensing</title>
+
+ <para>
+ Because open source projects are open to the public, they have
+ different licensing structures in place.
+ License evolution for both Open Source and Free Software has an
+ interesting history.
+ If you are interested in this history, you can find basic information
+ here:
+ <itemizedlist>
+ <listitem><para>
+ <ulink url='http://en.wikipedia.org/wiki/Open-source_license'>Open source license history</ulink>
+ </para></listitem>
+ <listitem><para>
+ <ulink url='http://en.wikipedia.org/wiki/Free_software_license'>Free software license history</ulink>
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ In general, the Yocto Project is broadly licensed under the
+ Massachusetts Institute of Technology (MIT) License.
+ MIT licensing permits the reuse of software within proprietary
+ software as long as the license is distributed with that software.
+ MIT is also compatible with the GNU General Public License (GPL).
+ Patches to the Yocto Project follow the upstream licensing scheme.
+ You can find information on the MIT license
+ <ulink url='http://www.opensource.org/licenses/mit-license.php'>here</ulink>.
+ You can find information on the GNU GPL
+ <ulink url='http://www.opensource.org/licenses/LGPL-3.0'>here</ulink>.
+ </para>
+
+ <para>
+ When you build an image using the Yocto Project, the build process
+ uses a known list of licenses to ensure compliance.
+ You can find this list in the
+ <link linkend='source-directory'>Source Directory</link> at
+ <filename>meta/files/common-licenses</filename>.
+ Once the build completes, the list of all licenses found and used
+ during that build are kept in the
+ <link linkend='build-directory'>Build Directory</link>
+ at <filename>tmp/deploy/licenses</filename>.
+ </para>
+
+ <para>
+ If a module requires a license that is not in the base list, the
+ build process generates a warning during the build.
+ These tools make it easier for a developer to be certain of the
+ licenses with which their shipped products must comply.
+ However, even with these tools it is still up to the developer to
+ resolve potential licensing issues.
+ </para>
+
+ <para>
+ The base list of licenses used by the build process is a combination
+ of the Software Package Data Exchange (SPDX) list and the Open
+ Source Initiative (OSI) projects.
+ <ulink url='http://spdx.org'>SPDX Group</ulink> is a working group of
+ the Linux Foundation that maintains a specification for a standard
+ format for communicating the components, licenses, and copyrights
+ associated with a software package.
+ <ulink url='http://opensource.org'>OSI</ulink> is a corporation
+ dedicated to the Open Source Definition and the effort for reviewing
+ and approving licenses that conform to the Open Source Definition
+ (OSD).
+ </para>
+
+ <para>
+ You can find a list of the combined SPDX and OSI licenses that the
+ Yocto Project uses in the
+ <filename>meta/files/common-licenses</filename> directory in your
+ <link linkend='source-directory'>Source Directory</link>.
+ </para>
+
+ <para>
+ For information that can help you maintain compliance with various
+ open source licensing during the lifecycle of a product created using
+ the Yocto Project, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+</section>
+
+<section id='recipe-syntax'>
+ <title>Recipe Syntax</title>
+
+ <para>
+ Understanding recipe file syntax is important for
+ writing recipes.
+ The following list overviews the basic items that make up a
+ BitBake recipe file.
+ For more complete BitBake syntax descriptions, see the
+ "<ulink url='&YOCTO_DOCS_BB_URL;#bitbake-user-manual-metadata'>Syntax and Operators</ulink>"
+ chapter of the BitBake User Manual.
+ <itemizedlist>
+ <listitem><para><emphasis>Variable Assignments and Manipulations:</emphasis>
+ Variable assignments allow a value to be assigned to a
+ variable.
+ The assignment can be static text or might include
+ the contents of other variables.
+ In addition to the assignment, appending and prepending
+ operations are also supported.</para>
+ <para>The following example shows some of the ways
+ you can use variables in recipes:
+ <literallayout class='monospaced'>
+ S = "${WORKDIR}/postfix-${PV}"
+ CFLAGS += "-DNO_ASM"
+ SRC_URI_append = " file://fixup.patch"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Functions:</emphasis>
+ Functions provide a series of actions to be performed.
+ You usually use functions to override the default
+ implementation of a task function or to complement
+ a default function (i.e. append or prepend to an
+ existing function).
+ Standard functions use <filename>sh</filename> shell
+ syntax, although access to OpenEmbedded variables and
+ internal methods are also available.</para>
+ <para>The following is an example function from the
+ <filename>sed</filename> recipe:
+ <literallayout class='monospaced'>
+ do_install () {
+ autotools_do_install
+ install -d ${D}${base_bindir}
+ mv ${D}${bindir}/sed ${D}${base_bindir}/sed
+ rmdir ${D}${bindir}/
+ }
+ </literallayout>
+ It is also possible to implement new functions that
+ are called between existing tasks as long as the
+ new functions are not replacing or complementing the
+ default functions.
+ You can implement functions in Python
+ instead of shell.
+ Both of these options are not seen in the majority of
+ recipes.</para></listitem>
+ <listitem><para><emphasis>Keywords:</emphasis>
+ BitBake recipes use only a few keywords.
+ You use keywords to include common
+ functions (<filename>inherit</filename>), load parts
+ of a recipe from other files
+ (<filename>include</filename> and
+ <filename>require</filename>) and export variables
+ to the environment (<filename>export</filename>).</para>
+ <para>The following example shows the use of some of
+ these keywords:
+ <literallayout class='monospaced'>
+ export POSTCONF = "${STAGING_BINDIR}/postconf"
+ inherit autoconf
+ require otherfile.inc
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Comments:</emphasis>
+ Any lines that begin with the hash character
+ (<filename>#</filename>) are treated as comment lines
+ and are ignored:
+ <literallayout class='monospaced'>
+ # This is a comment
+ </literallayout>
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ This next list summarizes the most important and most commonly
+ used parts of the recipe syntax.
+ For more information on these parts of the syntax, you can
+ reference the
+ <ulink url='&YOCTO_DOCS_BB_URL;#bitbake-user-manual-metadata'>Syntax and Operators</ulink>
+ chapter in the BitBake User Manual.
+ <itemizedlist>
+ <listitem><para><emphasis>Line Continuation: <filename>\</filename></emphasis> -
+ Use the backward slash (<filename>\</filename>)
+ character to split a statement over multiple lines.
+ Place the slash character at the end of the line that
+ is to be continued on the next line:
+ <literallayout class='monospaced'>
+ VAR = "A really long \
+ line"
+ </literallayout>
+ <note>
+ You cannot have any characters including spaces
+ or tabs after the slash character.
+ </note>
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Using Variables: <filename>${...}</filename></emphasis> -
+ Use the <filename>${<replaceable>VARNAME</replaceable>}</filename> syntax to
+ access the contents of a variable:
+ <literallayout class='monospaced'>
+ SRC_URI = "${SOURCEFORGE_MIRROR}/libpng/zlib-${PV}.tar.gz"
+ </literallayout>
+ <note>
+ It is important to understand that the value of a
+ variable expressed in this form does not get
+ substituted automatically.
+ The expansion of these expressions happens
+ on-demand later (e.g. usually when a function that
+ makes reference to the variable executes).
+ This behavior ensures that the values are most
+ appropriate for the context in which they are
+ finally used.
+ On the rare occasion that you do need the variable
+ expression to be expanded immediately, you can use
+ the <filename>:=</filename> operator instead of
+ <filename>=</filename> when you make the
+ assignment, but this is not generally needed.
+ </note>
+ </para></listitem>
+ <listitem><para><emphasis>Quote All Assignments: <filename>"<replaceable>value</replaceable>"</filename></emphasis> -
+ Use double quotes around the value in all variable
+ assignments.
+ <literallayout class='monospaced'>
+ VAR1 = "${OTHERVAR}"
+ VAR2 = "The version is ${PV}"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Conditional Assignment: <filename>?=</filename></emphasis> -
+ Conditional assignment is used to assign a value to
+ a variable, but only when the variable is currently
+ unset.
+ Use the question mark followed by the equal sign
+ (<filename>?=</filename>) to make a "soft" assignment
+ used for conditional assignment.
+ Typically, "soft" assignments are used in the
+ <filename>local.conf</filename> file for variables
+ that are allowed to come through from the external
+ environment.
+ </para>
+ <para>Here is an example where
+ <filename>VAR1</filename> is set to "New value" if
+ it is currently empty.
+ However, if <filename>VAR1</filename> has already been
+ set, it remains unchanged:
+ <literallayout class='monospaced'>
+ VAR1 ?= "New value"
+ </literallayout>
+ In this next example, <filename>VAR1</filename>
+ is left with the value "Original value":
+ <literallayout class='monospaced'>
+ VAR1 = "Original value"
+ VAR1 ?= "New value"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Appending: <filename>+=</filename></emphasis> -
+ Use the plus character followed by the equals sign
+ (<filename>+=</filename>) to append values to existing
+ variables.
+ <note>
+ This operator adds a space between the existing
+ content of the variable and the new content.
+ </note></para>
+ <para>Here is an example:
+ <literallayout class='monospaced'>
+ SRC_URI += "file://fix-makefile.patch"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Prepending: <filename>=+</filename></emphasis> -
+ Use the equals sign followed by the plus character
+ (<filename>=+</filename>) to prepend values to existing
+ variables.
+ <note>
+ This operator adds a space between the new content
+ and the existing content of the variable.
+ </note></para>
+ <para>Here is an example:
+ <literallayout class='monospaced'>
+ VAR =+ "Starts"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Appending: <filename>_append</filename></emphasis> -
+ Use the <filename>_append</filename> operator to
+ append values to existing variables.
+ This operator does not add any additional space.
+ Also, the operator is applied after all the
+ <filename>+=</filename>, and
+ <filename>=+</filename> operators have been applied and
+ after all <filename>=</filename> assignments have
+ occurred.
+ </para>
+ <para>The following example shows the space being
+ explicitly added to the start to ensure the appended
+ value is not merged with the existing value:
+ <literallayout class='monospaced'>
+ SRC_URI_append = " file://fix-makefile.patch"
+ </literallayout>
+ You can also use the <filename>_append</filename>
+ operator with overrides, which results in the actions
+ only being performed for the specified target or
+ machine:
+ <literallayout class='monospaced'>
+ SRC_URI_append_sh4 = " file://fix-makefile.patch"
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Prepending: <filename>_prepend</filename></emphasis> -
+ Use the <filename>_prepend</filename> operator to
+ prepend values to existing variables.
+ This operator does not add any additional space.
+ Also, the operator is applied after all the
+ <filename>+=</filename>, and
+ <filename>=+</filename> operators have been applied and
+ after all <filename>=</filename> assignments have
+ occurred.
+ </para>
+ <para>The following example shows the space being
+ explicitly added to the end to ensure the prepended
+ value is not merged with the existing value:
+ <literallayout class='monospaced'>
+ CFLAGS_prepend = "-I${S}/myincludes "
+ </literallayout>
+ You can also use the <filename>_prepend</filename>
+ operator with overrides, which results in the actions
+ only being performed for the specified target or
+ machine:
+ <literallayout class='monospaced'>
+ CFLAGS_prepend_sh4 = "-I${S}/myincludes "
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Overrides:</emphasis> -
+ You can use overrides to set a value conditionally,
+ typically based on how the recipe is being built.
+ For example, to set the
+ <link linkend='var-KBRANCH'><filename>KBRANCH</filename></link>
+ variable's value to "standard/base" for any target
+ <link linkend='var-MACHINE'><filename>MACHINE</filename></link>,
+ except for qemuarm where it should be set to
+ "standard/arm-versatile-926ejs", you would do the
+ following:
+ <literallayout class='monospaced'>
+ KBRANCH = "standard/base"
+ KBRANCH_qemuarm = "standard/arm-versatile-926ejs"
+ </literallayout>
+ Overrides are also used to separate alternate values
+ of a variable in other situations.
+ For example, when setting variables such as
+ <link linkend='var-FILES'><filename>FILES</filename></link>
+ and
+ <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>
+ that are specific to individual packages produced by
+ a recipe, you should always use an override that
+ specifies the name of the package.
+ </para></listitem>
+ <listitem><para><emphasis>Indentation:</emphasis>
+ Use spaces for indentation rather than than tabs.
+ For shell functions, both currently work.
+ However, it is a policy decision of the Yocto Project
+ to use tabs in shell functions.
+ Realize that some layers have a policy to use spaces
+ for all indentation.
+ </para></listitem>
+ <listitem><para><emphasis>Using Python for Complex Operations: <filename>${@<replaceable>python_code</replaceable>}</filename></emphasis> -
+ For more advanced processing, it is possible to use
+ Python code during variable assignments (e.g.
+ search and replacement on a variable).</para>
+ <para>You indicate Python code using the
+ <filename>${@<replaceable>python_code</replaceable>}</filename>
+ syntax for the variable assignment:
+ <literallayout class='monospaced'>
+ SRC_URI = "ftp://ftp.info-zip.org/pub/infozip/src/zip${@d.getVar('PV',1).replace('.', '')}.tgz
+ </literallayout>
+ </para></listitem>
+ <listitem><para><emphasis>Shell Function Syntax:</emphasis>
+ Write shell functions as if you were writing a shell
+ script when you describe a list of actions to take.
+ You should ensure that your script works with a generic
+ <filename>sh</filename> and that it does not require
+ any <filename>bash</filename> or other shell-specific
+ functionality.
+ The same considerations apply to various system
+ utilities (e.g. <filename>sed</filename>,
+ <filename>grep</filename>, <filename>awk</filename>,
+ and so forth) that you might wish to use.
+ If in doubt, you should check with multiple
+ implementations - including those from BusyBox.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+</section>
+
+<section id="development-concepts">
+ <title>Development Concepts</title>
+
+ <para>
+ This section takes a more detailed look inside the development
+ process.
+ The following diagram represents development at a high level.
+ The remainder of this chapter expands on the fundamental input, output,
+ process, and
+ <link linkend='metadata'>Metadata</link>) blocks
+ that make up development in the Yocto Project environment.
+ </para>
+
+ <para id='general-yocto-environment-figure'>
+ <imagedata fileref="figures/yocto-environment-ref.png" align="center" width="8in" depth="4.25in" />
+ </para>
+
+ <para>
+ In general, development consists of several functional areas:
+ <itemizedlist>
+ <listitem><para><emphasis>User Configuration:</emphasis>
+ Metadata you can use to control the build process.
+ </para></listitem>
+ <listitem><para><emphasis>Metadata Layers:</emphasis>
+ Various layers that provide software, machine, and
+ distro Metadata.</para></listitem>
+ <listitem><para><emphasis>Source Files:</emphasis>
+ Upstream releases, local projects, and SCMs.</para></listitem>
+ <listitem><para><emphasis>Build System:</emphasis>
+ Processes under the control of
+ <link linkend='bitbake-term'>BitBake</link>.
+ This block expands on how BitBake fetches source, applies
+ patches, completes compilation, analyzes output for package
+ generation, creates and tests packages, generates images, and
+ generates cross-development tools.</para></listitem>
+ <listitem><para><emphasis>Package Feeds:</emphasis>
+ Directories containing output packages (RPM, DEB or IPK),
+ which are subsequently used in the construction of an image or
+ SDK, produced by the build system.
+ These feeds can also be copied and shared using a web server or
+ other means to facilitate extending or updating existing
+ images on devices at runtime if runtime package management is
+ enabled.</para></listitem>
+ <listitem><para><emphasis>Images:</emphasis>
+ Images produced by the development process.
+ </para></listitem>
+ <listitem><para><emphasis>Application Development SDK:</emphasis>
+ Cross-development tools that are produced along with an image
+ or separately with BitBake.</para></listitem>
+ </itemizedlist>
+ </para>
+
+ <section id="user-configuration">
+ <title>User Configuration</title>
+
+ <para>
+ User configuration helps define the build.
+ Through user configuration, you can tell BitBake the
+ target architecture for which you are building the image,
+ where to store downloaded source, and other build properties.
+ </para>
+
+ <para>
+ The following figure shows an expanded representation of the
+ "User Configuration" box of the
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>:
+ </para>
+
+ <para>
+ <imagedata fileref="figures/user-configuration.png" align="center" />
+ </para>
+
+ <para>
+ BitBake needs some basic configuration files in order to complete
+ a build.
+ These files are <filename>*.conf</filename> files.
+ The minimally necessary ones reside as example files in the
+ <link linkend='source-directory'>Source Directory</link>.
+ For simplicity, this section refers to the Source Directory as
+ the "Poky Directory."
+ </para>
+
+ <para>
+ When you clone the <filename>poky</filename> Git repository or you
+ download and unpack a Yocto Project release, you can set up the
+ Source Directory to be named anything you want.
+ For this discussion, the cloned repository uses the default
+ name <filename>poky</filename>.
+ <note>
+ The Poky repository is primarily an aggregation of existing
+ repositories.
+ It is not a canonical upstream source.
+ </note>
+ </para>
+
+ <para>
+ The <filename>meta-poky</filename> layer inside Poky contains
+ a <filename>conf</filename> directory that has example
+ configuration files.
+ These example files are used as a basis for creating actual
+ configuration files when you source the build environment
+ script
+ (i.e.
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
+ </para>
+
+ <para>
+ Sourcing the build environment script creates a
+ <link linkend='build-directory'>Build Directory</link>
+ if one does not already exist.
+ BitBake uses the Build Directory for all its work during builds.
+ The Build Directory has a <filename>conf</filename> directory that
+ contains default versions of your <filename>local.conf</filename>
+ and <filename>bblayers.conf</filename> configuration files.
+ These default configuration files are created only if versions
+ do not already exist in the Build Directory at the time you
+ source the build environment setup script.
+ </para>
+
+ <para>
+ Because the Poky repository is fundamentally an aggregation of
+ existing repositories, some users might be familiar with running
+ the <filename>&OE_INIT_FILE;</filename> script in the context
+ of separate OpenEmbedded-Core and BitBake repositories rather than a
+ single Poky repository.
+ This discussion assumes the script is executed from within a cloned
+ or unpacked version of Poky.
+ </para>
+
+ <para>
+ Depending on where the script is sourced, different sub-scripts
+ are called to set up the Build Directory (Yocto or OpenEmbedded).
+ Specifically, the script
+ <filename>scripts/oe-setup-builddir</filename> inside the
+ poky directory sets up the Build Directory and seeds the directory
+ (if necessary) with configuration files appropriate for the
+ Yocto Project development environment.
+ <note>
+ The <filename>scripts/oe-setup-builddir</filename> script
+ uses the <filename>$TEMPLATECONF</filename> variable to
+ determine which sample configuration files to locate.
+ </note>
+ </para>
+
+ <para>
+ The <filename>local.conf</filename> file provides many
+ basic variables that define a build environment.
+ Here is a list of a few.
+ To see the default configurations in a <filename>local.conf</filename>
+ file created by the build environment script, see the
+ <filename>local.conf.sample</filename> in the
+ <filename>meta-poky</filename> layer:
+ <itemizedlist>
+ <listitem><para><emphasis>Parallelism Options:</emphasis>
+ Controlled by the
+ <link linkend='var-BB_NUMBER_THREADS'><filename>BB_NUMBER_THREADS</filename></link>,
+ <link linkend='var-PARALLEL_MAKE'><filename>PARALLEL_MAKE</filename></link>,
+ and
+ <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_NUMBER_PARSE_THREADS'><filename>BB_NUMBER_PARSE_THREADS</filename></ulink>
+ variables.</para></listitem>
+ <listitem><para><emphasis>Target Machine Selection:</emphasis>
+ Controlled by the
+ <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
+ variable.</para></listitem>
+ <listitem><para><emphasis>Download Directory:</emphasis>
+ Controlled by the
+ <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
+ variable.</para></listitem>
+ <listitem><para><emphasis>Shared State Directory:</emphasis>
+ Controlled by the
+ <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>
+ variable.</para></listitem>
+ <listitem><para><emphasis>Build Output:</emphasis>
+ Controlled by the
+ <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
+ variable.</para></listitem>
+ </itemizedlist>
+ <note>
+ Configurations set in the <filename>conf/local.conf</filename>
+ file can also be set in the
+ <filename>conf/site.conf</filename> and
+ <filename>conf/auto.conf</filename> configuration files.
+ </note>
+ </para>
+
+ <para>
+ The <filename>bblayers.conf</filename> file tells BitBake what
+ layers you want considered during the build.
+ By default, the layers listed in this file include layers
+ minimally needed by the build system.
+ However, you must manually add any custom layers you have created.
+ You can find more information on working with the
+ <filename>bblayers.conf</filename> file in the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#enabling-your-layer'>Enabling Your Layer</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+
+ <para>
+ The files <filename>site.conf</filename> and
+ <filename>auto.conf</filename> are not created by the environment
+ initialization script.
+ If you want the <filename>site.conf</filename> file, you need to
+ create that yourself.
+ The <filename>auto.conf</filename> file is typically created by
+ an autobuilder:
+ <itemizedlist>
+ <listitem><para><emphasis><filename>site.conf</filename>:</emphasis>
+ You can use the <filename>conf/site.conf</filename>
+ configuration file to configure multiple build directories.
+ For example, suppose you had several build environments and
+ they shared some common features.
+ You can set these default build properties here.
+ A good example is perhaps the packaging format to use
+ through the
+ <link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>
+ variable.</para>
+ <para>One useful scenario for using the
+ <filename>conf/site.conf</filename> file is to extend your
+ <link linkend='var-BBPATH'><filename>BBPATH</filename></link>
+ variable to include the path to a
+ <filename>conf/site.conf</filename>.
+ Then, when BitBake looks for Metadata using
+ <filename>BBPATH</filename>, it finds the
+ <filename>conf/site.conf</filename> file and applies your
+ common configurations found in the file.
+ To override configurations in a particular build directory,
+ alter the similar configurations within that build
+ directory's <filename>conf/local.conf</filename> file.
+ </para></listitem>
+ <listitem><para><emphasis><filename>auto.conf</filename>:</emphasis>
+ The file is usually created and written to by
+ an autobuilder.
+ The settings put into the file are typically the same as
+ you would find in the <filename>conf/local.conf</filename>
+ or the <filename>conf/site.conf</filename> files.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ You can edit all configuration files to further define
+ any particular build environment.
+ This process is represented by the "User Configuration Edits"
+ box in the figure.
+ </para>
+
+ <para>
+ When you launch your build with the
+ <filename>bitbake <replaceable>target</replaceable></filename>
+ command, BitBake sorts out the configurations to ultimately
+ define your build environment.
+ It is important to understand that the OpenEmbedded build system
+ reads the configuration files in a specific order:
+ <filename>site.conf</filename>, <filename>auto.conf</filename>,
+ and <filename>local.conf</filename>.
+ And, the build system applies the normal assignment statement
+ rules.
+ Because the files are parsed in a specific order, variable
+ assignments for the same variable could be affected.
+ For example, if the <filename>auto.conf</filename> file and
+ the <filename>local.conf</filename> set
+ <replaceable>variable1</replaceable> to different values, because
+ the build system parses <filename>local.conf</filename> after
+ <filename>auto.conf</filename>,
+ <replaceable>variable1</replaceable> is assigned the value from
+ the <filename>local.conf</filename> file.
+ </para>
+ </section>
+
+ <section id="metadata-machine-configuration-and-policy-configuration">
+ <title>Metadata, Machine Configuration, and Policy Configuration</title>
+
+ <para>
+ The previous section described the user configurations that
+ define BitBake's global behavior.
+ This section takes a closer look at the layers the build system
+ uses to further control the build.
+ These layers provide Metadata for the software, machine, and
+ policy.
+ </para>
+
+ <para>
+ In general, three types of layer input exist:
+ <itemizedlist>
+ <listitem><para><emphasis>Policy Configuration:</emphasis>
+ Distribution Layers provide top-level or general
+ policies for the image or SDK being built.
+ For example, this layer would dictate whether BitBake
+ produces RPM or IPK packages.</para></listitem>
+ <listitem><para><emphasis>Machine Configuration:</emphasis>
+ Board Support Package (BSP) layers provide machine
+ configurations.
+ This type of information is specific to a particular
+ target architecture.</para></listitem>
+ <listitem><para><emphasis>Metadata:</emphasis>
+ Software layers contain user-supplied recipe files,
+ patches, and append files.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ The following figure shows an expanded representation of the
+ Metadata, Machine Configuration, and Policy Configuration input
+ (layers) boxes of the
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>:
+ </para>
+
+ <para>
+ <imagedata fileref="figures/layer-input.png" align="center" width="8in" depth="7.5in" />
+ </para>
+
+ <para>
+ In general, all layers have a similar structure.
+ They all contain a licensing file
+ (e.g. <filename>COPYING</filename>) if the layer is to be
+ distributed, a <filename>README</filename> file as good practice
+ and especially if the layer is to be distributed, a
+ configuration directory, and recipe directories.
+ </para>
+
+ <para>
+ The Yocto Project has many layers that can be used.
+ You can see a web-interface listing of them on the
+ <ulink url="http://git.yoctoproject.org/">Source Repositories</ulink>
+ page.
+ The layers are shown at the bottom categorized under
+ "Yocto Metadata Layers."
+ These layers are fundamentally a subset of the
+ <ulink url="http://layers.openembedded.org/layerindex/layers/">OpenEmbedded Metadata Index</ulink>,
+ which lists all layers provided by the OpenEmbedded community.
+ <note>
+ Layers exist in the Yocto Project Source Repositories that
+ cannot be found in the OpenEmbedded Metadata Index.
+ These layers are either deprecated or experimental in nature.
+ </note>
+ </para>
+
+ <para>
+ BitBake uses the <filename>conf/bblayers.conf</filename> file,
+ which is part of the user configuration, to find what layers it
+ should be using as part of the build.
+ </para>
+
+ <para>
+ For more information on layers, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and Creating Layers</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para>
+
+ <section id="distro-layer">
+ <title>Distro Layer</title>
+
+ <para>
+ The distribution layer provides policy configurations for your
+ distribution.
+ Best practices dictate that you isolate these types of
+ configurations into their own layer.
+ Settings you provide in
+ <filename>conf/distro/<replaceable>distro</replaceable>.conf</filename> override
+ similar
+ settings that BitBake finds in your
+ <filename>conf/local.conf</filename> file in the Build
+ Directory.
+ </para>
+
+ <para>
+ The following list provides some explanation and references
+ for what you typically find in the distribution layer:
+ <itemizedlist>
+ <listitem><para><emphasis>classes:</emphasis>
+ Class files (<filename>.bbclass</filename>) hold
+ common functionality that can be shared among
+ recipes in the distribution.
+ When your recipes inherit a class, they take on the
+ settings and functions for that class.
+ You can read more about class files in the
+ "<link linkend='ref-classes'>Classes</link>" section.
+ </para></listitem>
+ <listitem><para><emphasis>conf:</emphasis>
+ This area holds configuration files for the
+ layer (<filename>conf/layer.conf</filename>),
+ the distribution
+ (<filename>conf/distro/<replaceable>distro</replaceable>.conf</filename>),
+ and any distribution-wide include files.
+ </para></listitem>
+ <listitem><para><emphasis>recipes-*:</emphasis>
+ Recipes and append files that affect common
+ functionality across the distribution.
+ This area could include recipes and append files
+ to add distribution-specific configuration,
+ initialization scripts, custom image recipes,
+ and so forth.</para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id="bsp-layer">
+ <title>BSP Layer</title>
+
+ <para>
+ The BSP Layer provides machine configurations.
+ Everything in this layer is specific to the machine for which
+ you are building the image or the SDK.
+ A common structure or form is defined for BSP layers.
+ You can learn more about this structure in the
+ <ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>.
+ <note>
+ In order for a BSP layer to be considered compliant with the
+ Yocto Project, it must meet some structural requirements.
+ </note>
+ </para>
+
+ <para>
+ The BSP Layer's configuration directory contains
+ configuration files for the machine
+ (<filename>conf/machine/<replaceable>machine</replaceable>.conf</filename>) and,
+ of course, the layer (<filename>conf/layer.conf</filename>).
+ </para>
+
+ <para>
+ The remainder of the layer is dedicated to specific recipes
+ by function: <filename>recipes-bsp</filename>,
+ <filename>recipes-core</filename>,
+ <filename>recipes-graphics</filename>, and
+ <filename>recipes-kernel</filename>.
+ Metadata can exist for multiple formfactors, graphics
+ support systems, and so forth.
+ <note>
+ While the figure shows several <filename>recipes-*</filename>
+ directories, not all these directories appear in all
+ BSP layers.
+ </note>
+ </para>
+ </section>
+
+ <section id="software-layer">
+ <title>Software Layer</title>
+
+ <para>
+ The software layer provides the Metadata for additional
+ software packages used during the build.
+ This layer does not include Metadata that is specific to the
+ distribution or the machine, which are found in their
+ respective layers.
+ </para>
+
+ <para>
+ This layer contains any new recipes that your project needs
+ in the form of recipe files.
+ </para>
+ </section>
+ </section>
+
+ <section id="sources-dev-environment">
+ <title>Sources</title>
+
+ <para>
+ In order for the OpenEmbedded build system to create an image or
+ any target, it must be able to access source files.
+ The
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
+ represents source files using the "Upstream Project Releases",
+ "Local Projects", and "SCMs (optional)" boxes.
+ The figure represents mirrors, which also play a role in locating
+ source files, with the "Source Mirror(s)" box.
+ </para>
+
+ <para>
+ The method by which source files are ultimately organized is
+ a function of the project.
+ For example, for released software, projects tend to use tarballs
+ or other archived files that can capture the state of a release
+ guaranteeing that it is statically represented.
+ On the other hand, for a project that is more dynamic or
+ experimental in nature, a project might keep source files in a
+ repository controlled by a Source Control Manager (SCM) such as
+ Git.
+ Pulling source from a repository allows you to control
+ the point in the repository (the revision) from which you want to
+ build software.
+ Finally, a combination of the two might exist, which would give the
+ consumer a choice when deciding where to get source files.
+ </para>
+
+ <para>
+ BitBake uses the
+ <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
+ variable to point to source files regardless of their location.
+ Each recipe must have a <filename>SRC_URI</filename> variable
+ that points to the source.
+ </para>
+
+ <para>
+ Another area that plays a significant role in where source files
+ come from is pointed to by the
+ <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
+ variable.
+ This area is a cache that can hold previously downloaded source.
+ You can also instruct the OpenEmbedded build system to create
+ tarballs from Git repositories, which is not the default behavior,
+ and store them in the <filename>DL_DIR</filename> by using the
+ <link linkend='var-BB_GENERATE_MIRROR_TARBALLS'><filename>BB_GENERATE_MIRROR_TARBALLS</filename></link>
+ variable.
+ </para>
+
+ <para>
+ Judicious use of a <filename>DL_DIR</filename> directory can
+ save the build system a trip across the Internet when looking
+ for files.
+ A good method for using a download directory is to have
+ <filename>DL_DIR</filename> point to an area outside of your
+ Build Directory.
+ Doing so allows you to safely delete the Build Directory
+ if needed without fear of removing any downloaded source file.
+ </para>
+
+ <para>
+ The remainder of this section provides a deeper look into the
+ source files and the mirrors.
+ Here is a more detailed look at the source file area of the
+ base figure:
+ <imagedata fileref="figures/source-input.png" align="center" width="7in" depth="7.5in" />
+ </para>
+
+ <section id='upstream-project-releases'>
+ <title>Upstream Project Releases</title>
+
+ <para>
+ Upstream project releases exist anywhere in the form of an
+ archived file (e.g. tarball or zip file).
+ These files correspond to individual recipes.
+ For example, the figure uses specific releases each for
+ BusyBox, Qt, and Dbus.
+ An archive file can be for any released product that can be
+ built using a recipe.
+ </para>
+ </section>
+
+ <section id='local-projects'>
+ <title>Local Projects</title>
+
+ <para>
+ Local projects are custom bits of software the user provides.
+ These bits reside somewhere local to a project - perhaps
+ a directory into which the user checks in items (e.g.
+ a local directory containing a development source tree
+ used by the group).
+ </para>
+
+ <para>
+ The canonical method through which to include a local project
+ is to use the
+ <link linkend='ref-classes-externalsrc'><filename>externalsrc</filename></link>
+ class to include that local project.
+ You use either the <filename>local.conf</filename> or a
+ recipe's append file to override or set the
+ recipe to point to the local directory on your disk to pull
+ in the whole source tree.
+ </para>
+
+ <para>
+ For information on how to use the
+ <filename>externalsrc</filename> class, see the
+ "<link linkend='ref-classes-externalsrc'><filename>externalsrc.bbclass</filename></link>"
+ section.
+ </para>
+ </section>
+
+ <section id='scms'>
+ <title>Source Control Managers (Optional)</title>
+
+ <para>
+ Another place the build system can get source files from is
+ through an SCM such as Git or Subversion.
+ In this case, a repository is cloned or checked out.
+ The
+ <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
+ task inside BitBake uses
+ the <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
+ variable and the argument's prefix to determine the correct
+ fetcher module.
+ </para>
+
+ <note>
+ For information on how to have the OpenEmbedded build system
+ generate tarballs for Git repositories and place them in the
+ <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
+ directory, see the
+ <link linkend='var-BB_GENERATE_MIRROR_TARBALLS'><filename>BB_GENERATE_MIRROR_TARBALLS</filename></link>
+ variable.
+ </note>
+
+ <para>
+ When fetching a repository, BitBake uses the
+ <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
+ variable to determine the specific revision from which to
+ build.
+ </para>
+ </section>
+
+ <section id='source-mirrors'>
+ <title>Source Mirror(s)</title>
+
+ <para>
+ Two kinds of mirrors exist: pre-mirrors and regular mirrors.
+ The <link linkend='var-PREMIRRORS'><filename>PREMIRRORS</filename></link>
+ and
+ <link linkend='var-MIRRORS'><filename>MIRRORS</filename></link>
+ variables point to these, respectively.
+ BitBake checks pre-mirrors before looking upstream for any
+ source files.
+ Pre-mirrors are appropriate when you have a shared directory
+ that is not a directory defined by the
+ <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>
+ variable.
+ A Pre-mirror typically points to a shared directory that is
+ local to your organization.
+ </para>
+
+ <para>
+ Regular mirrors can be any site across the Internet that is
+ used as an alternative location for source code should the
+ primary site not be functioning for some reason or another.
+ </para>
+ </section>
+ </section>
+
+ <section id="package-feeds-dev-environment">
+ <title>Package Feeds</title>
+
+ <para>
+ When the OpenEmbedded build system generates an image or an SDK,
+ it gets the packages from a package feed area located in the
+ <link linkend='build-directory'>Build Directory</link>.
+ The
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
+ shows this package feeds area in the upper-right corner.
+ </para>
+
+ <para>
+ This section looks a little closer into the package feeds area used
+ by the build system.
+ Here is a more detailed look at the area:
+ <imagedata fileref="figures/package-feeds.png" align="center" width="7in" depth="6in" />
+ </para>
+
+ <para>
+ Package feeds are an intermediary step in the build process.
+ The OpenEmbedded build system provides classes to generate
+ different package types, and you specify which classes to enable
+ through the
+ <link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>
+ variable.
+ Before placing the packages into package feeds,
+ the build process validates them with generated output quality
+ assurance checks through the
+ <link linkend='ref-classes-insane'><filename>insane</filename></link>
+ class.
+ </para>
+
+ <para>
+ The package feed area resides in the Build Directory.
+ The directory the build system uses to temporarily store packages
+ is determined by a combination of variables and the particular
+ package manager in use.
+ See the "Package Feeds" box in the illustration and note the
+ information to the right of that area.
+ In particular, the following defines where package files are
+ kept:
+ <itemizedlist>
+ <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
+ Defined as <filename>tmp/deploy</filename> in the Build
+ Directory.
+ </para></listitem>
+ <listitem><para><filename>DEPLOY_DIR_*</filename>:
+ Depending on the package manager used, the package type
+ sub-folder.
+ Given RPM, IPK, or DEB packaging and tarball creation, the
+ <link linkend='var-DEPLOY_DIR_RPM'><filename>DEPLOY_DIR_RPM</filename></link>,
+ <link linkend='var-DEPLOY_DIR_IPK'><filename>DEPLOY_DIR_IPK</filename></link>,
+ <link linkend='var-DEPLOY_DIR_DEB'><filename>DEPLOY_DIR_DEB</filename></link>,
+ or
+ <link linkend='var-DEPLOY_DIR_TAR'><filename>DEPLOY_DIR_TAR</filename></link>,
+ variables are used, respectively.
+ </para></listitem>
+ <listitem><para><link linkend='var-PACKAGE_ARCH'><filename>PACKAGE_ARCH</filename></link>:
+ Defines architecture-specific sub-folders.
+ For example, packages could exist for the i586 or qemux86
+ architectures.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ BitBake uses the <filename>do_package_write_*</filename> tasks to
+ generate packages and place them into the package holding area (e.g.
+ <filename>do_package_write_ipk</filename> for IPK packages).
+ See the
+ "<link linkend='ref-tasks-package_write_deb'><filename>do_package_write_deb</filename></link>",
+ "<link linkend='ref-tasks-package_write_ipk'><filename>do_package_write_ipk</filename></link>",
+ "<link linkend='ref-tasks-package_write_rpm'><filename>do_package_write_rpm</filename></link>",
+ and
+ "<link linkend='ref-tasks-package_write_tar'><filename>do_package_write_tar</filename></link>"
+ sections for additional information.
+ As an example, consider a scenario where an IPK packaging manager
+ is being used and package architecture support for both i586
+ and qemux86 exist.
+ Packages for the i586 architecture are placed in
+ <filename>build/tmp/deploy/ipk/i586</filename>, while packages for
+ the qemux86 architecture are placed in
+ <filename>build/tmp/deploy/ipk/qemux86</filename>.
+ </para>
+ </section>
+
+ <section id='bitbake-dev-environment'>
+ <title>BitBake</title>
+
+ <para>
+ The OpenEmbedded build system uses
+ <link linkend='bitbake-term'>BitBake</link>
+ to produce images.
+ You can see from the
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>,
+ the BitBake area consists of several functional areas.
+ This section takes a closer look at each of those areas.
+ </para>
+
+ <para>
+ Separate documentation exists for the BitBake tool.
+ See the
+ <ulink url='&YOCTO_DOCS_BB_URL;#bitbake-user-manual'>BitBake User Manual</ulink>
+ for reference material on BitBake.
+ </para>
+
+ <section id='source-fetching-dev-environment'>
+ <title>Source Fetching</title>
+
+ <para>
+ The first stages of building a recipe are to fetch and unpack
+ the source code:
+ <imagedata fileref="figures/source-fetching.png" align="center" width="6.5in" depth="5in" />
+ </para>
+
+ <para>
+ The
+ <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
+ and
+ <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
+ tasks fetch the source files and unpack them into the work
+ directory.
+ <note>
+ For every local file (e.g. <filename>file://</filename>)
+ that is part of a recipe's
+ <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
+ statement, the OpenEmbedded build system takes a checksum
+ of the file for the recipe and inserts the checksum into
+ the signature for the <filename>do_fetch</filename>.
+ If any local file has been modified, the
+ <filename>do_fetch</filename> task and all tasks that
+ depend on it are re-executed.
+ </note>
+ By default, everything is accomplished in the
+ <link linkend='build-directory'>Build Directory</link>,
+ which has a defined structure.
+ For additional general information on the Build Directory,
+ see the
+ "<link linkend='structure-core-build'><filename>build/</filename></link>"
+ section.
+ </para>
+
+ <para>
+ Unpacked source files are pointed to by the
+ <link linkend='var-S'><filename>S</filename></link> 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:
+ <itemizedlist>
+ <listitem><para><link linkend='var-TMPDIR'><filename>TMPDIR</filename></link> -
+ The base directory where the OpenEmbedded build system
+ performs all its work during the build.
+ </para></listitem>
+ <listitem><para><link linkend='var-PACKAGE_ARCH'><filename>PACKAGE_ARCH</filename></link> -
+ The architecture of the built package or packages.
+ </para></listitem>
+ <listitem><para><link linkend='var-TARGET_OS'><filename>TARGET_OS</filename></link> -
+ The operating system of the target device.
+ </para></listitem>
+ <listitem><para><link linkend='var-PN'><filename>PN</filename></link> -
+ The name of the built package.
+ </para></listitem>
+ <listitem><para><link linkend='var-PV'><filename>PV</filename></link> -
+ The version of the recipe used to build the package.
+ </para></listitem>
+ <listitem><para><link linkend='var-PR'><filename>PR</filename></link> -
+ The revision of the recipe used to build the package.
+ </para></listitem>
+ <listitem><para><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link> -
+ The location within <filename>TMPDIR</filename> where
+ a specific package is built.
+ </para></listitem>
+ <listitem><para><link linkend='var-S'><filename>S</filename></link> -
+ Contains the unpacked source files for a given recipe.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='patching-dev-environment'>
+ <title>Patching</title>
+
+ <para>
+ Once source code is fetched and unpacked, BitBake locates
+ patch files and applies them to the source files:
+ <imagedata fileref="figures/patching.png" align="center" width="6in" depth="5in" />
+ </para>
+
+ <para>
+ The
+ <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
+ task processes recipes by
+ using the
+ <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
+ variable to locate applicable patch files, which by default
+ are <filename>*.patch</filename> or
+ <filename>*.diff</filename> files, or any file if
+ "apply=yes" is specified for the file in
+ <filename>SRC_URI</filename>.
+ </para>
+
+ <para>
+ BitBake finds and applies multiple patches for a single recipe
+ in the order in which it finds the patches.
+ Patches are applied to the recipe's source files located in the
+ <link linkend='var-S'><filename>S</filename></link> directory.
+ </para>
+
+ <para>
+ For more information on how the source directories are
+ created, see the
+ "<link linkend='source-fetching-dev-environment'>Source Fetching</link>"
+ section.
+ </para>
+ </section>
+
+ <section id='configuration-and-compilation-dev-environment'>
+ <title>Configuration and Compilation</title>
+
+ <para>
+ After source code is patched, BitBake executes tasks that
+ configure and compile the source code:
+ <imagedata fileref="figures/configuration-compile-autoreconf.png" align="center" width="7in" depth="5in" />
+ </para>
+
+ <para>
+ This step in the build process consists of three tasks:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><link linkend='ref-tasks-prepare_recipe_sysroot'><filename>do_prepare_recipe_sysroot</filename></link>:</emphasis>
+ This task sets up the two sysroots in
+ <filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}</filename>
+ (i.e. <filename>recipe-sysroot</filename> and
+ <filename>recipe-sysroot-native</filename>) so that
+ the sysroots contain the contents of the
+ <link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>
+ tasks of the recipes on which the recipe
+ containing the tasks depends.
+ A sysroot exists for both the target and for the native
+ binaries, which run on the host system.
+ </para></listitem>
+ <listitem><para><emphasis><filename>do_configure</filename>:</emphasis>
+ This task configures the source by enabling and
+ disabling any build-time and configuration options for
+ the software being built.
+ Configurations can come from the recipe itself as well
+ as from an inherited class.
+ Additionally, the software itself might configure itself
+ depending on the target for which it is being built.
+ </para>
+
+ <para>The configurations handled by the
+ <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
+ task are specific
+ to source code configuration for the source code
+ being built by the recipe.</para>
+
+ <para>If you are using the
+ <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
+ class,
+ you can add additional configuration options by using
+ the <link linkend='var-EXTRA_OECONF'><filename>EXTRA_OECONF</filename></link>
+ or
+ <link linkend='var-PACKAGECONFIG_CONFARGS'><filename>PACKAGECONFIG_CONFARGS</filename></link>
+ variables.
+ For information on how this variable works within
+ that class, see the
+ <filename>meta/classes/autotools.bbclass</filename> file.
+ </para></listitem>
+ <listitem><para><emphasis><filename>do_compile</filename>:</emphasis>
+ Once a configuration task has been satisfied, BitBake
+ compiles the source using the
+ <link linkend='ref-tasks-compile'><filename>do_compile</filename></link>
+ task.
+ Compilation occurs in the directory pointed to by the
+ <link linkend='var-B'><filename>B</filename></link>
+ variable.
+ Realize that the <filename>B</filename> directory is, by
+ default, the same as the
+ <link linkend='var-S'><filename>S</filename></link>
+ directory.</para></listitem>
+ <listitem><para><emphasis><filename>do_install</filename>:</emphasis>
+ Once compilation is done, BitBake executes the
+ <link linkend='ref-tasks-install'><filename>do_install</filename></link>
+ task.
+ This task copies files from the <filename>B</filename>
+ directory and places them in a holding area pointed to
+ by the
+ <link linkend='var-D'><filename>D</filename></link>
+ variable.</para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='package-splitting-dev-environment'>
+ <title>Package Splitting</title>
+
+ <para>
+ After source code is configured and compiled, the
+ OpenEmbedded build system analyzes
+ the results and splits the output into packages:
+ <imagedata fileref="figures/analysis-for-package-splitting.png" align="center" width="7in" depth="7in" />
+ </para>
+
+ <para>
+ The
+ <link linkend='ref-tasks-package'><filename>do_package</filename></link>
+ and
+ <link linkend='ref-tasks-packagedata'><filename>do_packagedata</filename></link>
+ tasks combine to analyze
+ the files found in the
+ <link linkend='var-D'><filename>D</filename></link> directory
+ and split them into subsets based on available packages and
+ files.
+ The analyzing process involves the following as well as other
+ items: splitting out debugging symbols,
+ looking at shared library dependencies between packages,
+ and looking at package relationships.
+ The <filename>do_packagedata</filename> task creates package
+ metadata based on the analysis such that the
+ OpenEmbedded build system can generate the final packages.
+ Working, staged, and intermediate results of the analysis
+ and package splitting process use these areas:
+ <itemizedlist>
+ <listitem><para><link linkend='var-PKGD'><filename>PKGD</filename></link> -
+ The destination directory for packages before they are
+ split.
+ </para></listitem>
+ <listitem><para><link linkend='var-PKGDATA_DIR'><filename>PKGDATA_DIR</filename></link> -
+ A shared, global-state directory that holds data
+ generated during the packaging process.
+ </para></listitem>
+ <listitem><para><link linkend='var-PKGDESTWORK'><filename>PKGDESTWORK</filename></link> -
+ A temporary work area used by the
+ <filename>do_package</filename> task.
+ </para></listitem>
+ <listitem><para><link linkend='var-PKGDEST'><filename>PKGDEST</filename></link> -
+ The parent directory for packages after they have
+ been split.
+ </para></listitem>
+ </itemizedlist>
+ The <link linkend='var-FILES'><filename>FILES</filename></link>
+ variable defines the files that go into each package in
+ <link linkend='var-PACKAGES'><filename>PACKAGES</filename></link>.
+ If you want details on how this is accomplished, you can
+ look at the
+ <link linkend='ref-classes-package'><filename>package</filename></link>
+ class.
+ </para>
+
+ <para>
+ Depending on the type of packages being created (RPM, DEB, or
+ IPK), the <filename>do_package_write_*</filename> task
+ creates the actual packages and places them in the
+ Package Feed area, which is
+ <filename>${TMPDIR}/deploy</filename>.
+ You can see the
+ "<link linkend='package-feeds-dev-environment'>Package Feeds</link>"
+ section for more detail on that part of the build process.
+ <note>
+ Support for creating feeds directly from the
+ <filename>deploy/*</filename> directories does not exist.
+ Creating such feeds usually requires some kind of feed
+ maintenance mechanism that would upload the new packages
+ into an official package feed (e.g. the
+ Ångström distribution).
+ This functionality is highly distribution-specific
+ and thus is not provided out of the box.
+ </note>
+ </para>
+ </section>
+
+ <section id='image-generation-dev-environment'>
+ <title>Image Generation</title>
+
+ <para>
+ Once packages are split and stored in the Package Feeds area,
+ the OpenEmbedded build system uses BitBake to generate the
+ root filesystem image:
+ <imagedata fileref="figures/image-generation.png" align="center" width="6in" depth="7in" />
+ </para>
+
+ <para>
+ The image generation process consists of several stages and
+ depends on several tasks and variables.
+ The
+ <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
+ task creates the root filesystem (file and directory structure)
+ for an image.
+ This task uses several key variables to help create the list
+ of packages to actually install:
+ <itemizedlist>
+ <listitem><para><link linkend='var-IMAGE_INSTALL'><filename>IMAGE_INSTALL</filename></link>:
+ Lists out the base set of packages to install from
+ the Package Feeds area.</para></listitem>
+ <listitem><para><link linkend='var-PACKAGE_EXCLUDE'><filename>PACKAGE_EXCLUDE</filename></link>:
+ Specifies packages that should not be installed.
+ </para></listitem>
+ <listitem><para><link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>:
+ Specifies features to include in the image.
+ Most of these features map to additional packages for
+ installation.</para></listitem>
+ <listitem><para><link linkend='var-PACKAGE_CLASSES'><filename>PACKAGE_CLASSES</filename></link>:
+ Specifies the package backend to use and consequently
+ helps determine where to locate packages within the
+ Package Feeds area.</para></listitem>
+ <listitem><para><link linkend='var-IMAGE_LINGUAS'><filename>IMAGE_LINGUAS</filename></link>:
+ Determines the language(s) for which additional
+ language support packages are installed.
+ </para></listitem>
+ <listitem><para><link linkend='var-PACKAGE_INSTALL'><filename>PACKAGE_INSTALL</filename></link>:
+ The final list of packages passed to the package manager
+ for installation into the image.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ With
+ <link linkend='var-IMAGE_ROOTFS'><filename>IMAGE_ROOTFS</filename></link>
+ pointing to the location of the filesystem under construction and
+ the <filename>PACKAGE_INSTALL</filename> variable providing the
+ final list of packages to install, the root file system is
+ created.
+ </para>
+
+ <para>
+ Package installation is under control of the package manager
+ (e.g. dnf/rpm, opkg, or apt/dpkg) regardless of whether or
+ not package management is enabled for the target.
+ At the end of the process, if package management is not
+ enabled for the target, the package manager's data files
+ are deleted from the root filesystem.
+ As part of the final stage of package installation, postinstall
+ scripts that are part of the packages are run.
+ Any scripts that fail to run
+ on the build host are run on the target when the target system
+ is first booted.
+ If you are using a
+ <ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-read-only-root-filesystem'>read-only root filesystem</ulink>,
+ all the post installation scripts must succeed during the
+ package installation phase since the root filesystem is
+ read-only.
+ </para>
+
+ <para>
+ The final stages of the <filename>do_rootfs</filename> task
+ handle post processing.
+ Post processing includes creation of a manifest file and
+ optimizations.
+ </para>
+
+ <para>
+ The manifest file (<filename>.manifest</filename>) resides
+ in the same directory as the root filesystem image.
+ This file lists out, line-by-line, the installed packages.
+ The manifest file is useful for the
+ <link linkend='ref-classes-testimage*'><filename>testimage</filename></link>
+ class, for example, to determine whether or not to run
+ specific tests.
+ See the
+ <link linkend='var-IMAGE_MANIFEST'><filename>IMAGE_MANIFEST</filename></link>
+ variable for additional information.
+ </para>
+
+ <para>
+ Optimizing processes run across the image include
+ <filename>mklibs</filename>, <filename>prelink</filename>,
+ and any other post-processing commands as defined by the
+ <link linkend='var-ROOTFS_POSTPROCESS_COMMAND'><filename>ROOTFS_POSTPROCESS_COMMAND</filename></link>
+ variable.
+ The <filename>mklibs</filename> process optimizes the size
+ of the libraries, while the
+ <filename>prelink</filename> process optimizes the dynamic
+ linking of shared libraries to reduce start up time of
+ executables.
+ </para>
+
+ <para>
+ After the root filesystem is built, processing begins on
+ the image through the
+ <link linkend='ref-tasks-image'><filename>do_image</filename></link>
+ task.
+ The build system runs any pre-processing commands as defined
+ by the
+ <link linkend='var-IMAGE_PREPROCESS_COMMAND'><filename>IMAGE_PREPROCESS_COMMAND</filename></link>
+ variable.
+ This variable specifies a list of functions to call before
+ the OpenEmbedded build system creates the final image output
+ files.
+ </para>
+
+ <para>
+ The OpenEmbedded build system dynamically creates
+ <filename>do_image_*</filename> tasks as needed, based
+ on the image types specified in the
+ <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
+ variable.
+ The process turns everything into an image file or a set of
+ image files and compresses the root filesystem image to reduce
+ the overall size of the image.
+ The formats used for the root filesystem depend on the
+ <filename>IMAGE_FSTYPES</filename> variable.
+ </para>
+
+ <para>
+ As an example, a dynamically created task when creating a
+ particular image <replaceable>type</replaceable> would take the
+ following form:
+ <literallayout class='monospaced'>
+ do_image_<replaceable>type</replaceable>[depends]
+ </literallayout>
+ So, if the <replaceable>type</replaceable> as specified by the
+ <filename>IMAGE_FSTYPES</filename> were
+ <filename>ext4</filename>, the dynamically generated task
+ would be as follows:
+ <literallayout class='monospaced'>
+ do_image_ext4[depends]
+ </literallayout>
+ </para>
+
+ <para>
+ The final task involved in image creation is the
+ <link linkend='ref-tasks-image-complete'><filename>do_image_complete</filename></link>
+ task.
+ This task completes the image by applying any image
+ post processing as defined through the
+ <link linkend='var-IMAGE_POSTPROCESS_COMMAND'><filename>IMAGE_POSTPROCESS_COMMAND</filename></link>
+ variable.
+ The variable specifies a list of functions to call once the
+ OpenEmbedded build system has created the final image output
+ files.
+ </para>
+
+ <note>
+ The entire image generation process is run under Pseudo.
+ Running under Pseudo ensures that the files in the root
+ filesystem have correct ownership.
+ </note>
+ </section>
+
+ <section id='sdk-generation-dev-environment'>
+ <title>SDK Generation</title>
+
+ <para>
+ The OpenEmbedded build system uses BitBake to generate the
+ Software Development Kit (SDK) installer script for both the
+ standard and extensible SDKs:
+ <imagedata fileref="figures/sdk-generation.png" align="center" />
+ </para>
+
+ <note>
+ For more information on the cross-development toolchain
+ generation, see the
+ "<link linkend='cross-development-toolchain-generation'>Cross-Development Toolchain Generation</link>"
+ section.
+ For information on advantages gained when building a
+ cross-development toolchain using the
+ <link linkend='ref-tasks-populate_sdk'><filename>do_populate_sdk</filename></link>
+ task, see the
+ "<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (SDK) manual.
+ </note>
+
+ <para>
+ Like image generation, the SDK script process consists of
+ several stages and depends on many variables.
+ The <filename>do_populate_sdk</filename> and
+ <filename>do_populate_sdk_ext</filename> tasks use these
+ key variables to help create the list of packages to actually
+ install.
+ For information on the variables listed in the figure, see the
+ "<link linkend='sdk-dev-environment'>Application Development SDK</link>"
+ section.
+ </para>
+
+ <para>
+ The <filename>do_populate_sdk</filename> task helps create
+ the standard SDK and handles two parts: a target part and a
+ host part.
+ The target part is the part built for the target hardware and
+ includes libraries and headers.
+ The host part is the part of the SDK that runs on the
+ <link linkend='var-SDKMACHINE'><filename>SDKMACHINE</filename></link>.
+ </para>
+
+ <para>
+ The <filename>do_populate_sdk_ext</filename> task helps create
+ the extensible SDK and handles host and target parts
+ differently than its counter part does for the standard SDK.
+ For the extensible SDK, the task encapsulates the build system,
+ which includes everything needed (host and target) for the SDK.
+ </para>
+
+ <para>
+ Regardless of the type of SDK being constructed, the
+ tasks perform some cleanup after which a cross-development
+ environment setup script and any needed configuration files
+ are created.
+ The final output is the Cross-development
+ toolchain installation script (<filename>.sh</filename> file),
+ which includes the environment setup script.
+ </para>
+ </section>
+
+ <section id='stamp-files-and-the-rerunning-of-tasks'>
+ <title>Stamp Files and the Rerunning of Tasks</title>
+
+ <para>
+ For each task that completes successfully, BitBake writes a
+ stamp file into the
+ <link linkend='var-STAMPS_DIR'><filename>STAMPS_DIR</filename></link>
+ directory.
+ The beginning of the stamp file's filename is determined by the
+ <link linkend='var-STAMP'><filename>STAMP</filename></link>
+ variable, and the end of the name consists of the task's name
+ and current
+ <ulink url='&YOCTO_DOCS_BB_URL;#checksums'>input checksum</ulink>.
+ <note>
+ This naming scheme assumes that
+ <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_SIGNATURE_HANDLER'><filename>BB_SIGNATURE_HANDLER</filename></ulink>
+ is "OEBasicHash", which is almost always the case in
+ current OpenEmbedded.
+ </note>
+ To determine if a task needs to be rerun, BitBake checks if a
+ stamp file with a matching input checksum exists for the task.
+ If such a stamp file exists, the task's output is assumed to
+ exist and still be valid.
+ If the file does not exist, the task is rerun.
+ <note>
+ <para>The stamp mechanism is more general than the shared
+ state (sstate) cache mechanism described in the
+ "<link linkend='setscene-tasks-and-shared-state'>Setscene Tasks and Shared State</link>"
+ section.
+ BitBake avoids rerunning any task that has a valid
+ stamp file, not just tasks that can be accelerated through
+ the sstate cache.</para>
+ <para>However, you should realize that stamp files only
+ serve as a marker that some work has been done and that
+ these files do not record task output.
+ The actual task output would usually be somewhere in
+ <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
+ (e.g. in some recipe's
+ <link linkend='var-WORKDIR'><filename>WORKDIR</filename></link>.)
+ What the sstate cache mechanism adds is a way to cache task
+ output that can then be shared between build machines.
+ </para>
+ </note>
+ Since <filename>STAMPS_DIR</filename> is usually a subdirectory
+ of <filename>TMPDIR</filename>, removing
+ <filename>TMPDIR</filename> will also remove
+ <filename>STAMPS_DIR</filename>, which means tasks will
+ properly be rerun to repopulate <filename>TMPDIR</filename>.
+ </para>
+
+ <para>
+ If you want some task to always be considered "out of date",
+ you can mark it with the
+ <ulink url='&YOCTO_DOCS_BB_URL;#variable-flags'><filename>nostamp</filename></ulink>
+ varflag.
+ If some other task depends on such a task, then that task will
+ also always be considered out of date, which might not be what
+ you want.
+ </para>
+
+ <para>
+ For details on how to view information about a task's
+ signature, see the
+ "<link linkend='usingpoky-viewing-task-variable-dependencies'>Viewing Task Variable Dependencies</link>"
+ section.
+ </para>
+ </section>
+
+ <section id='setscene-tasks-and-shared-state'>
+ <title>Setscene Tasks and Shared State</title>
+
+ <para>
+ The description of tasks so far assumes that BitBake needs to
+ build everything and there are no prebuilt objects available.
+ BitBake does support skipping tasks if prebuilt objects are
+ available.
+ These objects are usually made available in the form of a
+ shared state (sstate) cache.
+ <note>
+ For information on variables affecting sstate, see the
+ <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>
+ and
+ <link linkend='var-SSTATE_MIRRORS'><filename>SSTATE_MIRRORS</filename></link>
+ variables.
+ </note>
+ </para>
+
+ <para>
+ The idea of a setscene task (i.e
+ <filename>do_</filename><replaceable>taskname</replaceable><filename>_setscene</filename>)
+ is a version of the task where
+ instead of building something, BitBake can skip to the end
+ result and simply place a set of files into specific locations
+ as needed.
+ In some cases, it makes sense to have a setscene task variant
+ (e.g. generating package files in the
+ <filename>do_package_write_*</filename> task).
+ In other cases, it does not make sense, (e.g. a
+ <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
+ task or
+ <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
+ task) since the work involved would be equal to or greater than
+ the underlying task.
+ </para>
+
+ <para>
+ In the OpenEmbedded build system, the common tasks that have
+ setscene variants are <link linkend='ref-tasks-package'><filename>do_package</filename></link>,
+ <filename>do_package_write_*</filename>,
+ <link linkend='ref-tasks-deploy'><filename>do_deploy</filename></link>,
+ <link linkend='ref-tasks-packagedata'><filename>do_packagedata</filename></link>,
+ and
+ <link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>.
+ Notice that these are most of the tasks whose output is an
+ end result.
+ </para>
+
+ <para>
+ The OpenEmbedded build system has knowledge of the relationship
+ between these tasks and other tasks that precede them.
+ For example, if BitBake runs
+ <filename>do_populate_sysroot_setscene</filename> for
+ something, there is little point in running any of the
+ <filename>do_fetch</filename>, <filename>do_unpack</filename>,
+ <filename>do_patch</filename>,
+ <filename>do_configure</filename>,
+ <filename>do_compile</filename>, and
+ <filename>do_install</filename> tasks.
+ However, if <filename>do_package</filename> needs to be run,
+ BitBake would need to run those other tasks.
+ </para>
+
+ <para>
+ It becomes more complicated if everything can come from an
+ sstate cache because some objects are simply not required at
+ all.
+ For example, you do not need a compiler or native tools, such
+ as quilt, if there is nothing to compile or patch.
+ If the <filename>do_package_write_*</filename> packages are
+ available from sstate, BitBake does not need the
+ <filename>do_package</filename> task data.
+ </para>
+
+ <para>
+ To handle all these complexities, BitBake runs in two phases.
+ The first is the "setscene" stage.
+ During this stage, BitBake first checks the sstate cache for
+ any targets it is planning to build.
+ BitBake does a fast check to see if the object exists rather
+ than a complete download.
+ If nothing exists, the second phase, which is the setscene
+ stage, completes and the main build proceeds.
+ </para>
+
+ <para>
+ If objects are found in the sstate cache, the OpenEmbedded
+ build system works backwards from the end targets specified
+ by the user.
+ For example, if an image is being built, the OpenEmbedded build
+ system first looks for the packages needed for that image and
+ the tools needed to construct an image.
+ If those are available, the compiler is not needed.
+ Thus, the compiler is not even downloaded.
+ If something was found to be unavailable, or the download or
+ setscene task fails, the OpenEmbedded build system then tries
+ to install dependencies, such as the compiler, from the cache.
+ </para>
+
+ <para>
+ The availability of objects in the sstate cache is handled by
+ the function specified by the
+ <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_HASHCHECK_FUNCTION'><filename>BB_HASHCHECK_FUNCTION</filename></ulink>
+ variable and returns a list of the objects that are available.
+ The function specified by the
+ <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_SETSCENE_DEPVALID'><filename>BB_SETSCENE_DEPVALID</filename></ulink>
+ variable is the function that determines whether a given
+ dependency needs to be followed, and whether for any given
+ relationship the function needs to be passed.
+ The function returns a True or False value.
+ </para>
+ </section>
+ </section>
+
+ <section id='images-dev-environment'>
+ <title>Images</title>
+
+ <para>
+ The images produced by the OpenEmbedded build system
+ are compressed forms of the
+ root filesystem that are ready to boot on a target device.
+ You can see from the
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>
+ that BitBake output, in part, consists of images.
+ This section is going to look more closely at this output:
+ <imagedata fileref="figures/images.png" align="center" width="5.5in" depth="5.5in" />
+ </para>
+
+ <para>
+ For a list of example images that the Yocto Project provides,
+ see the
+ "<link linkend='ref-images'>Images</link>" chapter.
+ </para>
+
+ <para>
+ Images are written out to the
+ <link linkend='build-directory'>Build Directory</link>
+ inside the <filename>tmp/deploy/images/<replaceable>machine</replaceable>/</filename>
+ folder as shown in the figure.
+ This folder contains any files expected to be loaded on the
+ target device.
+ The
+ <link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>
+ variable points to the <filename>deploy</filename> directory,
+ while the
+ <link linkend='var-DEPLOY_DIR_IMAGE'><filename>DEPLOY_DIR_IMAGE</filename></link>
+ variable points to the appropriate directory containing images for
+ the current configuration.
+ <itemizedlist>
+ <listitem><para><filename><replaceable>kernel-image</replaceable></filename>:
+ A kernel binary file.
+ The <link linkend='var-KERNEL_IMAGETYPE'><filename>KERNEL_IMAGETYPE</filename></link>
+ variable setting determines the naming scheme for the
+ kernel image file.
+ Depending on that variable, the file could begin with
+ a variety of naming strings.
+ The <filename>deploy/images/<replaceable>machine</replaceable></filename>
+ directory can contain multiple image files for the
+ machine.</para></listitem>
+ <listitem><para><filename><replaceable>root-filesystem-image</replaceable></filename>:
+ Root filesystems for the target device (e.g.
+ <filename>*.ext3</filename> or <filename>*.bz2</filename>
+ files).
+ The <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
+ variable setting determines the root filesystem image
+ type.
+ The <filename>deploy/images/<replaceable>machine</replaceable></filename>
+ directory can contain multiple root filesystems for the
+ machine.</para></listitem>
+ <listitem><para><filename><replaceable>kernel-modules</replaceable></filename>:
+ Tarballs that contain all the modules built for the kernel.
+ Kernel module tarballs exist for legacy purposes and
+ can be suppressed by setting the
+ <link linkend='var-MODULE_TARBALL_DEPLOY'><filename>MODULE_TARBALL_DEPLOY</filename></link>
+ variable to "0".
+ The <filename>deploy/images/<replaceable>machine</replaceable></filename>
+ directory can contain multiple kernel module tarballs
+ for the machine.</para></listitem>
+ <listitem><para><filename><replaceable>bootloaders</replaceable></filename>:
+ Bootloaders supporting the image, if applicable to the
+ target machine.
+ The <filename>deploy/images/<replaceable>machine</replaceable></filename>
+ directory can contain multiple bootloaders for the
+ machine.</para></listitem>
+ <listitem><para><filename><replaceable>symlinks</replaceable></filename>:
+ The <filename>deploy/images/<replaceable>machine</replaceable></filename>
+ folder contains
+ a symbolic link that points to the most recently built file
+ for each machine.
+ These links might be useful for external scripts that
+ need to obtain the latest version of each file.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='sdk-dev-environment'>
+ <title>Application Development SDK</title>
+
+ <para>
+ In the
+ <link linkend='general-yocto-environment-figure'>general Yocto Project Development Environment figure</link>,
+ the output labeled "Application Development SDK" represents an
+ SDK.
+ The SDK generation process differs depending on whether you build
+ a standard SDK
+ (e.g. <filename>bitbake -c populate_sdk</filename> <replaceable>imagename</replaceable>)
+ or an extensible SDK
+ (e.g. <filename>bitbake -c populate_sdk_ext</filename> <replaceable>imagename</replaceable>).
+ This section is going to take a closer look at this output:
+ <imagedata fileref="figures/sdk.png" align="center" width="9in" depth="7.25in" />
+ </para>
+
+ <para>
+ The specific form of this output is a self-extracting
+ SDK installer (<filename>*.sh</filename>) that, when run,
+ installs the SDK, which consists of a cross-development
+ toolchain, a set of libraries and headers, and an SDK
+ environment setup script.
+ Running this installer essentially sets up your
+ cross-development environment.
+ You can think of the cross-toolchain as the "host"
+ part because it runs on the SDK machine.
+ You can think of the libraries and headers as the "target"
+ part because they are built for the target hardware.
+ The environment setup script is added so that you can initialize
+ the environment before using the tools.
+ </para>
+
+ <note><title>Notes</title>
+ <itemizedlist>
+ <listitem><para>
+ The Yocto Project supports several methods by which you can
+ set up this cross-development environment.
+ These methods include downloading pre-built SDK installers
+ or building and installing your own SDK installer.
+ </para></listitem>
+ <listitem><para>
+ For background information on cross-development toolchains
+ in the Yocto Project development environment, see the
+ "<link linkend='cross-development-toolchain-generation'>Cross-Development Toolchain Generation</link>"
+ section.
+ </para></listitem>
+ <listitem><para>
+ For information on setting up a cross-development
+ environment, see the
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ </para></listitem>
+ </itemizedlist>
+ </note>
+ <para>
+ Once built, the SDK installers are written out to the
+ <filename>deploy/sdk</filename> folder inside the
+ <link linkend='build-directory'>Build Directory</link>
+ as shown in the figure at the beginning of this section.
+ Depending on the type of SDK, several variables exist that help
+ configure these files.
+ The following list shows the variables associated with a standard
+ SDK:
+ <itemizedlist>
+ <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
+ Points to the <filename>deploy</filename>
+ directory.</para></listitem>
+ <listitem><para><link linkend='var-SDKMACHINE'><filename>SDKMACHINE</filename></link>:
+ Specifies the architecture of the machine
+ on which the cross-development tools are run to
+ create packages for the target hardware.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDKIMAGE_FEATURES'><filename>SDKIMAGE_FEATURES</filename></link>:
+ Lists the features to include in the "target" part
+ of the SDK.
+ </para></listitem>
+ <listitem><para><link linkend='var-TOOLCHAIN_HOST_TASK'><filename>TOOLCHAIN_HOST_TASK</filename></link>:
+ Lists packages that make up the host
+ part of the SDK (i.e. the part that runs on
+ the <filename>SDKMACHINE</filename>).
+ When you use
+ <filename>bitbake -c populate_sdk <replaceable>imagename</replaceable></filename>
+ to create the SDK, a set of default packages
+ apply.
+ This variable allows you to add more packages.
+ </para></listitem>
+ <listitem><para><link linkend='var-TOOLCHAIN_TARGET_TASK'><filename>TOOLCHAIN_TARGET_TASK</filename></link>:
+ Lists packages that make up the target part
+ of the SDK (i.e. the part built for the
+ target hardware).
+ </para></listitem>
+ <listitem><para><link linkend='var-SDKPATH'><filename>SDKPATH</filename></link>:
+ Defines the default SDK installation path offered by the
+ installation script.
+ </para></listitem>
+ </itemizedlist>
+ This next list, shows the variables associated with an extensible
+ SDK:
+ <itemizedlist>
+ <listitem><para><link linkend='var-DEPLOY_DIR'><filename>DEPLOY_DIR</filename></link>:
+ Points to the <filename>deploy</filename> directory.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_EXT_TYPE'><filename>SDK_EXT_TYPE</filename></link>:
+ Controls whether or not shared state artifacts are copied
+ into the extensible SDK.
+ By default, all required shared state artifacts are copied
+ into the SDK.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_INCLUDE_PKGDATA'><filename>SDK_INCLUDE_PKGDATA</filename></link>:
+ Specifies whether or not packagedata will be included in
+ the extensible SDK for all recipes in the "world" target.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_INCLUDE_TOOLCHAIN'><filename>SDK_INCLUDE_TOOLCHAIN</filename></link>:
+ Specifies whether or not the toolchain will be included
+ when building the extensible SDK.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_LOCAL_CONF_WHITELIST'><filename>SDK_LOCAL_CONF_WHITELIST</filename></link>:
+ A list of variables allowed through from the build system
+ configuration into the extensible SDK configuration.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_LOCAL_CONF_BLACKLIST'><filename>SDK_LOCAL_CONF_BLACKLIST</filename></link>:
+ A list of variables not allowed through from the build
+ system configuration into the extensible SDK configuration.
+ </para></listitem>
+ <listitem><para><link linkend='var-SDK_INHERIT_BLACKLIST'><filename>SDK_INHERIT_BLACKLIST</filename></link>:
+ A list of classes to remove from the
+ <link linkend='var-INHERIT'><filename>INHERIT</filename></link>
+ value globally within the extensible SDK configuration.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+</section>
+
+</chapter>
+<!--
+vim: expandtab tw=80 ts=4
+-->
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-devtool-reference.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-devtool-reference.xml
index 99d5a52..e29bf89 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-devtool-reference.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-devtool-reference.xml
@@ -20,8 +20,8 @@
For more information on how to apply the command when using the
extensible SDK, see the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-extensible'>Using the Extensible SDK</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's
- Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</para>
<section id='devtool-getting-help'>
@@ -35,45 +35,59 @@
the commands:
<literallayout class='monospaced'>
$ devtool --help
- usage: devtool [--basepath BASEPATH] [--bbpath BBPATH] [-d] [-q]
- [--color COLOR] [-h]
- <subcommand> ...
+ usage: devtool add [-h] [--same-dir | --no-same-dir] [--fetch URI]
+ [--fetch-dev] [--version VERSION] [--no-git]
+ [--srcrev SRCREV | --autorev] [--srcbranch SRCBRANCH]
+ [--binary] [--also-native] [--src-subdir SUBDIR]
+ [--mirrors] [--provides PROVIDES]
+ [recipename] [srctree] [fetchuri]
- OpenEmbedded development tool
+ Adds a new recipe to the workspace to build a specified source tree. Can
+ optionally fetch a remote URI and unpack it to create the source tree.
+
+ arguments:
+ recipename Name for new recipe to add (just name - no version,
+ path or extension). If not specified, will attempt
+ to auto-detect it.
+ srctree Path to external source tree. If not specified, a
+ subdirectory of
+ /home/<replaceable>user</replaceable>/poky/build/workspace/sources will be
+ used.
+ fetchuri Fetch the specified URI and extract it to create
+ the source tree
options:
- --basepath BASEPATH Base directory of SDK / build directory
- --bbpath BBPATH Explicitly specify the BBPATH, rather than getting it
- from the metadata
- -d, --debug Enable debug output
- -q, --quiet Print only errors
- --color COLOR Colorize output (where COLOR is auto, always, never)
- -h, --help show this help message and exit
-
- subcommands:
- Beginning work on a recipe:
- add Add a new recipe
- modify Modify the source for an existing recipe
- upgrade Upgrade an existing recipe
- Getting information:
- status Show workspace status
- search Search available recipes
- Working on a recipe in the workspace:
- edit-recipe Edit a recipe file in your workspace
- configure-help Get help on configure script options
- build Build a recipe
- update-recipe Apply changes from external source tree to recipe
- reset Remove a recipe from your workspace
- finish Finish working on a recipe in your workspace
- Testing changes on target:
- deploy-target Deploy recipe output files to live target machine
- undeploy-target Undeploy recipe output files in live target machine
- build-image Build image including workspace recipe packages
- Advanced:
- create-workspace Set up workspace in an alternative location
- extract Extract the source for an existing recipe
- sync Synchronize the source tree for an existing recipe
- Use devtool <subcommand> --help to get help on a specific command
+ -h, --help show this help message and exit
+ --same-dir, -s Build in same directory as source
+ --no-same-dir Force build in a separate build directory
+ --fetch URI, -f URI Fetch the specified URI and extract it to create
+ the source tree (deprecated - pass as positional
+ argument instead)
+ --fetch-dev For npm, also fetch devDependencies
+ --version VERSION, -V VERSION
+ Version to use within recipe (PV)
+ --no-git, -g If fetching source, do not set up source tree as a
+ git repository
+ --srcrev SRCREV, -S SRCREV
+ Source revision to fetch if fetching from an SCM
+ such as git (default latest)
+ --autorev, -a When fetching from a git repository, set SRCREV in
+ the recipe to a floating revision instead of fixed
+ --srcbranch SRCBRANCH, -B SRCBRANCH
+ Branch in source repository if fetching from an SCM
+ such as git (default master)
+ --binary, -b Treat the source tree as something that should be
+ installed verbatim (no compilation, same directory
+ structure). Useful with binary packages e.g. RPMs.
+ --also-native Also add native variant (i.e. support building
+ recipe for the build host as well as the target
+ machine)
+ --src-subdir SUBDIR Specify subdirectory within source tree to use
+ --mirrors Enable PREMIRRORS and MIRRORS for source tree
+ fetching (disable by default).
+ --provides PROVIDES, -p PROVIDES
+ Specify an alias for the item provided by the
+ recipe. E.g. virtual/libgl
</literallayout>
</para>
@@ -194,9 +208,9 @@
The following example creates and adds a new recipe named
<filename>jackson</filename> to a workspace layer the tool creates.
The source code built by the recipes resides in
- <filename>/home/scottrif/sources/jackson</filename>:
+ <filename>/home/<replaceable>user</replaceable>/sources/jackson</filename>:
<literallayout class='monospaced'>
- $ devtool add jackson /home/scottrif/sources/jackson
+ $ devtool add jackson /home/<replaceable>user</replaceable>/sources/jackson
</literallayout>
</para>
@@ -214,18 +228,52 @@
append files, and source files into the existing workspace layer.
The <filename>.bbappend</filename> file is created to point
to the external source tree.
+ <note>
+ If your recipe has runtime dependencies defined, you must be sure
+ that these packages exist on the target hardware before attempting
+ to run your application.
+ If dependent packages (e.g. libraries) do not exist on the target,
+ your application, when run, will fail to find those functions.
+ For more information, see the
+ "<link linkend='devtool-deploying-your-software-on-the-target-machine'>Deploying Your Software on the Target Machine</link>"
+ section.
+ </note>
</para>
- <note>
- If your recipe has runtime dependencies defined, you must be sure
- that these packages exist on the target hardware before attempting
- to run your application.
- If dependent packages (e.g. libraries) do not exist on the target,
- your application, when run, will fail to find those functions.
- For more information, see the
- "<link linkend='devtool-deploying-your-software-on-the-target-machine'>Deploying Your Software on the Target Machine</link>"
- section.
- </note>
+ <para>
+ By default, <filename>devtool add</filename> uses the latest
+ revision (i.e. master) when unpacking files from a remote URI.
+ In some cases, you might want to specify a source revision by
+ branch, tag, or commit hash. You can specify these options when
+ using the <filename>devtool add</filename> command:
+ <itemizedlist>
+ <listitem><para>
+ To specify a source branch, use the
+ <filename>--srcbranch</filename> option:
+ <literallayout class='monospaced'>
+ $ devtool add --srcbranch &DISTRO_NAME_NO_CAP; jackson /home/<replaceable>user</replaceable>/sources/jackson
+ </literallayout>
+ In the previous example, you are checking out the
+ &DISTRO_NAME_NO_CAP; branch.
+ </para></listitem>
+ <listitem><para>
+ To specify a specific tag or commit hash, use the
+ <filename>--srcrev</filename> option:
+ <literallayout class='monospaced'>
+ $ devtool add --srcrev &DISTRO_REL_TAG; jackson /home/<replaceable>user</replaceable>/sources/jackson
+ $ devtool add --srcrev <replaceable>some_commit_hash</replaceable> /home/<replaceable>user</replaceable>/sources/jackson
+ </literallayout>
+ The previous examples check out the &DISTRO_REL_TAG; tag
+ and the commit associated with the
+ <replaceable>some_commit_hash</replaceable> hash.
+ </para></listitem>
+ </itemizedlist>
+ <note>
+ If you prefer to use the latest revision every time the recipe is
+ built, use the options <filename>--autorev</filename>
+ or <filename>-a</filename>.
+ </note>
+ </para>
</section>
<section id='devtool-extracting-the-source-for-an-existing-recipe'>
@@ -276,7 +324,7 @@
Use the <filename>devtool modify</filename> command to begin
modifying the source of an existing recipe.
This command is very similar to the
- <ulink url='&YOCTO_DOCS_DEV_URL;#devtool-adding-a-new-recipe-to-the-workspace'><filename>add</filename></ulink>
+ <link linkend='devtool-adding-a-new-recipe-to-the-workspace'><filename>add</filename></link>
command except that it does not physically create the
recipe in the workspace layer because the recipe already
exists in an another layer.
@@ -334,7 +382,7 @@
to the source files.
For example, if you know you are going to work on some
code, you could first use the
- <ulink url='&YOCTO_DOCS_DEV_URL;#devtool-modifying-a-recipe'><filename>devtool modify</filename></ulink>
+ <link linkend='devtool-modifying-a-recipe'><filename>devtool modify</filename></link>
command to extract the code and set up the workspace.
After which, you could modify, compile, and test the code.
</para>
@@ -556,7 +604,7 @@
remove deployed build output from the target machine.
For the <filename>devtool undeploy-target</filename> command to
work, you must have previously used the
- <ulink url='&YOCTO_DOCS_DEV_URL;#devtool-deploying-your-software-on-the-target-machine'><filename>devtool deploy-target</filename></ulink>
+ <link linkend='devtool-deploying-your-software-on-the-target-machine'><filename>devtool deploy-target</filename></link>
command.
<literallayout class='monospaced'>
$ devtool undeploy-target <replaceable>recipe</replaceable> <replaceable>target</replaceable>
@@ -573,7 +621,7 @@
<para>
Use the <filename>devtool create-workspace</filename> command to
create a new workspace layer in your
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
When you create a new workspace layer, it is populated with the
<filename>README</filename> file and the
<filename>conf</filename> directory only.
@@ -616,7 +664,7 @@
$ devtool status
</literallayout>
Following is sample output after using
- <ulink url='&YOCTO_DOCS_DEV_URL;#devtool-adding-a-new-recipe-to-the-workspace'><filename>devtool add</filename></ulink>
+ <link linkend='devtool-adding-a-new-recipe-to-the-workspace'><filename>devtool add</filename></link>
to create and add the <filename>mtr_0.86.bb</filename> recipe
to the <filename>workspace</filename> directory:
<literallayout class='monospaced'>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-features.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-features.xml
index 7e1c5ef..02857dc 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-features.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-features.xml
@@ -36,7 +36,7 @@
<para>
One method you can use to determine which recipes are checking to see if a
particular feature is contained or not is to <filename>grep</filename> through
- the <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ the <link linkend='metadata'>Metadata</link>
for the feature.
Here is an example that discovers the recipes whose build is potentially
changed based on a given feature:
@@ -132,7 +132,7 @@
These select features make sense to be controlled both at
the machine and distribution configuration level.
See the
- <ulink url='&YOCTO_DOCS_REF_URL;#var-COMBINED_FEATURES'><filename>COMBINED_FEATURES</filename></ulink>
+ <link linkend='var-COMBINED_FEATURES'><filename>COMBINED_FEATURES</filename></link>
variable for more information.
</para>
@@ -151,8 +151,8 @@
is used.
See the
"<ulink url='&YOCTO_DOCS_SDK_URL;#adding-api-documentation-to-the-standard-sdk'>Adding API Documentation to the Standard SDK</ulink>"
- section in the Yocto Project Software Development Kit (SDK)
- Developer's Guide for more information.
+ section in the Yocto Project Application Development and
+ the Extensible Software Development Kit (eSDK) manual.
</para></listitem>
<listitem><para><emphasis>bluetooth:</emphasis> Include
bluetooth support (integrated BT only).</para></listitem>
@@ -217,7 +217,7 @@
the package tests where supported by individual recipes.
For more information on package tests, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#testing-packages-with-ptest'>Testing Packages With ptest</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para></listitem>
<listitem><para><emphasis>smbfs:</emphasis> Include SMB networks
client support (for mounting Samba/Microsoft Windows shares
@@ -304,7 +304,7 @@
<note>
To make the <filename>/var/log</filename> directory
on the target persistent, use the
- <ulink url='&YOCTO_DOCS_REF_URL;#var-VOLATILE_LOG_DIR'><filename>VOLATILE_LOG_DIR</filename></ulink>
+ <link linkend='var-VOLATILE_LOG_DIR'><filename>VOLATILE_LOG_DIR</filename></link>
variable by setting it to "no".
</note>
</para></listitem>
@@ -315,8 +315,8 @@
Creates an image whose root filesystem is read-only.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-read-only-root-filesystem'>Creating a Read-Only Root Filesystem</ulink>"
- section in the Yocto Project Development Manual for more
- information.
+ section in the Yocto Project Development Tasks Manual for
+ more information.
</para></listitem>
<listitem><para><emphasis>splash:</emphasis>
Enables showing a splash screen during boot.
@@ -356,7 +356,8 @@
<filename>perf</filename>, <filename>systemtap</filename>,
and <filename>LTTng</filename>.
For general information on user-space tools, see the
- <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-manual'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
</para></listitem>
<listitem><para><emphasis>ssh-server-dropbear:</emphasis>
Installs the Dropbear minimal SSH server.
@@ -374,7 +375,7 @@
<filename>strace</filename> and <filename>gdb</filename>.
For information on GDB, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-gdb-remotedebug'>Debugging With the GNU Project Debugger (GDB) Remotely</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
For information on tracing and profiling, see the
<ulink url='&YOCTO_DOCS_PROF_URL;'>Yocto Project Profiling and Tracing Manual</ulink>.
</para></listitem>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-images.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-images.xml
index f220968..c752f94 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-images.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-images.xml
@@ -30,8 +30,8 @@
<para>
From within the <filename>poky</filename> Git repository, you can use
the following command to display the list of directories within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
- that containe image recipe files:
+ <link linkend='source-directory'>Source Directory</link>
+ that contain image recipe files:
<literallayout class='monospaced'>
$ ls meta*/recipes*/images/*.bb
</literallayout>
@@ -140,7 +140,7 @@
second image to be tested.
You can find more information about runtime testing in the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para></listitem>
<listitem><para><filename>core-image-testmaster-initramfs</filename>:
A RAM-based Initial Root Filesystem (initramfs) image tailored for
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-kickstart.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-kickstart.xml
new file mode 100644
index 0000000..1dd36b2
--- /dev/null
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-kickstart.xml
@@ -0,0 +1,284 @@
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
+[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
+
+<chapter id='ref-kickstart'>
+<title>OpenEmbedded Kickstart (<filename>.wks</filename>) Reference</title>
+
+ <section id='openembedded-kickstart-wks-reference'>
+ <title>Introduction</title>
+
+ <para>
+ The current Wic implementation supports only the basic kickstart
+ partitioning commands:
+ <filename>partition</filename> (or <filename>part</filename>
+ for short) and <filename>bootloader</filename>.
+ <note>
+ Future updates will implement more commands and options.
+ If you use anything that is not specifically supported, results
+ can be unpredictable.
+ </note>
+ </para>
+
+ <para>
+ This chapter provides a reference on the available kickstart
+ commands.
+ The information lists the commands, their syntax, and meanings.
+ Kickstart commands are based on the Fedora kickstart versions but
+ with modifications to reflect Wic capabilities.
+ You can see the original documentation for those commands at the
+ following links:
+ <itemizedlist>
+ <listitem><para>
+ <ulink url='http://fedoraproject.org/wiki/Anaconda/Kickstart#part_or_partition'>http://fedoraproject.org/wiki/Anaconda/Kickstart#part_or_partition</ulink>
+ </para></listitem>
+ <listitem><para>
+ <ulink url='http://fedoraproject.org/wiki/Anaconda/Kickstart#bootloader'>http://fedoraproject.org/wiki/Anaconda/Kickstart#bootloader</ulink>
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='command-part-or-partition'>
+ <title>Command: part or partition</title>
+
+ <para>
+ Either of these commands create a partition on the system and use
+ the following syntax:
+ <literallayout class='monospaced'>
+ part [<replaceable>mntpoint</replaceable>]
+ partition [<replaceable>mntpoint</replaceable>]
+ </literallayout>
+ If you do not provide <replaceable>mntpoint</replaceable>, Wic
+ creates a partition but does not mount it.
+ </para>
+
+ <para>
+ The <filename><replaceable>mntpoint</replaceable></filename> is
+ where the partition will be mounted and must be of one of the
+ following forms:
+ <itemizedlist>
+ <listitem><para>
+ <filename>/<replaceable>path</replaceable></filename>:
+ For example, "/", "/usr", or "/home"
+ </para></listitem>
+ <listitem><para>
+ <filename>swap</filename>:
+ The created partition is used as swap space.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ Specifying a <replaceable>mntpoint</replaceable> causes the
+ partition to automatically be mounted.
+ Wic achieves this by adding entries to the filesystem table (fstab)
+ during image generation.
+ In order for wic to generate a valid fstab, you must also provide
+ one of the <filename>--ondrive</filename>,
+ <filename>--ondisk</filename>, or
+ <filename>--use-uuid</filename> partition options as part of the
+ command.
+ Here is an example using "/" as the mountpoint.
+ The command uses "--ondisk" to force the partition onto the
+ <filename>sdb</filename> disk:
+ <literallayout class='monospaced'>
+ part / --source rootfs --ondisk sdb --fstype=ext3 --label platform --align 1024
+ </literallayout>
+ </para>
+
+ <para>
+ Here is a list that describes other supported options you can use
+ with the <filename>part</filename> and
+ <filename>partition</filename> commands:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>--size</filename>:</emphasis>
+ The minimum partition size in MBytes.
+ Specify an integer value such as 500.
+ Do not append the number with "MB".
+ You do not need this option if you use
+ <filename>--source</filename>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--source</filename>:</emphasis>
+ This option is a Wic-specific option that names the source
+ of the data that populates the partition.
+ The most common value for this option is "rootfs", but you
+ can use any value that maps to a valid source plug-in.
+ For information on the source plug-ins, see the
+ "<link linkend='wic-plug-ins-interface'>Wic Plug-Ins Interface</link>"
+ section.</para>
+
+ <para>If you use <filename>--source rootfs</filename>, Wic
+ creates a partition as large as needed and to fill it with
+ the contents of the root filesystem pointed to by the
+ <filename>-r</filename> command-line option or the
+ equivalent rootfs derived from the <filename>-e</filename>
+ command-line option.
+ The filesystem type used to create the partition is driven
+ by the value of the <filename>--fstype</filename> option
+ specified for the partition.
+ See the entry on <filename>--fstype</filename> that follows
+ for more information.</para>
+
+ <para>If you use
+ <filename>--source <replaceable>plugin-name</replaceable></filename>,
+ Wic creates a partition as large as needed and fills it
+ with the contents of the partition that is generated by the
+ specified plug-in name using the data pointed to by the
+ <filename>-r</filename> command-line option or the
+ equivalent rootfs derived from the <filename>-e</filename>
+ command-line option.
+ Exactly what those contents and filesystem type end up
+ being are dependent on the given plug-in implementation.
+ </para>
+
+ <para>If you do not use the <filename>--source</filename>
+ option, the <filename>wic</filename> command creates an
+ empty partition.
+ Consequently, you must use the <filename>--size</filename>
+ option to specify the size of the empty partition.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--ondisk</filename> or <filename>--ondrive</filename>:</emphasis>
+ Forces the partition to be created on a particular disk.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--fstype</filename>:</emphasis>
+ Sets the file system type for the partition.
+ Valid values are:
+ <itemizedlist>
+ <listitem><para>
+ <filename>ext4</filename>
+ </para></listitem>
+ <listitem><para>
+ <filename>ext3</filename>
+ </para></listitem>
+ <listitem><para>
+ <filename>ext2</filename>
+ </para></listitem>
+ <listitem><para>
+ <filename>btrfs</filename>
+ </para></listitem>
+ <listitem><para>
+ <filename>squashfs</filename>
+ </para></listitem>
+ <listitem><para>
+ <filename>swap</filename>
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--fsoptions</filename>:</emphasis>
+ Specifies a free-form string of options to be used when
+ mounting the filesystem.
+ This string will be copied into the
+ <filename>/etc/fstab</filename> file of the installed
+ system and should be enclosed in quotes.
+ If not specified, the default string is "defaults".
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--label label</filename>:</emphasis>
+ Specifies the label to give to the filesystem to be made on
+ the partition.
+ If the given label is already in use by another filesystem,
+ a new label is created for the partition.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--active</filename>:</emphasis>
+ Marks the partition as active.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--align (in KBytes)</filename>:</emphasis>
+ This option is a Wic-specific option that says to start a
+ partition on an <replaceable>x</replaceable> KBytes
+ boundary.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--no-table</filename>:</emphasis>
+ This option is a Wic-specific option.
+ Using the option reserves space for the partition and
+ causes it to become populated.
+ However, the partition is not added to the partition table.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--extra-space</filename>:</emphasis>
+ This option is a Wic-specific option that adds extra space
+ after the space filled by the content of the partition.
+ The final size can go beyond the size specified by the
+ <filename>--size</filename> option.
+ The default value is 10 Mbytes.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--overhead-factor</filename>:</emphasis>
+ This option is a Wic-specific option that multiplies the
+ size of the partition by the option's value.
+ You must supply a value greater than or equal to "1".
+ The default value is "1.3".
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--part-type</filename>:</emphasis>
+ This option is a Wic-specific option that specifies the
+ partition type globally unique identifier (GUID) for GPT
+ partitions.
+ You can find the list of partition type GUIDs at
+ <ulink url='http://en.wikipedia.org/wiki/GUID_Partition_Table#Partition_type_GUIDs'></ulink>.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--use-uuid</filename>:</emphasis>
+ This option is a Wic-specific option that causes Wic to
+ generate a random GUID for the partition.
+ The generated identifier is used in the bootloader
+ configuration to specify the root partition.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--uuid</filename>:</emphasis>
+ This option is a Wic-specific option that specifies the
+ partition UUID.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id='command-bootloader'>
+ <title>Command: bootloader</title>
+
+ <para>
+ This command specifies how the bootloader should be configured and
+ supports the following options:
+ <note>
+ Bootloader functionality and boot partitions are implemented by
+ the various <filename>--source</filename> plug-ins that
+ implement bootloader functionality.
+ The bootloader command essentially provides a means of
+ modifying bootloader configuration.
+ </note>
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>--timeout</filename>:</emphasis>
+ Specifies the number of seconds before the bootloader times
+ out and boots the default option.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--append</filename>:</emphasis>
+ Specifies kernel parameters.
+ These parameters will be added to the syslinux
+ <filename>APPEND</filename> or <filename>grub</filename>
+ kernel command line.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>--configfile</filename>:</emphasis>
+ Specifies a user-defined configuration file for the
+ bootloader.
+ You can provide a full pathname for the file or a file that
+ exists in the <filename>canned-wks</filename> folder.
+ This option overrides all other bootloader options.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+</chapter>
+<!--
+vim: expandtab tw=80 ts=4
+-->
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-manual.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-manual.xml
index 752b210..d4b7bee 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-manual.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-manual.xml
@@ -22,11 +22,11 @@
<authorgroup>
<author>
- <firstname>Richard</firstname> <surname>Purdie</surname>
+ <firstname>Scott</firstname> <surname>Rifenbark</surname>
<affiliation>
- <orgname>Linux Foundation</orgname>
+ <orgname>Scotty's Documentation Services, INC</orgname>
</affiliation>
- <email>richard.purdie@linuxfoundation.org</email>
+ <email>srifenbark@gmail.com</email>
</author>
</authorgroup>
@@ -113,24 +113,19 @@
<revremark>Released with the Yocto Project 2.3 Release.</revremark>
</revision>
<revision>
- <revnumber>2.3.1</revnumber>
- <date>June 2017</date>
- <revremark>Released with the Yocto Project 2.3.1 Release.</revremark>
+ <revnumber>2.4</revnumber>
+ <date>October 2017</date>
+ <revremark>Released with the Yocto Project 2.4 Release.</revremark>
</revision>
<revision>
- <revnumber>2.3.2</revnumber>
- <date>September 2017</date>
- <revremark>Released with the Yocto Project 2.3.2 Release.</revremark>
- </revision>
- <revision>
- <revnumber>2.3.3</revnumber>
+ <revnumber>2.4.1</revnumber>
<date>January 2018</date>
- <revremark>Released with the Yocto Project 2.3.3 Release.</revremark>
+ <revremark>Released with the Yocto Project 2.4.1 Release.</revremark>
</revision>
<revision>
- <revnumber>2.3.4</revnumber>
- <date>April 2018</date>
- <revremark>Released with the Yocto Project 2.3.4 Release.</revremark>
+ <revnumber>2.4.2</revnumber>
+ <date>March 2018</date>
+ <revremark>Released with the Yocto Project 2.4.2 Release.</revremark>
</revision>
</revhistory>
@@ -147,29 +142,31 @@
<note><title>Manual Notes</title>
<itemizedlist>
<listitem><para>
- For the latest version of the Yocto Project Reference
- Manual associated with this Yocto Project release
- (version &YOCTO_DOC_VERSION;),
- see the Yocto Project Reference Manual from the
+ This version of the
+ <emphasis>Yocto Project Reference Manual</emphasis>
+ is for the &YOCTO_DOC_VERSION; release of the
+ Yocto Project.
+ To be sure you have the latest version of the manual
+ for this release, use the manual from the
<ulink url='&YOCTO_HOME_URL;/documentation'>Yocto Project documentation page</ulink>.
</para></listitem>
<listitem><para>
- This version of the manual is version
- &YOCTO_DOC_VERSION;.
- For later releases of the Yocto Project (if they exist),
- go to the
+ For manuals associated with other releases of the Yocto
+ Project, go to the
<ulink url='&YOCTO_HOME_URL;/documentation'>Yocto Project documentation page</ulink>
and use the drop-down "Active Releases" button
- and choose the Yocto Project version for which you want
- the manual.
+ and choose the manual associated with the desired
+ Yocto Project.
</para></listitem>
<listitem><para>
- For an in-development version of the Yocto Project
- Reference Manual, see
- <ulink url='&YOCTO_DOCS_URL;/latest/ref-manual/ref-manual.html'></ulink>.
+ To report any inaccuracies or problems with this
+ manual, send an email to the Yocto Project
+ discussion group at
+ <filename>yocto@yoctoproject.com</filename> or log into
+ the freenode <filename>#yocto</filename> channel.
</para></listitem>
- </itemizedlist>
- </note>
+ </itemizedlist>
+ </note>
</legalnotice>
</bookinfo>
@@ -178,7 +175,7 @@
<xi:include href="usingpoky.xml"/>
- <xi:include href="closer-look.xml"/>
+ <xi:include href="ref-development-environment.xml"/>
<xi:include href="technical-details.xml"/>
@@ -194,6 +191,8 @@
<xi:include href="ref-devtool-reference.xml"/>
+ <xi:include href="ref-kickstart.xml"/>
+
<xi:include href="ref-qa-checks.xml"/>
<xi:include href="ref-images.xml"/>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-release-process.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-release-process.xml
index fe3ba09..e2902eb 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-release-process.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-release-process.xml
@@ -61,9 +61,9 @@
<para>
Each major release receives a codename that identifies the release in
the
- <ulink url='&YOCTO_DOCS_DEV_URL;#yocto-project-repositories'>Yocto Project Source Repositories</ulink>.
+ <link linkend='yocto-project-repositories'>Yocto Project Source Repositories</link>.
The concept is that branches of
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
with the same codename are likely to be compatible and thus
work together.
<note>
@@ -131,7 +131,7 @@
Yocto Project.
For information on how to run available tests on your projects, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -206,7 +206,8 @@
<para>
The Yocto Project's main Autobuilder
(<filename>autobuilder.yoctoproject.org</filename>) publicly tests
- each Yocto Project release's code in the OE-Core, Poky, and BitBake
+ each Yocto Project release's code in the
+ <link linkend='oe-core'>OE-Core</link>, Poky, and BitBake
repositories.
The testing occurs for both the current state of the
"master" branch and also for submitted patches.
@@ -216,7 +217,7 @@
in the <filename>poky</filename> repository.
<note>
You can find all these branches in the Yocto Project
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-repositories'>Source Repositories</ulink>.
+ <link linkend='source-repositories'>Source Repositories</link>.
</note>
Testing within these public branches ensures in a publicly visible way
that all of the main supposed architectures and recipes in OE-Core
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-structure.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-structure.xml
index 9b2701c..4bddc59 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-structure.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-structure.xml
@@ -7,16 +7,19 @@
<title>Source Directory Structure</title>
<para>
- The <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink> consists of several components.
- Understanding them and knowing where they are located is key to using the Yocto Project well.
- This chapter describes the Source Directory and gives information about the various
- files and directories.
+ The <link linkend='source-directory'>Source Directory</link>
+ consists of several components.
+ Understanding them and knowing where they are located is key to using the
+ Yocto Project well.
+ This chapter describes the Source Directory and gives information about
+ the various files and directories.
</para>
<para>
- For information on how to establish a local Source Directory on your development system, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#getting-setup'>Getting Set Up</ulink>"
- section in the Yocto Project Development Manual.
+ For information on how to establish a local Source Directory on your
+ development system, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-yocto-project-source-files'>Working With Yocto Project Source Files</ulink>"
+ section in the Yocto Project Development Tasks Manual.
</para>
<note>
@@ -31,7 +34,7 @@
<para>
This section describes the top-level components of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
<section id='structure-core-bitbake'>
@@ -42,7 +45,7 @@
The copy usually matches the current stable BitBake release from
the BitBake project.
BitBake, a
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
interpreter, reads the Yocto Project Metadata and runs the tasks
defined by that data.
Failures are usually from the Metadata and not from BitBake itself.
@@ -53,10 +56,8 @@
When you run the <filename>bitbake</filename> command, the
main BitBake executable, which resides in the
<filename>bitbake/bin/</filename> directory, starts.
- Sourcing an environment setup script (e.g.
- <link linkend="structure-core-script"><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend="structure-memres-core-script"><filename>oe-init-build-env-memres</filename></link>)
+ Sourcing the environment setup script (i.e.
+ <link linkend="structure-core-script"><filename>&OE_INIT_FILE;</filename></link>)
places the <filename>scripts</filename> and
<filename>bitbake/bin</filename> directories (in that order) into
the shell's <filename>PATH</filename> environment variable.
@@ -75,27 +76,24 @@
This directory contains user configuration files and the output
generated by the OpenEmbedded build system in its standard configuration where
the source tree is combined with the output.
- The <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ The
+ <link linkend='build-directory'>Build Directory</link>
is created initially when you <filename>source</filename>
the OpenEmbedded build environment setup script
(i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
</para>
<para>
It is also possible to place output and configuration
files in a directory separate from the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
by providing a directory name when you <filename>source</filename>
the setup script.
For information on separating output from your local
Source Directory files, see the
- "<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- and
- "<link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>"
- sections.
+ "<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>"
+ section.
</para>
</section>
@@ -175,9 +173,7 @@
This directory contains various integration scripts that implement
extra functionality in the Yocto Project environment (e.g. QEMU scripts).
The <link linkend="structure-core-script"><filename>&OE_INIT_FILE;</filename></link>
- and
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>
- scripts append this directory to the shell's
+ script appends this directory to the shell's
<filename>PATH</filename> environment variable.
</para>
@@ -192,14 +188,7 @@
<title><filename>&OE_INIT_FILE;</filename></title>
<para>
- This script is one of two scripts that set up the OpenEmbedded build
- environment.
- For information on the other script, see the
- "<link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>"
- section.
- </para>
-
- <para>
+ This script sets up the OpenEmbedded build environment.
Running this script with the <filename>source</filename> command in
a shell makes changes to <filename>PATH</filename> and sets other
core BitBake variables based on the current working directory.
@@ -212,7 +201,7 @@
<para>
When you run this script, your Yocto Project environment is set
up, a
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
is created, your working directory becomes the Build Directory,
and you are presented with a list of common BitBake targets.
Here is an example:
@@ -234,19 +223,19 @@
The script gets its default list of common targets from the
<filename>conf-notes.txt</filename> file, which is found in the
<filename>meta-poky</filename> directory within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
Should you have custom distributions, it is very easy to modify
this configuration file to include your targets for your
distribution.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-custom-template-configuration-directory'>Creating a Custom Template Configuration Directory</ulink>"
- section in the Yocto Project Development Manual for more
+ section in the Yocto Project Development Tasks Manual for more
information.
</para>
<para>
By default, running this script without a
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
argument creates the <filename>build</filename> directory
in your current working directory.
If you provide a Build Directory argument when you
@@ -254,17 +243,17 @@
build system to create a Build Directory of your choice.
For example, the following command creates a Build Directory named
<filename>mybuilds</filename> that is outside of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>:
+ <link linkend='source-directory'>Source Directory</link>:
<literallayout class='monospaced'>
$ source &OE_INIT_FILE; ~/mybuilds
</literallayout>
The OpenEmbedded build system uses the template configuration
files, which are found by default in the
<filename>meta-poky/conf</filename> directory in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ Source Directory.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-custom-template-configuration-directory'>Creating a Custom Template Configuration Directory</ulink>"
- section in the Yocto Project Development Manual for more
+ section in the Yocto Project Development Tasks Manual for more
information.
<note>
The OpenEmbedded build system does not support file or directory names that
@@ -278,157 +267,6 @@
</para>
</section>
- <section id='structure-memres-core-script'>
- <title><filename>oe-init-build-env-memres</filename></title>
-
- <para>
- This script is one of two scripts that set up the OpenEmbedded
- build environment.
- Aside from setting up the environment, this script starts a
- memory-resident BitBake server.
- For information on the other setup script, see the
- "<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>"
- section.
- </para>
-
- <para>
- Memory-resident BitBake resides in memory until you specifically
- remove it using the following BitBake command:
- <literallayout class='monospaced'>
- $ bitbake -m
- </literallayout>
- </para>
-
- <para>
- Running this script with the <filename>source</filename> command in
- a shell makes changes to <filename>PATH</filename> and sets other
- core BitBake variables based on the current working directory.
- One of these variables is the
- <link linkend='var-BBSERVER'><filename>BBSERVER</filename></link>
- variable, which allows the OpenEmbedded build system to locate
- the server that is running BitBake.
- </para>
-
- <para>
- You need to run an environment setup script before using BitBake
- commands.
- Following is the script syntax:
- <literallayout class='monospaced'>
- $ source oe-init-build-env-memres <replaceable>port_number</replaceable> <replaceable>build_dir</replaceable>
- </literallayout>
- Following are some considerations when sourcing this script:
- <itemizedlist>
- <listitem><para>
- The script uses other scripts within the
- <filename>scripts</filename> directory to do the bulk of
- the work.
- </para></listitem>
- <listitem><para>
- If you do not provide a port number with the script, the
- BitBake server starts at a randomly selected port.
- </para></listitem>
- <listitem><para>
- The script's parameters are positionally dependent.
- Consequently, you cannot run the script and provide a
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- name without also providing a port number.
- In other words, the following syntax is illegal:
- <literallayout class='monospaced'>
- $ source oe-initbuild-env-memres <replaceable>build_dir</replaceable>
- </literallayout>
- <note>
- The previous restriction might be resolved in the
- future.
- See
- <ulink url='https://bugzilla.yoctoproject.org/show_bug.cgi?id=7555'>Bug 7555</ulink>
- for more information.
- </note>
- </para></listitem>
- </itemizedlist>
- </para>
-
- <para>
- When you run this script, your Yocto Project environment is set
- up, a Build Directory is created, your working directory becomes
- the Build Directory, and you are presented with a list of common
- BitBake targets.
- Here is an example:
- <literallayout class='monospaced'>
- $ source oe-init-build-env-memres
- No port specified, using dynamically selected port
-
- ### Shell environment set up for builds. ###
-
- You can now run 'bitbake <target>'
-
- Common targets are:
- core-image-minimal
- core-image-sato
- meta-toolchain
- meta-ide-support
-
- You can also run generated qemu images with a command like 'runqemu qemux86'
- Bitbake server address: 127.0.0.1, server port: 53995
- Bitbake server started on demand as needed, use bitbake -m to shut it down
- </literallayout>
- The script gets its default list of common targets from the
- <filename>conf-notes.txt</filename> file, which is found in the
- <filename>meta-poky</filename> directory within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
- Should you have custom distributions, it is very easy to modify
- this configuration file to include your targets for your
- distribution.
- See the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-custom-template-configuration-directory'>Creating a Custom Template Configuration Directory</ulink>"
- section in the Yocto Project Development Manual for more
- information.
- </para>
-
- <para>
- By default, running this script without a
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- argument creates a build directory named
- <filename>build</filename>.
- If you provide a Build Directory argument and port number when you
- <filename>source</filename> the script, the Build Directory is
- created using that name.
- For example, the following command starts the BitBake server using
- port 53995 and creates a Build Directory named
- <filename>mybuilds</filename> that is outside of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>:
- <literallayout class='monospaced'>
- $ source oe-init-build-env-memres 53995 ~/mybuilds
- </literallayout>
- The <filename>oe-init-build-env-memres</filename> script starts a
- memory resident BitBake server.
- This BitBake instance uses the
- <filename>bitbake-cookerdaemon.log</filename> file, which is
- located in the Build Directory.
- </para>
-
- <para>
- The OpenEmbedded build system uses the template configuration
- files, which are found by default in the
- <filename>meta-poky/conf</filename> directory in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
- See the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-custom-template-configuration-directory'>Creating a Custom Template Configuration Directory</ulink>"
- section in the Yocto Project Development Manual for more
- information.
- <note>
- The OpenEmbedded build system does not support file or
- directory names that contain spaces.
- If you attempt to run the
- <filename>oe-init-build-env-memres</filename> script
- from a Source Directory that contains spaces in either the
- filenames or directory names, the script returns an error
- indicating no such file or directory.
- Be sure to use a Source Directory free of names containing
- spaces.
- </note>
- </para>
- </section>
-
<section id='structure-basic-top-level'>
<title><filename>LICENSE, README, and README.hardware</filename></title>
@@ -443,11 +281,9 @@
<para>
The OpenEmbedded build system creates the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
- when you run one of the build environment setup scripts (i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ <link linkend='build-directory'>Build Directory</link>
+ when you run the build environment setup scripts (i.e.
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
</para>
<para>
@@ -505,9 +341,7 @@
<filename>local.conf.sample</filename> when
you <filename>source</filename> the top-level build environment
setup script (i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
</para>
<para>
@@ -533,7 +367,7 @@
You can see how the <filename>TEMPLATECONF</filename> variable
is used by looking at the
<filename>scripts/oe-setup-builddir</filename> script in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You can find the Yocto Project version of the
<filename>local.conf.sample</filename> file in the
<filename>meta-poky/conf</filename> directory.
@@ -559,9 +393,7 @@
<filename>bblayers.conf.sample</filename> when
you <filename>source</filename> the top-level build environment
setup script (i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
</para>
<para>
@@ -585,7 +417,7 @@
<note>
You can see how the <filename>TEMPLATECONF</filename> variable
<filename>scripts/oe-setup-builddir</filename> script in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You can find the Yocto Project version of the
<filename>bblayers.conf.sample</filename> file in the
<filename>meta-poky/conf</filename> directory.
@@ -733,7 +565,7 @@
contain appropriate <filename>COPYING</filename> license files with other licensing information.
For information on licensing, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
- section.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -777,7 +609,8 @@
sysroot that matches your target hardware.
You can find out more about these installers in the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</para>
</section>
@@ -808,7 +641,8 @@
recipe listed in
<link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>.
Population of this directory is handled through shared state, while
- the path is specified by the <filename>COMPONENTS_DIR</filename>
+ the path is specified by the
+ <link linkend='var-COMPONENTS_DIR'><filename>COMPONENTS_DIR</filename></link>
variable. Apart from a few unusual circumstances, handling of the
<filename>sysroots-components</filename> directory should be
automatic, and recipes should not directly reference
@@ -907,7 +741,8 @@
<filename>linux-qemux86-standard-build</filename> and then patched by Quilt.
(See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#using-a-quilt-workflow'>Using Quilt in Your Workflow</ulink>"
- section in the Yocto Project Development Manual for more information.)
+ section in the Yocto Project Development Tasks Manual for more
+ information.)
Within the <filename>linux-qemux86-standard-build</filename> directory,
standard Quilt directories <filename>linux-3.0/patches</filename>
and <filename>linux-3.0/.pc</filename> are created,
@@ -1041,7 +876,7 @@
<para>
As mentioned previously,
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink> is the core
+ <link linkend='metadata'>Metadata</link> is the core
of the Yocto Project.
Metadata has several important subdivisions:
</para>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-style.css b/import-layers/yocto-poky/documentation/ref-manual/ref-style.css
index 8ea8dac..7077e4b 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-style.css
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-style.css
@@ -773,6 +773,10 @@
border-color: black;
}
+.writernotes {
+ color: red;
+}
+
/*********** /
/ graphics /
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-tasks.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-tasks.xml
index 87ddb98..c726cb9 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-tasks.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-tasks.xml
@@ -302,7 +302,7 @@
See the <filename>bin_package.bbclass</filename>
file in the <filename>meta/classes</filename>
directory of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
for an example.
</para></listitem>
</itemizedlist>
@@ -495,10 +495,11 @@
<para>
Installs the files into the individual recipe specific sysroots
- (i.e.
+ (i.e. <filename>recipe-sysroot</filename> and
+ <filename>recipe-sysroot-native</filename> under
<filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}</filename>
based upon the dependencies specified by
- <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>.
+ <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>).
See the
"<link linkend='ref-classes-staging'><filename>staging</filename></link>"
class for more information.
@@ -717,7 +718,7 @@
the BitBake environment.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devpyshell'>Using a Development Python Shell</ulink>"
- section in the Yocto Project Development Manual for more
+ section in the Yocto Project Development Tasks Manual for more
information about using <filename>devpyshell</filename>.
</para>
</section>
@@ -730,7 +731,7 @@
development, debugging, or both.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devshell'>Using a Development Shell</ulink>"
- section in the Yocto Project Development Manual for more
+ section in the Yocto Project Development Tasks Manual for more
information about using <filename>devshell</filename>.
</para>
</section>
@@ -820,7 +821,7 @@
Boots an image and performs runtime tests within the image.
For information on automatically testing images, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
@@ -838,17 +839,7 @@
<para>
For information on automatically testing images, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
- </para>
- </section>
-
- <section id='ref-tasks-vmdkimg'>
- <title><filename>do_vmdkimg</filename></title>
-
- <para>
- Creates a <filename>.vmdk</filename> image for use with
- <ulink url='http://www.vmware.com/'>VMware</ulink>
- and compatible virtual machine hosts.
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
</section>
@@ -892,7 +883,7 @@
$ bitbake linux-yocto -c diffconfig
</literallayout>
For more information, see the
- "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#generating-configuration-files'>Generating Configuration Files</ulink>"
+ "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#creating-config-fragments'>Creating Configuration Fragments</ulink>"
section in the Yocto Project Linux Kernel Development Manual.
</para>
</section>
@@ -927,7 +918,7 @@
$ bitbake linux-yocto -c kernel_configcheck -f
</literallayout>
For more information, see the
- "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#generating-configuration-files'>Generating Configuration Files</ulink>"
+ "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#validating-configuration'>Validating Configuration</ulink>"
section in the Yocto Project Linux Kernel Development Manual.
</para>
</section>
@@ -965,12 +956,9 @@
</literallayout>
</note>
See the
- "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#generating-configuration-files'>Generating Configuration Files</ulink>"
+ "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#using-menuconfig'>Using <filename>menuconfig</filename></ulink>"
section in the Yocto Project Linux Kernel Development Manual
for more information on this configuration tool.
- You can also reference the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#using-menuconfig'>Using <filename>menuconfig</filename></ulink>"
- section in the Yocto Project Development Manual.
</para>
</section>
@@ -997,8 +985,8 @@
<para>
Runs <filename>make menuconfig</filename> for the kernel.
For information on <filename>menuconfig</filename>, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#using-menuconfig'>Using <filename>menuconfig</filename></ulink>"
- section in the Yocto Project Development Manual.
+ "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#using-menuconfig'>Using <filename>menuconfig</filename></ulink>"
+ section in the Yocto Project Linux Kernel Development Manual.
</para>
</section>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/ref-variables.xml b/import-layers/yocto-poky/documentation/ref-manual/ref-variables.xml
index ad10139..2b01723 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/ref-variables.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/ref-variables.xml
@@ -29,7 +29,7 @@
<link linkend='var-KARCH'>K</link>
<link linkend='var-LABELS'>L</link>
<link linkend='var-MACHINE'>M</link>
-<!-- <link linkend='var-glossary-n'>N</link> -->
+ <link linkend='var-NATIVELSBSTRING'>N</link>
<link linkend='var-OBJCOPY'>O</link>
<link linkend='var-P'>P</link>
<!-- <link linkend='var-glossary-q'>Q</link> -->
@@ -321,7 +321,7 @@
For information on how the variable works, see the
<filename>meta/classes/archiver.bbclass</filename> file
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
</glossdef>
</glossentry>
@@ -488,7 +488,7 @@
<para>
For more information see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#automatically-incrementing-a-binary-package-revision-number'>Automatically Incrementing a Binary Package Revision Number</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -536,7 +536,7 @@
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
The directory within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
in which the OpenEmbedded build system places generated
objects during a recipe's build process.
By default, this directory is the same as the <link linkend='var-S'><filename>S</filename></link>
@@ -626,14 +626,14 @@
Multilib context.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#combining-multiple-versions-library-files-into-one-image'>Combining Multiple Versions of Library Files into One Image</ulink>"
- section in the Yocto Project Development Manual for
+ section in the Yocto Project Development Tasks Manual for
information on Multilib.
</para>
<para>
The <filename>BASE_LIB</filename> variable is defined in
the machine include files in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
If Multilib is not being used, the value defaults to "lib".
</para>
</glossdef>
@@ -734,7 +734,7 @@
variable to "1", "yes", or "true"
in your <filename>local.conf</filename> file, which is
located in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>:
+ <link linkend='build-directory'>Build Directory</link>:
Here is an example:
<literallayout class='monospaced'>
BB_DANGLINGAPPENDS_WARNONLY = "1"
@@ -759,7 +759,7 @@
Disk space monitoring is disabled by default.
To enable monitoring, add the <filename>BB_DISKMON_DIRS</filename>
variable to your <filename>conf/local.conf</filename> file found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
Use the following form:
<literallayout class='monospaced'>
BB_DISKMON_DIRS = "<replaceable>action</replaceable>,<replaceable>dir</replaceable>,<replaceable>threshold</replaceable> [...]"
@@ -852,7 +852,7 @@
Defines the disk space and free inode warning intervals.
To set these intervals, define the variable in your
<filename>conf/local.conf</filename> file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
<para>
@@ -936,7 +936,7 @@
</literallayout>
Set this variable in your <filename>local.conf</filename>
file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
</glossdef>
</glossentry>
@@ -1154,7 +1154,8 @@
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
Lists the layers to enable during the build.
This variable is defined in the <filename>bblayers.conf</filename> configuration
- file in the <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ file in the
+ <link linkend='build-directory'>Build Directory</link>.
Here is an example:
<literallayout class='monospaced'>
BBLAYERS = " \
@@ -1250,7 +1251,7 @@
BBMULTIFONFIG = "configA configB configC"
</literallayout>
Each configuration file you use must reside in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory's</ulink>
+ <link linkend='build-directory'>Build Directory</link>
<filename>conf/multiconfig</filename> directory
(e.g.
<replaceable>build_directory</replaceable><filename>/conf/multiconfig/configA.conf</filename>).
@@ -1262,7 +1263,7 @@
supports building targets with multiple configurations,
see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-building-targets-with-multiple-configurations'>Building Targets with Multiple Configurations</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -1280,7 +1281,7 @@
<filename>PATH</filename> variable.
<note>
If you run BitBake from a directory outside of the
- <ulink url='&YOCTO_DOCS_DEV_URL;build-directory'>Build Directory</ulink>,
+ <link linkend='build-directory'>Build Directory</link>,
you must be sure to set
<filename>BBPATH</filename> to point to the
Build Directory.
@@ -1298,29 +1299,29 @@
<glossentry id='var-BBSERVER'><glossterm>BBSERVER</glossterm>
<info>
- BBSERVER[doc] = "Points to the server that runs memory-resident BitBake."
+ BBSERVER[doc] = "Points to the BitBake remote server."
</info>
<glossdef>
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
- Points to the server that runs memory-resident BitBake.
- This variable is set by the
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>
- setup script and should not be hand-edited.
- The variable is only used when you employ memory-resident
- BitBake.
- The setup script exports the value as follows:
+ If defined in the BitBake environment,
+ <filename>BBSERVER</filename> points to the BitBake
+ remote server.
+ </para>
+
+ <para>
+ Use the following format to export the variable to the
+ BitBake environment:
<literallayout class='monospaced'>
- export BBSERVER=localhost:$port
+ export BBSERVER=localhost:$port"
</literallayout>
</para>
<para>
- For more information on how the
- <filename>BBSERVER</filename> is used, see the
- <filename>oe-init-build-env-memres</filename> script, which
- is located in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ By default, <filename>BBSERVER</filename> also appears in
+ <ulink url='&YOCTO_DOCS_BB_URL;#var-BB_HASHBASE_WHITELIST'><filename>BB_HASHBASE_WHITELIST</filename></ulink>.
+ Consequently, <filename>BBSERVER</filename> is excluded
+ from checksum and dependency data.
</para>
</glossdef>
</glossentry>
@@ -1373,7 +1374,7 @@
<para>
For more information on how this variable works, see
<filename>meta/classes/binconfig.bbclass</filename> in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You can also find general information on the class in the
"<link linkend='ref-classes-binconfig'><filename>binconfig.bbclass</filename></link>"
section.
@@ -1456,6 +1457,51 @@
</glossdef>
</glossentry>
+ <glossentry id='var-BUILD_AS_ARCH'><glossterm>BUILD_AS_ARCH</glossterm>
+ <info>
+ BUILD_AS_ARCH[doc] = "Specifies the architecture-specific assembler flags for the build host."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the architecture-specific assembler flags for
+ the build host. By default, the value of
+ <filename>BUILD_AS_ARCH</filename> is empty.
+ </para>
+ </glossdef>
+ </glossentry>
+
+ <glossentry id='var-BUILD_CC_ARCH'><glossterm>BUILD_CC_ARCH</glossterm>
+ <info>
+ BUILD_CC_ARCH[doc] = "Specifies the architecture-specific C compiler flags for the build host."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the architecture-specific C compiler flags for
+ the build host. By default, the value of
+ <filename>BUILD_CC_ARCH</filename> is empty.
+ </para>
+ </glossdef>
+ </glossentry>
+
+ <glossentry id='var-BUILD_CCLD'><glossterm>BUILD_CCLD</glossterm>
+ <info>
+ BUILD_CCLD[doc] = "Specifies the linker command to be used for the build host when the C compiler is being used as the linker."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the linker command to be used for the build host
+ when the C compiler is being used as the linker. By default,
+ <filename>BUILD_CCLD</filename> points to GCC and passes as
+ arguments the value of
+ <link linkend='var-BUILD_CC_ARCH'><filename>BUILD_CC_ARCH</filename></link>,
+ assuming <filename>BUILD_CC_ARCH</filename> is set.
+ </para>
+ </glossdef>
+ </glossentry>
+
<glossentry id='var-BUILD_CFLAGS'><glossterm>BUILD_CFLAGS</glossterm>
<info>
BUILD_CFLAGS[doc] = "Specifies the flags to pass to the C compiler when building for the build host."
@@ -1505,6 +1551,52 @@
</glossdef>
</glossentry>
+ <glossentry id='var-BUILD_FC'><glossterm>BUILD_FC</glossterm>
+ <info>
+ BUILD_FC[doc] = "Specifies the Fortran compiler command for the build host."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the Fortran compiler command for the build host.
+ By default, <filename>BUILD_FC</filename> points to
+ Gfortran and passes as arguments the value of
+ <link linkend='var-BUILD_CC_ARCH'><filename>BUILD_CC_ARCH</filename></link>,
+ assuming <filename>BUILD_CC_ARCH</filename> is set.
+ </para>
+ </glossdef>
+ </glossentry>
+
+ <glossentry id='var-BUILD_LD'><glossterm>BUILD_LD</glossterm>
+ <info>
+ BUILD_LD[doc] = "Specifies the linker command for the build host."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the linker command for the build host. By default,
+ <filename>BUILD_LD</filename> points to the GNU linker (ld)
+ and passes as arguments the value of
+ <link linkend='var-BUILD_LD_ARCH'><filename>BUILD_LD_ARCH</filename></link>,
+ assuming <filename>BUILD_LD_ARCH</filename> is set.
+ </para>
+ </glossdef>
+ </glossentry>
+
+ <glossentry id='var-BUILD_LD_ARCH'><glossterm>BUILD_LD_ARCH</glossterm>
+ <info>
+ BUILD_LD_ARCH[doc] = "Specifies architecture-specific linker flags for the build."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies architecture-specific linker flags for the build
+ host. By default, the value of
+ <filename>BUILD_LD_ARCH</filename> is empty.
+ </para>
+ </glossdef>
+ </glossentry>
+
<glossentry id='var-BUILD_LDFLAGS'><glossterm>BUILD_LDFLAGS</glossterm>
<info>
BUILD_LDFLAGS[doc] = "Specifies the flags to pass to the linker when building for the build host."
@@ -1578,6 +1670,21 @@
</glossdef>
</glossentry>
+ <glossentry id='var-BUILD_STRIP'><glossterm>BUILD_STRIP</glossterm>
+ <info>
+ BUILD_STRIP[doc] = "Specifies the command to be used to strip debugging symbols from binaries produced for the build host."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Specifies the command to be used to strip debugging symbols
+ from binaries produced for the build host. By default,
+ <filename>BUILD_STRIP</filename> points to
+ <filename>${</filename><link linkend='var-BUILD_PREFIX'><filename>BUILD_PREFIX</filename></link><filename>}strip</filename>.
+ </para>
+ </glossdef>
+ </glossentry>
+
<glossentry id='var-BUILD_SYS'><glossterm>BUILD_SYS</glossterm>
<info>
BUILD_SYS[doc] = "The toolchain binary prefix used for native recipes."
@@ -1626,14 +1733,12 @@
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
Points to the location of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
You can define this directory indirectly through the
<link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- and
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>
- scripts by passing in a Build Directory path when you run
- the scripts.
- If you run the scripts and do not provide a Build Directory
+ script by passing in a Build Directory path when you run
+ the script.
+ If you run the script and do not provide a Build Directory
path, the <filename>BUILDDIR</filename> defaults to
<filename>build</filename> in the current directory.
</para>
@@ -1968,7 +2073,7 @@
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
Specifies the directory BitBake uses to store a cache
of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
so it does not need to be parsed every time BitBake is
started.
</para>
@@ -2126,7 +2231,7 @@
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
Points to <filename>meta/files/common-licenses</filename>
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>,
+ <link linkend='source-directory'>Source Directory</link>,
which is where generic license files reside.
</para>
</glossdef>
@@ -2207,6 +2312,27 @@
</glossdef>
</glossentry>
+ <glossentry id='var-COMPONENTS_DIR'><glossterm>COMPONENTS_DIR</glossterm>
+ <info>
+ COMPONENTS_DIR[doc] = "Stores sysroot components for each recipe."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Stores sysroot components for each recipe.
+ The OpenEmbedded build system uses
+ <filename>COMPONENTS_DIR</filename> when constructing
+ recipe-specific sysroots for other recipes.
+ </para>
+
+ <para>
+ The default is
+ "<filename>${</filename><link linkend='var-STAGING_DIR'><filename>STAGING_DIR</filename></link><filename>}-components</filename>."
+ (i.e. "<filename>${</filename><link linkend='var-TMPDIR'><filename>TMPDIR</filename></link><filename>}/sysroots-components</filename>").
+ </para>
+ </glossdef>
+ </glossentry>
+
<glossentry id='var-CONF_VERSION'><glossterm>CONF_VERSION</glossterm>
<info>
CONF_VERSION[doc] = "Tracks the version of local.conf. Increased each time build/conf/ changes incompatibly."
@@ -2272,7 +2398,7 @@
than <filename>/usr/bin</filename>.
You can find a list of these variables at the top of the
<filename>meta/conf/bitbake.conf</filename> file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</note>
</glossdef>
</glossentry>
@@ -2315,7 +2441,7 @@
<para>
For information on creating an initramfs, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -2549,8 +2675,8 @@
variable for additional information.
You can also reference the
"<ulink url='&YOCTO_DOCS_DEV_URL;#providing-license-text'>Providing License Text</ulink>"
- section in the Yocto Project Development Manual for
- information on providing license text.
+ section in the Yocto Project Development Tasks Manual
+ for information on providing license text.
</note>
</para>
</glossdef>
@@ -2577,8 +2703,8 @@
variable for additional information.
You can also reference the
"<ulink url='&YOCTO_DOCS_DEV_URL;#providing-license-text'>Providing License Text</ulink>"
- section in the Yocto Project Development Manual for
- information on providing license text.
+ section in the Yocto Project Development Tasks Manual
+ for information on providing license text.
</note>
</para>
</glossdef>
@@ -2595,7 +2721,7 @@
You should only set this variable in the
<filename>local.conf</filename> configuration file found
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
<para>
@@ -2805,7 +2931,8 @@
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
The destination directory.
- The location in the <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ The location in the
+ <link linkend='build-directory'>Build Directory</link>
where components are installed by the
<link linkend='ref-tasks-install'><filename>do_install</filename></link>
task.
@@ -3116,7 +3243,7 @@
system uses to place images, packages, SDKs and other output
files that are ready to be used outside of the build system.
By default, this directory resides within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
as <filename>${TMPDIR}/deploy</filename>.
</para>
@@ -3189,7 +3316,7 @@
The directory is machine-specific as it contains the
<filename>${MACHINE}</filename> name.
By default, this directory resides within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
as <filename>${DEPLOY_DIR}/images/${MACHINE}/</filename>.
</para>
@@ -3439,7 +3566,7 @@
and resides in the
<filename>meta-poky/conf/distro</filename> directory of
the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
<para>
@@ -3453,7 +3580,7 @@
<para>
Distribution configuration files are located in a
<filename>conf/distro</filename> directory within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
that contains the distribution configuration.
The value for <filename>DISTRO</filename> must not contain
spaces, and is typically all lower-case.
@@ -3794,7 +3921,7 @@
to touch it.
By default, the directory is <filename>downloads</filename>
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
<literallayout class='monospaced'>
#DL_DIR ?= "${TOPDIR}/downloads"
</literallayout>
@@ -3862,14 +3989,14 @@
<glossentry id='var-EFI_PROVIDER'><glossterm>EFI_PROVIDER</glossterm>
<info>
- EFI_PROVIDER[doc] = "When building bootable images (i.e. where hddimg or vmdk is in IMAGE_FSTYPES), the EFI_PROVIDER variable specifies the EFI bootloader to use."
+ EFI_PROVIDER[doc] = "When building bootable images (i.e. where hddimg, iso, or wic.vmdk is in IMAGE_FSTYPES), the EFI_PROVIDER variable specifies the EFI bootloader to use."
</info>
<glossdef>
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
When building bootable images (i.e. where
- <filename>hddimg</filename> or <filename>vmdk</filename>
- is in
+ <filename>hddimg</filename>, <filename>iso</filename>,
+ or <filename>wic.vmdk</filename> is in
<link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>),
the <filename>EFI_PROVIDER</filename> variable specifies
the EFI bootloader to use.
@@ -4117,7 +4244,7 @@
You can also find information on how to use this variable
in the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-software-from-an-external-source'>Building Software from an External Source</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -4148,7 +4275,7 @@
You can also find information on how to use this variable
in the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-software-from-an-external-source'>Building Software from an External Source</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -4191,7 +4318,7 @@
<para>
Typically, you configure this variable in your
<filename>local.conf</filename> file, which is found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
Although you can use this variable from within a recipe,
best practices dictate that you do not.
<note>
@@ -4225,8 +4352,8 @@
filesystem is read-only. See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#creating-a-read-only-root-filesystem'>Creating a Read-Only Root Filesystem</ulink>"
section in the Yocto Project
- Development Manual for more
- information
+ Development Tasks Manual for
+ more information
"tools-debug" - Adds debugging tools such as gdb and
strace.
@@ -4252,7 +4379,7 @@
For an example that shows how to customize your image by
using this variable, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#usingpoky-extend-customimage-imagefeatures'>Customizing Images Using Custom <filename>IMAGE_FEATURES</filename> and <filename>EXTRA_IMAGE_FEATURES</filename></ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -4541,7 +4668,7 @@
<filename>/usr/bin</filename>.
You can find a list of these variables at the top of the
<filename>meta/conf/bitbake.conf</filename> file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
You will also find the default values of the various
<filename>FILES_*</filename> variables in this file.
</note>
@@ -4615,7 +4742,8 @@
in a directory that has the same name as the corresponding
append file.
<note>
- <para>When extending <filename>FILESEXTRAPATHS</filename>,
+ <para>When extending
+ <filename>FILESEXTRAPATHS</filename>,
be sure to use the immediate expansion
(<filename>:=</filename>) operator.
Immediate expansion makes sure that BitBake evaluates
@@ -4624,6 +4752,7 @@
some later time when expansion might result in a
directory that does not contain the files you need.
</para>
+
<para>Also, include the trailing separating colon
character if you are prepending.
The trailing colon character is necessary because you
@@ -4641,13 +4770,37 @@
</para>
<para>
- Here is a final example that specifically adds three paths:
+ This next example specifically adds three paths:
<literallayout class='monospaced'>
FILESEXTRAPATHS_prepend := "path_1:path_2:path_3:"
</literallayout>
</para>
<para>
+ A final example shows how you can extend the search path
+ and include a
+ <link linkend='var-MACHINE'><filename>MACHINE</filename></link>-specific
+ override, which is useful in a BSP layer:
+ <literallayout class='monospaced'>
+ FILESEXTRAPATHS_prepend_intel-x86-common := "${THISDIR}/${PN}:"
+ </literallayout>
+ The previous statement appears in the
+ <filename>linux-yocto-dev.bbappend</filename> file, which
+ is found in the Yocto Project
+ <link linkend='source-repositories'>Source Repositories</link>
+ in
+ <filename>meta-intel/common/recipes-kernel/linux</filename>.
+ Here, the machine override is a special
+ <link linkend='var-PACKAGE_ARCH'><filename>PACKAGE_ARCH</filename></link>
+ definition for multiple <filename>meta-intel</filename>
+ machines.
+ <note>
+ For a layer that supports a single BSP, the override
+ could just be the value of <filename>MACHINE</filename>.
+ </note>
+ </para>
+
+ <para>
By prepending paths in <filename>.bbappend</filename>
files, you allow multiple append files that reside in
different layers but are used for the same recipe to
@@ -4707,7 +4860,7 @@
The default value for the <filename>FILESPATH</filename>
variable is defined in the <filename>base.bbclass</filename>
class found in <filename>meta/classes</filename> in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>:
+ <link linkend='source-directory'>Source Directory</link>:
<literallayout class='monospaced'>
FILESPATH = "${@base_set_filespath(["${FILE_DIRNAME}/${BP}", \
"${FILE_DIRNAME}/${BPN}", "${FILE_DIRNAME}/files"], d)}"
@@ -4753,7 +4906,7 @@
<para>
By default, the OpenEmbedded build system uses the <filename>fs-perms.txt</filename>, which
is located in the <filename>meta/files</filename> folder in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
If you create your own file permissions setting table, you should place it in your
layer or the distro's layer.
</para>
@@ -4761,7 +4914,7 @@
<para>
You define the <filename>FILESYSTEM_PERMS_TABLES</filename> variable in the
<filename>conf/local.conf</filename> file, which is found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>, to
+ <link linkend='build-directory'>Build Directory</link>, to
point to your custom <filename>fs-perms.txt</filename>.
You can specify more than a single file permissions setting table.
The paths you specify to these files must be defined within the
@@ -5539,7 +5692,7 @@
<para>
For more information, see
<filename>meta/classes/image_types.bbclass</filename> in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
</glossdef>
</glossentry>
@@ -5613,7 +5766,7 @@
Typically, you configure this variable in an image recipe.
Although you can use this variable from your
<filename>local.conf</filename> file, which is found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>,
+ <link linkend='build-directory'>Build Directory</link>,
best practices dictate that you do not.
<note>
To enable extra features from outside the image recipe,
@@ -5633,7 +5786,7 @@
For an example that shows how to customize your image by
using this variable, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#usingpoky-extend-customimage-imagefeatures'>Customizing Images Using Custom <filename>IMAGE_FEATURES</filename> and <filename>EXTRA_IMAGE_FEATURES</filename></ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -5662,20 +5815,25 @@
<link linkend='var-IMAGE_TYPES'><filename>IMAGE_TYPES</filename></link>.
</para>
- <note>
- If you add "live" to <filename>IMAGE_FSTYPES</filename>
- inside an image recipe, be sure that you do so prior to the
- "inherit image" line of the recipe or the live image will
- not build.
- </note>
-
- <note>
- Due to the way this variable is processed, it is not
- possible to update its contents using
- <filename>_append</filename> or
- <filename>_prepend</filename>. To add one or more
- additional options to this variable the
- <filename>+=</filename> operator must be used.
+ <note><title>Notes</title>
+ <itemizedlist>
+ <listitem><para>
+ If you add "live" to
+ <filename>IMAGE_FSTYPES</filename> inside an image
+ recipe, be sure that you do so prior to the
+ "inherit image" line of the recipe or the live
+ image will not build.
+ </para></listitem>
+ <listitem><para>
+ Due to the way the OpenEmbedded build system
+ processes this variable, you cannot update its
+ contents by using <filename>_append</filename> or
+ <filename>_prepend</filename>.
+ You must use the <filename>+=</filename>
+ operator to add one or more options to the
+ <filename>IMAGE_FSTYPES</filename> variable.
+ </para></listitem>
+ </itemizedlist>
</note>
</glossdef>
</glossentry>
@@ -5703,7 +5861,7 @@
not be affected by <filename>IMAGE_INSTALL</filename>.
For information on creating an initramfs, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</note>
</para>
@@ -6188,7 +6346,6 @@
jffs2
jffs2.sum
multiubi
- qcow2
squashfs
squashfs-lzo
squashfs-xz
@@ -6199,8 +6356,6 @@
tar.xz
ubi
ubifs
- vdi
- vmdk
wic
wic.bz2
wic.gz
@@ -6212,7 +6367,7 @@
For more information about these types of images, see
<filename>meta/classes/image_types*.bbclass</filename>
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
</glossdef>
</glossentry>
@@ -6455,7 +6610,7 @@
The default value of this variable, which is set in the
<filename>meta/conf/bitbake.conf</filename> configuration
file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>,
+ <link linkend='source-directory'>Source Directory</link>,
is "cpio.gz".
The Linux kernel's initramfs mechanism, as opposed to the
initial RAM filesystem
@@ -6477,32 +6632,38 @@
<link linkend='var-PROVIDES'><filename>PROVIDES</filename></link>
name of an image recipe that is used to build an initial
RAM filesystem (initramfs) image.
- An initramfs provides a temporary root filesystem used for
- early system initialization (e.g. loading of modules
- needed to locate and mount the "real" root filesystem).
- The specified recipe is added as a dependency of the root
- filesystem recipe (e.g.
- <filename>core-image-sato</filename>).
- See the <filename>meta/recipes-core/images/core-image-minimal-initramfs.bb</filename>
- recipe in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
- for an example initramfs recipe.
- To select this recipe to provide the initramfs,
- set <filename>INITRAMFS_IMAGE</filename> to
- "core-image-minimal-initramfs".
+ In other words, the <filename>INITRAMFS_IMAGE</filename>
+ variable causes an additional recipe to be built as
+ a dependency to whatever root filesystem recipe you
+ might be using (e.g. <filename>core-image-sato</filename>).
+ The initramfs image recipe you provide should set
+ <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
+ to
+ <link linkend='var-INITRAMFS_FSTYPES'><filename>INITRAMFS_FSTYPES</filename></link>.
+ </para>
+
+ <para>
+ An initramfs image provides a temporary root filesystem
+ used for early system initialization (e.g. loading of
+ modules needed to locate and mount the "real" root
+ filesystem).
<note>
- The initramfs image recipe should set
- <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
- to
- <link linkend='var-INITRAMFS_FSTYPES'><filename>INITRAMFS_FSTYPES</filename></link>.
+ See the <filename>meta/recipes-core/images/core-image-minimal-initramfs.bb</filename>
+ recipe in the
+ <link linkend='source-directory'>Source Directory</link>
+ for an example initramfs recipe.
+ To select this sample recipe as the one built
+ to provide the initramfs image,
+ set <filename>INITRAMFS_IMAGE</filename> to
+ "core-image-minimal-initramfs".
</note>
</para>
<para>
You can also find more information by referencing the
- <filename>meta/poky/conf/local.conf.sample.extended</filename>
+ <filename>meta-poky/conf/local.conf.sample.extended</filename>
configuration file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>,
+ <link linkend='source-directory'>Source Directory</link>,
the
<link linkend='ref-classes-image'><filename>image</filename></link>
class, and the
@@ -6513,7 +6674,7 @@
<para>
If <filename>INITRAMFS_IMAGE</filename> is empty, which is
- the default, then no initramfs is built.
+ the default, then no initramfs image is built.
</para>
<para>
@@ -6521,10 +6682,10 @@
<link linkend='var-INITRAMFS_IMAGE_BUNDLE'><filename>INITRAMFS_IMAGE_BUNDLE</filename></link>
variable, which allows the generated image to be bundled
inside the kernel image.
- Additionally, for information on creating an initramfs, see
- the
+ Additionally, for information on creating an initramfs
+ image, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -6562,7 +6723,7 @@
The combined binary is deposited into the
<filename>tmp/deploy</filename> directory, which is part
of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
<para>
@@ -6591,7 +6752,7 @@
file for additional information.
Also, for information on creating an initramfs, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -6862,12 +7023,13 @@
<para>
Values for this variable are set in the kernel's recipe
file and the kernel's append file.
- For example, if you are using the Yocto Project kernel that
- is based on the Linux 3.14 kernel, the kernel recipe file
- is the
- <filename>meta/recipes-kernel/linux/linux-yocto_3.14.bb</filename>
+ For example, if you are using the
+ <filename>linux-yocto_4.12</filename> kernel, the kernel
+ recipe file is the
+ <filename>meta/recipes-kernel/linux/linux-yocto_4.12.bb</filename>
file.
- Following is an example for a kernel recipe file:
+ <filename>KBRANCH</filename> is set as follows in that
+ kernel recipe file:
<literallayout class='monospaced'>
KBRANCH ?= "standard/base"
</literallayout>
@@ -6877,21 +7039,25 @@
This variable is also used from the kernel's append file
to identify the kernel branch specific to a particular
machine or target hardware.
- The kernel's append file is located in the BSP layer for
- a given machine.
- For example, the kernel append file for the Emenlow BSP is in the
- <filename>meta-intel</filename> Git repository and is named
- <filename>meta-emenlow/recipes-kernel/linux/linux-yocto_3.14.bbappend</filename>.
- Here are the related statements from the append file:
+ Continuing with the previous kernel example, the kernel's
+ append file (i.e.
+ <filename>linux-yocto_4.12.bbappend</filename>) is located
+ in the BSP layer for a given machine.
+ For example, the append file for the Beaglebone,
+ EdgeRouter, and generic versions of both 32 and 64-bit IA
+ machines (<filename>meta-yocto-bsp</filename>) is named
+ <filename>meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend</filename>.
+ Here are the related statements from that append file:
<literallayout class='monospaced'>
- COMPATIBLE_MACHINE_emenlow-noemgd = "emenlow-noemgd"
- KMACHINE_emenlow-noemgd = "emenlow"
- KBRANCH_emenlow-noemgd = "standard/base"
- KERNEL_FEATURES_append_emenlow-noemgd = " features/drm-gma500/drm-gma500.scc"
+ KBRANCH_genericx86 = "standard/base"
+ KBRANCH_genericx86-64 = "standard/base"
+ KBRANCH_edgerouter = "standard/edgerouter"
+ KBRANCH_beaglebone = "standard/beaglebone"
+ KBRANCH_mpc8315e-rdb = "standard/fsl-mpc8315e-rdb"
</literallayout>
- The <filename>KBRANCH</filename> statement identifies
- the kernel branch to use when building for the Emenlow
- BSP.
+ The <filename>KBRANCH</filename> statements identify
+ the kernel branch to use when building for each
+ supported BSP.
</para>
</glossdef>
</glossentry>
@@ -6913,20 +7079,23 @@
Typically, when using a <filename>defconfig</filename> to
configure a kernel during a build, you place the
file in your layer in the same manner as you would
- patch files and configuration fragment files (i.e.
+ place patch files and configuration fragment files (i.e.
"out-of-tree").
However, if you want to use a <filename>defconfig</filename>
file that is part of the kernel tree (i.e. "in-tree"),
you can use the
- <filename>KBUILD_DEFCONFIG</filename> variable to point
- to the <filename>defconfig</filename> file.
+ <filename>KBUILD_DEFCONFIG</filename> variable and append
+ the
+ <link linkend='var-KMACHINE'><filename>KMACHINE</filename></link>
+ variable to point to the <filename>defconfig</filename>
+ file.
</para>
<para>
To use the variable, set it in the append file for your
kernel recipe using the following form:
<literallayout class='monospaced'>
- KBUILD_DEFCONFIG_<link linkend='var-KMACHINE'>KMACHINE</link> ?= <replaceable>defconfig_file</replaceable>
+ KBUILD_DEFCONFIG_<replaceable>KMACHINE</replaceable> ?= <replaceable>defconfig_file</replaceable>
</literallayout>
Here is an example from a "raspberrypi2"
<filename>KMACHINE</filename> build that uses a
@@ -7028,41 +7197,50 @@
<glossentry id='var-KERNEL_FEATURES'><glossterm>KERNEL_FEATURES</glossterm>
<info>
- KERNEL_FEATURES[doc] = "Includes additional metadata from the Yocto Project kernel Git repository. The metadata you add through this variable includes config fragments and features descriptions."
+ KERNEL_FEATURES[doc] = "Includes additional kernel metadata. The metadata you add through this variable includes config fragments and features descriptions."
</info>
<glossdef>
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
- Includes additional metadata from the Yocto Project kernel Git repository.
- In the OpenEmbedded build system, the default Board Support Packages (BSPs)
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ Includes additional kernel metadata.
+ In the OpenEmbedded build system, the default Board Support
+ Packages (BSPs)
+ <link linkend='metadata'>Metadata</link>
is provided through
the <link linkend='var-KMACHINE'><filename>KMACHINE</filename></link>
- and <link linkend='var-KBRANCH'><filename>KBRANCH</filename></link> variables.
- You can use the <filename>KERNEL_FEATURES</filename> variable to further
- add metadata for all BSPs.
+ and
+ <link linkend='var-KBRANCH'><filename>KBRANCH</filename></link>
+ variables.
+ You can use the <filename>KERNEL_FEATURES</filename>
+ variable from within the kernel recipe or kernel append
+ file to further add metadata for all BSPs or specific
+ BSPs.
</para>
<para>
- The metadata you add through this variable includes config fragments and
- features descriptions,
+ The metadata you add through this variable includes config
+ fragments and features descriptions,
which usually includes patches as well as config fragments.
- You typically override the <filename>KERNEL_FEATURES</filename> variable
- for a specific machine.
- In this way, you can provide validated, but optional, sets of kernel
- configurations and features.
+ You typically override the
+ <filename>KERNEL_FEATURES</filename> variable for a
+ specific machine.
+ In this way, you can provide validated, but optional,
+ sets of kernel configurations and features.
</para>
<para>
- For example, the following adds <filename>netfilter</filename> to all
- the Yocto Project kernels and adds sound support to the <filename>qemux86</filename>
- machine:
+ For example, the following example from the
+ <filename>linux-yocto-rt_4.12</filename> kernel recipe
+ adds "netfilter" and "taskstats" features to all BSPs
+ as well as "virtio" configurations to all QEMU machines.
+ The last two statements add specific configurations to
+ targeted machine types:
<literallayout class='monospaced'>
- # Add netfilter to all linux-yocto kernels
- KERNEL_FEATURES="features/netfilter/netfilter.scc"
-
- # Add sound support to the qemux86 machine
- KERNEL_FEATURES_append_qemux86=" cfg/sound.scc"
+ KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
+ KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
+ KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
+ KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
+ KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
</literallayout></para>
</glossdef>
</glossentry>
@@ -7739,7 +7917,7 @@
<link linkend='var-COPY_LIC_MANIFEST'><filename>COPY_LIC_MANIFEST</filename></link>
variable, and the
"<ulink url='&YOCTO_DOCS_DEV_URL;#providing-license-text'>Providing License Text</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -7838,7 +8016,7 @@
defines the search
arguments used by the kernel tools to find the appropriate
description within the kernel
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
with which to build out the sources and configuration.
</para>
</glossdef>
@@ -7942,7 +8120,7 @@
Specifies the target device for which the image is built.
You define <filename>MACHINE</filename> in the
<filename>local.conf</filename> file found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
By default, <filename>MACHINE</filename> is set to
"qemux86", which is an x86-based architecture machine to
be emulated using QEMU:
@@ -7957,7 +8135,7 @@
Thus, when <filename>MACHINE</filename> is set to "qemux86" there
exists the corresponding <filename>qemux86.conf</filename> machine
configuration file, which can be found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
in <filename>meta/conf/machine</filename>.
</para>
@@ -8708,6 +8886,29 @@
</glossdef>
</glossentry>
+ <glossentry id='var-NOAUTOPACKAGEDEBUG'><glossterm>NOAUTOPACKAGEDEBUG</glossterm>
+ <info>
+ NOAUTOPACKAGEDEBUG[doc] = "Disables auto package from splitting .debug files."
+ </info>
+ <glossdef>
+ <para role="glossdeffirst">
+<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
+ Disables auto package from splitting
+ <filename>.debug</filename> files. If a recipe requires
+ <filename>FILES_${PN}-dbg</filename> to be set manually,
+ the <filename>NOAUTOPACKAGEDEBUG</filename> can be defined
+ allowing you to define the content of the debug package.
+ For example:
+ <literallayout class='monospaced'>
+ NOAUTOPACKAGEDEBUG = "1"
+ FILES_${PN}-dev = "${includedir}/${QT_DIR_NAME}/Qt/*"
+ FILES_${PN}-dbg = "/usr/src/debug/"
+ FILES_${QT_BASE_NAME}-demos-doc = "${docdir}/${QT_DIR_NAME}/qch/qt.qch"
+ </literallayout>
+ </para>
+ </glossdef>
+ </glossentry>
+
<glossentry id='var-NOHDD'><glossterm>NOHDD</glossterm>
<info>
NOHDD[doc] = "Causes the OpenEmbedded build system to skip building the .hddimg image."
@@ -8798,7 +8999,7 @@
<para>
See the <filename>meta/classes/binconfig.bbclass</filename>
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
for details on how this class applies these additional
sed command arguments.
For general information on the
@@ -8863,7 +9064,7 @@
<filename>-c devshell</filename> command-line option).
For more information, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devshell'>Using a Development Shell</ulink>" section
- in the Yocto Project Development Manual.
+ in the Yocto Project Development Tasks Manual.
</para>
<para>
@@ -8891,19 +9092,17 @@
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
The directory from which the top-level build environment
setup script is sourced.
- The Yocto Project makes two top-level build environment
- setup scripts available:
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- and
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>.
- When you run one of these scripts, the
+ The Yocto Project provides a top-level build environment
+ setup script:
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>.
+ When you run this script, the
<filename>OEROOT</filename> variable resolves to the
directory that contains the script.
</para>
<para>
For additional information on how this variable is used,
- see the initialization scripts.
+ see the initialization script.
</para>
</glossdef>
</glossentry>
@@ -9086,7 +9285,7 @@
This variable, which is set in the
<filename>local.conf</filename> configuration file found in
the <filename>conf</filename> folder of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>,
+ <link linkend='build-directory'>Build Directory</link>,
specifies the package manager the OpenEmbedded build system
uses when packaging data.
</para>
@@ -9179,7 +9378,7 @@
You can find out more about debugging using GDB by reading
the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-gdb-remotedebug'>Debugging With the GNU Project Debugger (GDB) Remotely</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -9466,7 +9665,7 @@
variable.
For information on creating an initramfs, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#building-an-initramfs-image'>Building an Initial RAM Filesystem (initramfs) Image</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -9522,7 +9721,7 @@
For information on running post-installation scripts, see
the
"<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-post-installation-scripts'>Post-Installation Scripts</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -9654,7 +9853,7 @@
<glossentry id='var-PACKAGECONFIG_CONFARGS'><glossterm>PACKAGECONFIG_CONFARGS</glossterm>
<info>
- PACKAGECONFIG_CONFARGS[doc] = "A space-separated list of configuration options generated from PACKAGECONFIG."
+ PACKAGECONFIG_CONFARGS[doc] = "A space-separated list of configuration options generated from the PACKAGECONFIG setting."
</info>
<glossdef>
<para role="glossdeffirst">
@@ -9789,7 +9988,7 @@
For an example of how to use the <filename>PACKAGES_DYNAMIC</filename>
variable when you are splitting packages, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#handling-optional-module-packaging'>Handling Optional Module Packaging</ulink>" section
- in the Yocto Project Development Manual.
+ in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -9854,7 +10053,7 @@
the recipe as a workaround.
For information on addressing race conditions, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#debugging-parallel-make-races'>Debugging Parallel Make Races</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</note>
For single socket systems (i.e. one CPU), you should not
have to override this variable to gain optimal parallelism
@@ -9903,7 +10102,8 @@
the recipe as a workaround.
For information on addressing race conditions, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#debugging-parallel-make-races'>Debugging Parallel Make Races</ulink>"
- section in the Yocto Project Development Manual.</para>
+ section in the Yocto Project Development Tasks Manual.
+ </para>
</note>
</para>
</glossdef>
@@ -10385,7 +10585,8 @@
cumbersome and error-prone, an automated solution exists.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-a-pr-service'>Working With a PR Service</ulink>"
- section for more information.
+ section in the Yocto Project Development Tasks Manual
+ for more information.
</para>
</glossdef>
</glossentry>
@@ -10409,6 +10610,8 @@
PREFERRED_PROVIDER_virtual/xserver = "xserver-xf86"
PREFERRED_PROVIDER_virtual/libgl ?= "mesa"
</literallayout>
+ For more information see:
+ <link linkend='metadata-virtual-providers'>Metadata (Virtual Providers)</link>
<note>
If you set <filename>PREFERRED_PROVIDER</filename>
for a <filename>virtual/*</filename> item, then any
@@ -10445,7 +10648,7 @@
Here are two examples:
<literallayout class='monospaced'>
PREFERRED_VERSION_python = "3.4.0"
- PREFERRED_VERSION_linux-yocto = "3.19%"
+ PREFERRED_VERSION_linux-yocto = "4.12%"
</literallayout>
<note>
The specified version is matched against
@@ -10480,14 +10683,14 @@
to set a machine-specific override.
Here is an example:
<literallayout class='monospaced'>
- PREFERRED_VERSION_linux-yocto_qemux86 = "3.4%"
+ PREFERRED_VERSION_linux-yocto_qemux86 = "4.12%"
</literallayout>
Although not recommended, worst case, you can also use the
"forcevariable" override, which is the strongest override
possible.
Here is an example:
<literallayout class='monospaced'>
- PREFERRED_VERSION_linux-yocto_forcevariable = "3.4%"
+ PREFERRED_VERSION_linux-yocto_forcevariable = "4.12%"
</literallayout>
<note>
The <filename>_forcevariable</filename> override is
@@ -10532,7 +10735,7 @@
build system to attempt before any others by adding
something like the following to the
<filename>local.conf</filename> configuration file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>:
+ <link linkend='build-directory'>Build Directory</link>:
<literallayout class='monospaced'>
PREMIRRORS_prepend = "\
git://.*/.* http://www.yoctoproject.org/sources/ \n \
@@ -10710,7 +10913,7 @@
<para>
The <filename>conf/local.conf.sample.extended</filename>
configuration file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
shows how the <filename>PRSERV_HOST</filename> variable is
set:
<literallayout class='monospaced'>
@@ -11494,7 +11697,7 @@
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
The location in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
where unpacked recipe source code resides.
By default, this directory is
<filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}/${</filename><link linkend='var-BPN'><filename>BPN</filename></link><filename>}-${</filename><link linkend='var-PV'><filename>PV</filename></link><filename>}</filename>,
@@ -11502,7 +11705,7 @@
and <filename>${PV}</filename> is the recipe version.
If the source tarball extracts the code to a directory
named anything other than <filename>${BPN}-${PV}</filename>,
- or if the source code if fetched from an SCM such as
+ or if the source code is fetched from an SCM such as
Git or Subversion, then you must set <filename>S</filename>
in the recipe so that the OpenEmbedded build system
knows where to find the unpacked source.
@@ -11510,7 +11713,7 @@
<para>
As an example, assume a
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
top-level folder named <filename>poky</filename> and a
default Build Directory at <filename>poky/build</filename>.
In this case, the work directory the build system uses
@@ -12412,7 +12615,7 @@
To enable file removal, set the variable to "1" in your
<filename>conf/local.conf</filename> configuration file
in your:
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
<literallayout class='monospaced'>
SKIP_FILEDEPS = "1"
</literallayout>
@@ -12619,7 +12822,7 @@
<listitem><para><emphasis><filename>file://</filename> -</emphasis>
Fetches files, which are usually files shipped with
the
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>,
+ <link linkend='metadata'>Metadata</link>,
from the local machine.
The path is relative to the
<link linkend='var-FILESPATH'><filename>FILESPATH</filename></link>
@@ -12819,7 +13022,7 @@
The <filename>SRCPV</filename> variable is defined in the
<filename>meta/conf/bitbake.conf</filename> configuration
file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
as follows:
<literallayout class='monospaced'>
SRCPV = "${@bb.fetch2.get_srcrev(d)}"
@@ -12863,7 +13066,8 @@
<link linkend='var-AUTOREV'><filename>AUTOREV</filename></link>
variable description and the
"<ulink url='&YOCTO_DOCS_DEV_URL;#automatically-incrementing-a-binary-package-revision-number'>Automatically Incrementing a Binary Package Revision Number</ulink>"
- section, which is in the Yocto Project Development Manual.
+ section, which is in the Yocto Project Development
+ Tasks Manual.
</note>
</para>
@@ -13116,7 +13320,8 @@
<link linkend='var-SYSROOT_DIRS'><filename>SYSROOT_DIRS</filename></link>
variable and the
"<ulink url='&YOCTO_DOCS_DEV_URL;#new-sharing-files-between-recipes'>Sharing Files Between Recipes</ulink>"
- section for more information.
+ section in the Yocto Project Development Tasks Manual
+ for more information.
<note>
Recipes should never write files directly under
the <filename>STAGING_DIR</filename> directory because
@@ -13583,15 +13788,12 @@
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
Points to the temporary directory under the work directory
(default
- <filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}/sysroot-destidir</filename>)
+ "<filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}/sysroot-destdir</filename>")
where the files
that will be populated into the sysroot are assembled
during the
<link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>
task.
- <literallayout class='monospaced'>
- SYSROOT_DESTDIR ?= "console=ttyS0,115200"
- </literallayout>
</para>
</glossdef>
</glossentry>
@@ -14026,7 +14228,7 @@
See the
<filename>meta/conf/machine/include/arm/feature-arm-thumb.inc</filename>
file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
for an example.
</para>
</glossdef>
@@ -14292,7 +14494,7 @@
The suffix identifies the <filename>libc</filename> variant
for building.
When you are building for multiple variants with the same
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>,
+ <link linkend='build-directory'>Build Directory</link>,
this mechanism ensures that output for different
<filename>libc</filename> variants is kept separate to
avoid potential conflicts.
@@ -14450,7 +14652,7 @@
<filename>ssh</filename>.
You can set this variable to "1" in your
<filename>local.conf</filename> file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
to have the OpenEmbedded build system automatically run
these tests after an image successfully builds:
<literallayout class='monospaced'>
@@ -14459,7 +14661,8 @@
For more information on enabling, running, and writing
these tests, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual and the
+ section in the Yocto Project Development Tasks Manual and
+ the
"<link linkend='ref-classes-testimage*'><filename>testimage*.bbclass</filename></link>"
section.
</para>
@@ -14543,7 +14746,7 @@
<para>
For more information on testing images, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -14650,8 +14853,8 @@
Boots a QEMU image and runs the tests.
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#qemu-image-enabling-tests'>Enabling Runtime Tests on QEMU</ulink>"
- section in the Yocto Project Development Manual for
- more information.
+ section in the Yocto Project Development Tasks
+ Manual for more information.
</para></listitem>
<listitem><para><emphasis>"simpleremote" and "SimpleRemoteTarget":</emphasis>
Runs the tests on target hardware that is already
@@ -14683,7 +14886,7 @@
<para>
For information on running tests on hardware, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#hardware-image-enabling-tests'>Enabling Runtime Tests on Hardware</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -14772,7 +14975,7 @@
<para>
For more information on testing images, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
</glossdef>
</glossentry>
@@ -14818,7 +15021,7 @@
files (other than the shared state cache).
By default, the <filename>TMPDIR</filename> variable points
to <filename>tmp</filename> within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
<para>
@@ -14826,7 +15029,7 @@
than the default, you can uncomment and edit the following
statement in the
<filename>conf/local.conf</filename> file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>:
+ <link linkend='source-directory'>Source Directory</link>:
<literallayout class='monospaced'>
#TMPDIR = "${TOPDIR}/tmp"
</literallayout>
@@ -14872,8 +15075,9 @@
variable, but you can add additional packages to the list.
See the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-adding-individual-packages'>Adding Individual Packages to the Standard SDK</ulink>"
- section in the Yocto Project Software Development Kit (SDK)
- Developer's Guide for more information.
+ section in the Yocto Project Application Development and
+ the Extensible Software Development Kit (eSDK) manual
+ for more information.
</para>
<para>
@@ -14883,7 +15087,8 @@
section.
For information on setting up a cross-development
environment, see the
- <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-manual'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
</para>
</glossdef>
</glossentry>
@@ -14929,8 +15134,9 @@
part of the SDK that runs on the target.
See the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-adding-individual-packages'>Adding Individual Packages to the Standard SDK</ulink>"
- section in the Yocto Project Software Development Kit (SDK)
- Developer's Guide for more information.
+ section in the Yocto Project Application Development and
+ the Extensible Software Development Kit (eSDK) manual for
+ more information.
</para>
<para>
@@ -14940,7 +15146,8 @@
section.
For information on setting up a cross-development
environment, see the
- <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-manual'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
</para>
</glossdef>
</glossentry>
@@ -14953,12 +15160,10 @@
<para role="glossdeffirst">
<!-- <para role="glossdeffirst"><imagedata fileref="figures/define-generic.png" /> -->
The top-level
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
BitBake automatically sets this variable when you
- initialize your build environment using either
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>.
+ initialize your build environment using
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>.
</para>
</glossdef>
</glossentry>
@@ -15010,7 +15215,7 @@
For example, the
<filename>meta/conf/machine/include/mips/README</filename>
file in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
provides information for <filename>TUNE_ARCH</filename>
specific to the <filename>mips</filename> architecture.
</para>
@@ -15293,7 +15498,7 @@
<para>
Known tuning conflicts are specified in the machine include
files in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
Here is an example from the
<filename>meta/conf/machine/include/mips/arch-mips.inc</filename>
include file that lists the "o32" and "n64" features as
@@ -15325,7 +15530,7 @@
<para>
See the machine include files in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
for these features.
</para>
</glossdef>
@@ -15662,7 +15867,7 @@
<para>
See the
"<ulink url='&YOCTO_DOCS_DEV_URL;#selecting-dev-manager'>Selecting a Device Manager</ulink>"
- section in the Yocto Project Development Manual for
+ section in the Yocto Project Development Tasks Manual for
information on how to use this variable.
</para>
</glossdef>
@@ -15717,7 +15922,7 @@
For more information, see
<filename>meta-poky/conf/local.conf.sample</filename> in
the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
</para>
</glossdef>
</glossentry>
@@ -16056,12 +16261,13 @@
kickstart file that is used by the OpenEmbedded build
system to create a partitioned image
(<replaceable>image</replaceable><filename>.wic</filename>).
- For information on how to create a
- partitioned image, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-wic-images-oe'>Creating Partitioned Images</ulink>"
- section.
+ For information on how to create a partitioned image, see
+ the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-partitioned-images-using-wic'>Creating Partitioned Images Using Wic</ulink>"
+ section in the Yocto Project Development Tasks Manual.
For details on the kickstart file format, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#openembedded-kickstart-wks-reference'>OpenEmbedded Kickstart (<filename>.wks</filename>) Reference</ulink>.
+ "<link linkend='openembedded-kickstart-wks-reference'>OpenEmbedded Kickstart (<filename>.wks</filename>) Reference</link>
+ Chapter.
</para>
</glossdef>
</glossentry>
diff --git a/import-layers/yocto-poky/documentation/ref-manual/resources.xml b/import-layers/yocto-poky/documentation/ref-manual/resources.xml
index 8299f9f..d59bea2 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/resources.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/resources.xml
@@ -3,25 +3,71 @@
[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
<chapter id='resources'>
-<title>Contributing to the Yocto Project</title>
+<title>Contributions and Additional Information</title>
<section id='resources-intro'>
<title>Introduction</title>
<para>
- The Yocto Project team is happy for people to experiment with the Yocto Project.
- A number of places exist to find help if you run into difficulties or find bugs.
- To find out how to download source code,
- see the "<ulink url='&YOCTO_DOCS_DEV_URL;#local-yp-release'>Yocto Project Release</ulink>"
- section in the Yocto Project Development Manual.
+ The Yocto Project team is happy for people to experiment with the
+ Yocto Project.
+ A number of places exist to find help if you run into difficulties
+ or find bugs.
+ This presents information about contributing and participating in
+ the Yocto Project.
+ </para>
+</section>
+
+<section id='resources-contributions'>
+ <title>Contributions</title>
+
+ <para>
+ The Yocto Project gladly accepts contributions.
+ You can submit changes to the project either by creating and sending
+ pull requests,
+ or by submitting patches through email.
+ For information on how to do both as well as information on how
+ to identify the maintainer for each area of code, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#how-to-submit-a-change'>Submitting a Change to the Yocto Project</ulink>"
+ section in the Yocto Project Development Tasks Manual.
</para>
</section>
<section id='resources-bugtracker'>
- <title>Tracking Bugs</title>
+ <title>Yocto Project Bugzilla</title>
<para>
- If you find problems with the Yocto Project, you should report them using the
- Bugzilla application at <ulink url='&YOCTO_BUGZILLA_URL;'></ulink>.
+ The Yocto Project uses its own implementation of
+ <ulink url='http://www.bugzilla.org/about/'>Bugzilla</ulink> to track
+ defects (bugs).
+ Implementations of Bugzilla work well for group development because
+ they track bugs and code changes, can be used to communicate changes
+ and problems with developers, can be used to submit and review patches,
+ and can be used to manage quality assurance.
+ </para>
+
+ <para>
+ Sometimes it is helpful to submit, investigate, or track a bug against
+ the Yocto Project itself (e.g. when discovering an issue with some
+ component of the build system that acts contrary to the documentation
+ or your expectations).
+ </para>
+
+ <para>
+ A general procedure and guidelines exist for when you use Bugzilla to
+ submit a bug.
+ For information on how to use Bugzilla to submit a bug against the
+ Yocto Project, see the following:
+ <itemizedlist>
+ <listitem><para>
+ The
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#submitting-a-defect-against-the-yocto-project'>Submitting a Defect Against the Yocto Project</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ </para></listitem>
+ <listitem><para>
+ The Yocto Project
+ <ulink url='&YOCTO_WIKI_URL;/wiki/Bugzilla_Configuration_and_Bug_Tracking'>Bugzilla wiki page</ulink>
+ </para></listitem>
+ </itemizedlist>
</para>
</section>
@@ -43,19 +89,19 @@
Discussion mailing list about OpenEmbedded.</para></listitem>
<listitem><para><ulink url='&OE_LISTS_URL;/listinfo/bitbake-devel'></ulink> -
Discussion mailing list about the
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>
+ <link linkend='bitbake-term'>BitBake</link>
build tool.</para></listitem>
<listitem><para><ulink url='&YOCTO_LISTS_URL;/listinfo/poky'></ulink> -
Discussion mailing list about
- <ulink url='&YOCTO_DOCS_DEV_URL;#poky'>Poky</ulink>.
+ <link linkend='poky'>Poky</link>.
</para></listitem>
<listitem><para><ulink url='&YOCTO_LISTS_URL;/listinfo/yocto-announce'></ulink> -
Mailing list to receive official Yocto Project release and milestone
announcements.</para></listitem>
</itemizedlist>
</para>
- For more Yocto Project-related mailing lists, see the Yocto Project community mailing lists page
- <ulink url='&YOCTO_HOME_URL;/tools-resources/community/mailing-lists'>here</ulink>.
+ For more Yocto Project-related mailing lists, see the
+ <ulink url='&YOCTO_HOME_URL;'>Yocto Project Website</ulink>.
</section>
<section id='resources-irc'>
@@ -70,53 +116,160 @@
</para>
</section>
-<section id='resources-links'>
- <title>Links</title>
+<section id='resources-links-and-related-documentation'>
+ <title>Links and Related Documentation</title>
<para>
- Here is a list of resources you will find helpful:
+ Here is a list of resources you might find helpful:
<itemizedlist>
- <listitem><para><emphasis>
+ <listitem><para>
+ <emphasis>
<ulink url='&YOCTO_HOME_URL;'>The Yocto Project website</ulink>:
- </emphasis> The home site for the Yocto
- Project.</para></listitem>
-<!--
- <listitem><para><emphasis>
- <ulink url='http://www.intel.com/'>Intel Corporation</ulink>:</emphasis>
- The company that acquired OpenedHand in 2008 and began
- development on the Yocto Project.</para></listitem>
--->
- <listitem><para><emphasis>
- <ulink url='&OE_HOME_URL;'>OpenEmbedded</ulink>:</emphasis>
- The upstream, generic, embedded distribution used as the basis
- for the build system in the Yocto Project.
- Poky derives from and contributes back to the OpenEmbedded
- project.</para></listitem>
- <listitem><para><emphasis>
+ </emphasis> The home site for the Yocto Project.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_WIKI_URL;/wiki/Main_Page'>The Yocto Project Main Wiki Page</ulink>:
+ </emphasis>
+ The main wiki page for the Yocto Project.
+ This page contains information about project planning,
+ release engineering, QA & automation, a reference
+ site map, and other resources related to the Yocto Project.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&OE_HOME_URL;'>OpenEmbedded</ulink>:
+ </emphasis>
+ The build system used by the Yocto Project.
+ This project is the upstream, generic, embedded distribution
+ from which the Yocto Project derives its build system (Poky)
+ and to which it contributes.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
<ulink url='http://www.openembedded.org/wiki/BitBake'>
- BitBake</ulink>:</emphasis> The tool used to process metadata.</para></listitem>
+ BitBake</ulink>:
+ </emphasis> The tool used to process metadata.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_BB_URL;'>BitBake User Manual:</ulink>
+ </emphasis>
+ A comprehensive guide to the BitBake tool.
+ If you want information on BitBake, see this manual.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_QS_URL;'>Yocto Project Quick Start</ulink>:
+ </emphasis>
+ This short document lets you get started
+ with the Yocto Project and quickly begin building an image.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_DEV_URL;'>Yocto Project Development Tasks Manual</ulink>:
+ </emphasis>
+ This manual is a "how-to" guide that presents procedures
+ useful to both application and system developers who use the
+ Yocto Project.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual:</emphasis>
+ This guide provides information that lets you get going
+ with the standard or extensible SDK.
+ An SDK, with its cross-development toolchains, allows you
+ to develop projects inside or outside of the Yocto Project
+ environment.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_BSP_URL;'>Yocto Project Board Support Package (BSP) Developer's Guide</ulink>:
+ </emphasis>
+ This guide defines the structure for BSP components.
+ Having a commonly understood structure encourages
+ standardization.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;'>Yocto Project Linux Kernel Development Manual</ulink>:
+ </emphasis>
+ This manual describes how to work with Linux Yocto kernels as
+ well as provides a bit of conceptual information on the
+ construction of the Yocto Linux kernel tree.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_PROF_URL;'>Yocto Project Profiling and Tracing Manual</ulink>:
+ </emphasis>
+ This manual presents a set of common and generally useful
+ tracing and profiling schemes along with their applications
+ (as appropriate) to each tool.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-appendix-latest-yp-eclipse-plug-in'>Eclipse IDE Yocto Plug-in</ulink>:
+ </emphasis>
+ Instructions that demonstrate how an application developer
+ uses the Eclipse Yocto Project Plug-in feature within
+ the Eclipse IDE.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_WIKI_URL;/wiki/FAQ'>FAQ</ulink>:
+ </emphasis>
+ A list of commonly asked questions and their answers.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_RELEASE_NOTES;'>Release Notes</ulink>:
+ </emphasis>
+ Features, updates and known issues for the current
+ release of the Yocto Project.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_DOCS_TOAST_URL;'>Toaster User Manual</ulink>:
+ </emphasis>
+ This manual introduces and describes how to set up and use
+ Toaster.
+ Toaster is an Application Programming Interface (API) and
+ web-based interface to the
+ <link linkend='build-system-term'>OpenEmbedded Build System</link>,
+ which uses BitBake, that reports build information.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_BUGZILLA_URL;'>Bugzilla</ulink>:
+ </emphasis>
+ The bug tracking application the Yocto Project uses.
+ If you find problems with the Yocto Project, you should report
+ them using this application.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='&YOCTO_WIKI_URL;/wiki/Bugzilla_Configuration_and_Bug_Tracking'>Bugzilla Configuration and Bug Tracking Wiki Page</ulink>:
+ </emphasis>
+ Information on how to get set up and use the Yocto Project
+ implementation of Bugzilla for logging and tracking Yocto
+ Project defects.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>Internet Relay Chat (IRC):</emphasis>
+ Two IRC channels on freenode are available
+ for Yocto Project and Poky discussions: <filename>#yocto</filename> and
+ <filename>#poky</filename>, respectively.
+ </para></listitem>
+ <listitem><para>
+ <emphasis>
+ <ulink url='http://wiki.qemu.org/Index.html'>Quick EMUlator (QEMU)</ulink>:
+ </emphasis>
+ An open-source machine emulator and virtualizer.
+ </para></listitem>
</itemizedlist>
- For more links, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#other-information'>Other Information</ulink>"
- section in the Yocto Project Development Manual.
</para>
</section>
-
-<section id='resources-contributions'>
- <title>Contributions</title>
-
- <para>
- The Yocto Project gladly accepts contributions.
- You can submit changes to the project either by creating and sending
- pull requests,
- or by submitting patches through email.
- For information on how to do both as well as information on how
- to identify the maintainer for each area of code, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#how-to-submit-a-change'>How to Submit a Change</ulink>"
- section in the Yocto Project Development Manual.
- </para>
-</section>
-
</chapter>
<!--
vim: expandtab tw=80 ts=4
diff --git a/import-layers/yocto-poky/documentation/ref-manual/technical-details.xml b/import-layers/yocto-poky/documentation/ref-manual/technical-details.xml
index 1964a9a..e9e76e4 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/technical-details.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/technical-details.xml
@@ -18,7 +18,7 @@
<para>
The
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink>
+ <link linkend='bitbake-term'>BitBake</link>
task executor together with various types of configuration files form
the OpenEmbedded Core.
This section overviews these components by describing their use and
@@ -48,15 +48,16 @@
to each data source as a layer.
For information on layers, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#understanding-and-creating-layers'>Understanding and
- Creating Layers</ulink>" section of the Yocto Project Development Manual.
+ Creating Layers</ulink>" section of the Yocto Project Development
+ Tasks Manual.
</para>
<para>
Following are some brief details on these core components.
For additional information on how these components interact during
a build, see the
- "<link linkend='closer-look'>A Closer Look at the Yocto Project Development Environment</link>"
- Chapter.
+ "<link linkend='development-concepts'>Development Concepts</link>"
+ section.
</para>
<section id='usingpoky-components-bitbake'>
@@ -65,7 +66,7 @@
<para>
BitBake is the tool at the heart of the OpenEmbedded build system
and is responsible for parsing the
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>,
+ <link linkend='metadata'>Metadata</link>,
generating a list of tasks from it, and then executing those tasks.
</para>
@@ -146,13 +147,70 @@
</para>
</section>
+ <section id='metadata-virtual-providers'>
+ <title>Metadata (Virtual Providers)</title>
+
+ <para>
+ Prior to the build, if you know that several different recipes
+ provide the same functionality, you can use a virtual provider
+ (i.e. <filename>virtual/*</filename>) as a placeholder for the
+ actual provider.
+ The actual provider would be determined at build
+ time.
+ In this case, you should add <filename>virtual/*</filename>
+ to <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>,
+ rather than listing the specified provider.
+ You would select the actual provider by setting the
+ <link linkend='var-PREFERRED_PROVIDER'><filename>PREFERRED_PROVIDER</filename></link>
+ variable (i.e. <filename>PREFERRED_PROVIDER_virtual/*</filename>)
+ in the build's configuration file (e.g.
+ <filename>poky/build/conf/local.conf</filename>).
+ <note>
+ Any recipe that PROVIDES a <filename>virtual/*</filename> item
+ that is ultimately not selected through
+ <filename>PREFERRED_PROVIDER</filename> does not get built.
+ Preventing these recipes from building is usually the desired
+ behavior since this mechanism's purpose is to select between
+ mutually exclusive alternative providers.
+ </note>
+ </para>
+
+ <para>
+ The following lists specific examples of virtual providers:
+ <itemizedlist>
+ <listitem><para>
+ <filename>virtual/mesa</filename>:
+ Provides <filename>gbm.pc</filename>.
+ </para></listitem>
+ <listitem><para>
+ <filename>virtual/egl</filename>:
+ Provides <filename>egl.pc</filename> and possibly
+ <filename>wayland-egl.pc</filename>.
+ </para></listitem>
+ <listitem><para>
+ <filename>virtual/libgl</filename>:
+ Provides <filename>gl.pc</filename> (i.e. libGL).
+ </para></listitem>
+ <listitem><para>
+ <filename>virtual/libgles1</filename>:
+ Provides <filename>glesv1_cm.pc</filename>
+ (i.e. libGLESv1_CM).
+ </para></listitem>
+ <listitem><para>
+ <filename>virtual/libgles2</filename>:
+ Provides <filename>glesv2.pc</filename> (i.e. libGLESv2).
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
<section id='usingpoky-components-classes'>
<title>Classes</title>
<para>
Class files (<filename>.bbclass</filename>) contain information that
is useful to share between
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink> files.
+ <link linkend='metadata'>Metadata</link> files.
An example is the
<link linkend='ref-classes-autotools'><filename>autotools</filename></link>
class, which contains common settings for any application that
@@ -172,7 +230,7 @@
distribution configuration options, compiler tuning options, general common configuration
options, and user configuration options in <filename>local.conf</filename>, which is found
in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
</para>
</section>
</section>
@@ -183,11 +241,12 @@
<para>
The Yocto Project does most of the work for you when it comes to
creating
- <ulink url='&YOCTO_DOCS_DEV_URL;#cross-development-toolchain'>cross-development toolchains</ulink>.
+ <link linkend='cross-development-toolchain'>cross-development toolchains</link>.
This section provides some technical background on how
cross-development toolchains are created and used.
For more information on toolchains, you can also see the
- <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
</para>
<para>
@@ -372,8 +431,8 @@
For information on advantages gained when building a
cross-development toolchain installer, see the
"<ulink url='&YOCTO_DOCS_SDK_URL;#sdk-building-an-sdk-installer'>Building an SDK Installer</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's
- Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</note>
</section>
@@ -433,7 +492,7 @@
works with packages and can
track incrementing <filename>PR</filename> information, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#automatically-incrementing-a-binary-package-revision-number'>Automatically Incrementing a Binary Package Revision Number</ulink>"
- section.
+ section in the Yocto Project Development Tasks Manual.
</note>
<para>
@@ -562,7 +621,7 @@
code.
However, there is still the question of a task's indirect inputs - the
things that were already built and present in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ <link linkend='build-directory'>Build Directory</link>.
The checksum (or signature) for a particular task needs to add the hashes
of all the tasks on which the particular task depends.
Choosing which dependencies to add is a policy decision.
@@ -598,11 +657,12 @@
The code in <filename>meta/lib/oe/sstatesig.py</filename> shows two examples
of this and also illustrates how you can insert your own policy into the system
if so desired.
- This file defines the two basic signature generators <filename>OE-Core</filename>
- uses: "OEBasic" and "OEBasicHash".
+ This file defines the two basic signature generators
+ <link linkend='oe-core'>OE-Core</link> uses: "OEBasic" and
+ "OEBasicHash".
By default, there is a dummy "noop" signature handler enabled in BitBake.
This means that behavior is unchanged from previous versions.
- <filename>OE-Core</filename> uses the "OEBasicHash" signature handler by default
+ OE-Core uses the "OEBasicHash" signature handler by default
through this setting in the <filename>bitbake.conf</filename> file:
<literallayout class='monospaced'>
BB_SIGNATURE_HANDLER ?= "OEBasicHash"
@@ -610,7 +670,7 @@
The "OEBasicHash" <filename>BB_SIGNATURE_HANDLER</filename> is the same as the
"OEBasic" version but adds the task hash to the stamp files.
This results in any
- <ulink url='&YOCTO_DOCS_DEV_URL;#metadata'>Metadata</ulink>
+ <link linkend='metadata'>Metadata</link>
change that changes the task hash, automatically
causing the task to be run again.
This removes the need to bump <link linkend='var-PR'><filename>PR</filename></link>
@@ -1195,6 +1255,213 @@
</para>
</section>
+<section id='wic-plug-ins-interface'>
+ <title>Wic Plug-Ins Interface</title>
+
+ <para>
+ You can extend and specialize Wic functionality by using
+ Wic plug-ins.
+ This section explains the Wic plug-in interface.
+ For information on using Wic in general, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-partitioned-images-using-wic'>Creating Partitioned Images Using Wic</ulink>"
+ section in the Yocto Project Development Tasks Manual.
+ <note>
+ Wic plug-ins consist of "source" and "imager" plug-ins.
+ Imager plug-ins are beyond the scope of this section.
+ </note>
+ </para>
+
+ <para>
+ Source plug-ins provide a mechanism to customize partition
+ content during the Wic image generation process.
+ You can use source plug-ins to map values that you specify
+ using <filename>--source</filename> commands in kickstart
+ files (i.e. <filename>*.wks</filename>) to a plug-in
+ implementation used to populate a given partition.
+ <note>
+ If you use plug-ins that have build-time dependencies
+ (e.g. native tools, bootloaders, and so forth)
+ when building a Wic image, you need to specify those
+ dependencies using the
+ <link linkend='var-WKS_FILE_DEPENDS'><filename>WKS_FILE_DEPENDS</filename></link>
+ variable.
+ </note>
+ </para>
+
+ <para>
+ Source plug-ins are subclasses defined in plug-in files.
+ As shipped, the Yocto Project provides several plug-in
+ files.
+ You can see the source plug-in files that ship with the
+ Yocto Project
+ <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi/poky/tree/scripts/lib/wic/plugins/source'>here</ulink>.
+ Each of these plug-in files contain source plug-ins that
+ are designed to populate a specific Wic image partition.
+ </para>
+
+ <para>
+ Source plug-ins are subclasses of the
+ <filename>SourcePlugin</filename> class, which is
+ defined in the
+ <filename>poky/scripts/lib/wic/pluginbase.py</filename>
+ file.
+ For example, the <filename>BootimgEFIPlugin</filename>
+ source plug-in found in the
+ <filename>bootimg-efi.py</filename> file is a subclass of
+ the <filename>SourcePlugin</filename> class, which is found
+ in the <filename>pluginbase.py</filename> file.
+ </para>
+
+ <para>
+ You can also implement source plug-ins in a layer outside
+ of the Source Repositories (external layer).
+ To do so, be sure that your plug-in files are located in
+ a directory whose path is
+ <filename>scripts/lib/wic/plugins/source/</filename>
+ within your external layer.
+ When the plug-in files are located there, the source
+ plug-ins they contain are made available to Wic.
+ </para>
+
+ <para>
+ When the Wic implementation needs to invoke a
+ partition-specific implementation, it looks for the plug-in
+ with the same name as the <filename>--source</filename>
+ parameter used in the kickstart file given to that
+ partition.
+ For example, if the partition is set up using the following
+ command in a kickstart file:
+ <literallayout class='monospaced'>
+ part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024
+ </literallayout>
+ The methods defined as class members of the matching
+ source plug-in (i.e. <filename>bootimg-pcbios</filename>)
+ in the <filename>bootimg-pcbios.py</filename> plug-in file
+ are used.
+ </para>
+
+ <para>
+ To be more concrete, here is the corresponding plug-in
+ definition from the <filename>bootimg-pcbios.py</filename>
+ file for the previous command along with an example
+ method called by the Wic implementation when it needs to
+ prepare a partition using an implementation-specific
+ function:
+ <literallayout class='monospaced'>
+ bootimg-pcbios.py
+ .
+ .
+ .
+ class BootimgPcbiosPlugin(SourcePlugin):
+ """
+ Create MBR boot partition and install syslinux on it.
+ """
+
+ name = 'bootimg-pcbios'
+ .
+ .
+ .
+ @classmethod
+ def do_prepare_partition(cls, part, source_params, creator, cr_workdir,
+ oe_builddir, bootimg_dir, kernel_dir,
+ rootfs_dir, native_sysroot):
+ """
+ Called to do the actual content population for a partition i.e. it
+ 'prepares' the partition to be incorporated into the image.
+ In this case, prepare content for legacy bios boot partition.
+ """
+ .
+ .
+ .
+ </literallayout>
+ If a subclass (plug-in) itself does not implement a
+ particular function, Wic locates and uses the default
+ version in the superclass.
+ It is for this reason that all source plug-ins are derived
+ from the <filename>SourcePlugin</filename> class.
+ </para>
+
+ <para>
+ The <filename>SourcePlugin</filename> class defined in
+ the <filename>pluginbase.py</filename> file defines
+ a set of methods that source plug-ins can implement or
+ override.
+ Any plug-ins (subclass of
+ <filename>SourcePlugin</filename>) that do not implement
+ a particular method inherit the implementation of the
+ method from the <filename>SourcePlugin</filename> class.
+ For more information, see the
+ <filename>SourcePlugin</filename> class in the
+ <filename>pluginbase.py</filename> file for details:
+ </para>
+
+ <para>
+ The following list describes the methods implemented in the
+ <filename>SourcePlugin</filename> class:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><filename>do_prepare_partition()</filename>:</emphasis>
+ Called to populate a partition with actual content.
+ In other words, the method prepares the final
+ partition image that is incorporated into the
+ disk image.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>do_configure_partition()</filename>:</emphasis>
+ Called before
+ <filename>do_prepare_partition()</filename> to
+ create custom configuration files for a partition
+ (e.g. syslinux or grub configuration files).
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>do_install_disk()</filename>:</emphasis>
+ Called after all partitions have been prepared and
+ assembled into a disk image.
+ This method provides a hook to allow finalization
+ of a disk image (e.g. writing an MBR).
+ </para></listitem>
+ <listitem><para>
+ <emphasis><filename>do_stage_partition()</filename>:</emphasis>
+ Special content-staging hook called before
+ <filename>do_prepare_partition()</filename>.
+ This method is normally empty.</para>
+
+ <para>Typically, a partition just uses the passed-in
+ parameters (e.g. the unmodified value of
+ <filename>bootimg_dir</filename>).
+ However, in some cases, things might need to be
+ more tailored.
+ As an example, certain files might additionally
+ need to be taken from
+ <filename>bootimg_dir + /boot</filename>.
+ This hook allows those files to be staged in a
+ customized fashion.
+ <note>
+ <filename>get_bitbake_var()</filename>
+ allows you to access non-standard variables
+ that you might want to use for this
+ behavior.
+ </note>
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ You can extend the source plug-in mechanism.
+ To add more hooks, create more source plug-in methods
+ within <filename>SourcePlugin</filename> and the
+ corresponding derived subclasses.
+ The code that calls the plug-in methods uses the
+ <filename>plugin.get_source_plugin_methods()</filename>
+ function to find the method or methods needed by the call.
+ Retrieval of those methods is accomplished by filling up
+ a dict with keys that contain the method names of interest.
+ On success, these will be filled in with the actual
+ methods.
+ See the Wic implementation for examples and details.
+ </para>
+</section>
+
<section id='x32'>
<title>x32</title>
@@ -1310,7 +1577,7 @@
The Wayland protocol libraries and the reference Weston compositor
ship as integrated packages in the <filename>meta</filename> layer
of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
Specifically, you can find the recipes that build both Wayland
and Weston at <filename>meta/recipes-graphics/wayland</filename>.
</para>
@@ -1425,8 +1692,8 @@
<para>
For information that can help you maintain compliance with various open
source licensing during the lifecycle of the product, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Project's Lifecycle</ulink>" section
- in the Yocto Project Development Manual.
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Project's Lifecycle</ulink>"
+ section in the Yocto Project Development Tasks Manual.
</para>
<section id="usingpoky-configuring-LIC_FILES_CHKSUM">
diff --git a/import-layers/yocto-poky/documentation/ref-manual/usingpoky.xml b/import-layers/yocto-poky/documentation/ref-manual/usingpoky.xml
index d080316..13d9ad6 100644
--- a/import-layers/yocto-poky/documentation/ref-manual/usingpoky.xml
+++ b/import-layers/yocto-poky/documentation/ref-manual/usingpoky.xml
@@ -42,11 +42,9 @@
<para>
The first thing you need to do is set up the OpenEmbedded build
- environment by sourcing an environment setup script
+ environment by sourcing the environment setup script
(i.e.
- <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>
- or
- <link linkend='structure-memres-core-script'><filename>oe-init-build-env-memres</filename></link>).
+ <link linkend='structure-core-script'><filename>&OE_INIT_FILE;</filename></link>).
Here is an example:
<literallayout class='monospaced'>
$ source &OE_INIT_FILE; [<replaceable>build_dir</replaceable>]
@@ -56,7 +54,8 @@
<para>
The <replaceable>build_dir</replaceable> argument is optional and specifies the directory the
OpenEmbedded build system uses for the build -
- the <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>.
+ the
+ <link linkend='build-directory'>Build Directory</link>.
If you do not specify a Build Directory, it defaults to a directory
named <filename>build</filename> in your current working directory.
A common practice is to use a different Build Directory for different targets.
@@ -108,7 +107,7 @@
The <replaceable>target</replaceable> is the name of the recipe you want to build.
Common targets are the images in <filename>meta/recipes-core/images</filename>,
<filename>meta/recipes-sato/images</filename>, etc. all found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>.
+ <link linkend='source-directory'>Source Directory</link>.
Or, the target can be the name of a recipe for a specific piece of software such as
BusyBox.
For more details about the images the OpenEmbedded build system supports, see the
@@ -142,11 +141,12 @@
<para>
Once an image has been built, it often needs to be installed.
The images and kernels built by the OpenEmbedded build system are placed in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink> in
+ <link linkend='build-directory'>Build Directory</link> in
<filename class="directory">tmp/deploy/images</filename>.
For information on how to run pre-built images such as <filename>qemux86</filename>
and <filename>qemuarm</filename>, see the
- <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-manual'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
+ <ulink url='&YOCTO_DOCS_SDK_URL;'>Yocto Project Application Development and the Extensible Software Development Kit (eSDK)</ulink>
+ manual.
For information about how to install these images, see the documentation for your
particular board or machine.
</para>
@@ -177,16 +177,17 @@
going wrong.
For information on how to enable and use this feature, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#using-the-error-reporting-tool'>Using the Error Reporting Tool</ulink>"
- section in the Yocto Project Development Manual.
+ section in the Yocto Project Development Tasks Manual.
</para>
<para>
For discussions on debugging, see the
"<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-gdb-remotedebug'>Debugging With the GNU Project Debugger (GDB) Remotely</ulink>" section
- in the Yocto Project Developer's Manual
+ in the Yocto Project Development Tasks Manual
and the
"<ulink url='&YOCTO_DOCS_SDK_URL;#adt-eclipse'>Working within Eclipse</ulink>"
- section in the Yocto Project Software Development Kit (SDK) Developer's Guide.
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
</para>
<note>
@@ -208,7 +209,7 @@
(<filename>qemux86</filename>) might be in
<filename>tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/temp/log.do_compile</filename>.
To see the commands
- <ulink url='&YOCTO_DOCS_DEV_URL;#bitbake-term'>BitBake</ulink> ran
+ <link linkend='bitbake-term'>BitBake</link> ran
to generate a log, look at the corresponding
<filename>run.do_</filename><replaceable>taskname</replaceable>
file in the same directory.
@@ -874,7 +875,7 @@
class implements these functions.
See that class in the
<filename>meta/classes</filename> folder of the
- <ulink url='&YOCTO_DOCS_DEV_URL;#source-directory'>Source Directory</ulink>
+ <link linkend='source-directory'>Source Directory</link>
for information.
</para>
@@ -978,7 +979,7 @@
Removing
<link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
(usually <filename>tmp/</filename>, within the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>)
+ <link linkend='build-directory'>Build Directory</link>)
can often fix temporary build issues.
Removing <filename>TMPDIR</filename> is usually a
relatively cheap operation, because task output will be
@@ -1031,9 +1032,12 @@
the Yocto Project implementation of
<ulink url='https://bugzilla.yoctoproject.org/'>Bugzilla</ulink>.
For general information on how to submit a bug against
- the Yocto Project, see the
- "<ulink url='&YOCTO_DOCS_DEV_URL;#tracking-bugs'>Tracking Bugs</ulink>"
- section in the Yocto Project Development Manual.
+ the Yocto Project, see the Yocto Project Bugzilla
+ <ulink url='&YOCTO_WIKI_URL;/wiki/Bugzilla_Configuration_and_Bug_Tracking'>wiki page</ulink>"
+ or the
+ <ulink url='&YOCTO_DOCS_DEV_URL;#submitting-a-defect-against-the-yocto-project'>Submitting a Defect Against the Yocto Project</ulink>"
+ section, which is in the Yocto Project Development Tasks
+ Manual.
<note>
The manuals might not be the right place to document
variables that are purely internal and have a limited
@@ -1046,6 +1050,376 @@
</section>
</section>
+<section id='ref-quick-emulator-qemu'>
+ <title>Quick EMUlator (QEMU)</title>
+
+ <para>
+ The Yocto Project uses an implementation of the Quick EMUlator (QEMU)
+ Open Source project as part of the Yocto Project development "tool
+ set".
+ </para>
+
+ <para>
+ Within the context of the Yocto Project, QEMU is an
+ emulator and virtualization machine that allows you to run a complete
+ image you have built using the Yocto Project as just another task
+ on your build system.
+ QEMU is useful for running and testing images and applications on
+ supported Yocto Project architectures without having actual hardware.
+ Among other things, the Yocto Project uses QEMU to run automated
+ Quality Assurance (QA) tests on final images shipped with each
+ release.
+ <note>
+ This implementation is not the same as QEMU in general.
+ </note>
+ This section provides a brief reference for the Yocto Project
+ implementation of QEMU.
+ </para>
+
+ <para>
+ For official information and documentation on QEMU in general, see the
+ following references:
+ <itemizedlist>
+ <listitem><para>
+ <emphasis><ulink url='http://wiki.qemu.org/Main_Page'>QEMU Website</ulink>:</emphasis>
+ The official website for the QEMU Open Source project.
+ </para></listitem>
+ <listitem><para>
+ <emphasis><ulink url='http://wiki.qemu.org/Manual'>Documentation</ulink>:</emphasis>
+ The QEMU user manual.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>
+ For information on how to use the Yocto Project implementation of
+ QEMU, see the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#dev-manual-qemu'>Using the Quick EMUlator (QEMU)</ulink>"
+ chapter in the Yocto Project Development Tasks Manual.
+ </para>
+
+ <section id='qemu-availability'>
+ <title>QEMU Availability</title>
+
+ <para>
+ QEMU is made available with the Yocto Project a number of ways.
+ One method is to install a Software Development Kit (SDK).
+ For more information on how to make sure you have
+ QEMU available, see
+ "<ulink url='&YOCTO_DOCS_SDK_URL;#the-qemu-emulator'>The QEMU Emulator</ulink>"
+ section in the Yocto Project Application Development and the
+ Extensible Software Development Kit (eSDK) manual.
+ </para>
+ </section>
+
+ <section id='qemu-performance'>
+ <title>QEMU Performance</title>
+
+ <para>
+ Using QEMU to emulate your hardware can result in speed issues
+ depending on the target and host architecture mix.
+ For example, using the <filename>qemux86</filename> image in the
+ emulator on an Intel-based 32-bit (x86) host machine is fast
+ because the target and host architectures match.
+ On the other hand, using the <filename>qemuarm</filename> image
+ on the same Intel-based host can be slower.
+ But, you still achieve faithful emulation of ARM-specific issues.
+ </para>
+
+ <para>
+ To speed things up, the QEMU images support using
+ <filename>distcc</filename> to call a cross-compiler outside the
+ emulated system.
+ If you used <filename>runqemu</filename> to start QEMU, and the
+ <filename>distccd</filename> application is present on the host
+ system, any BitBake cross-compiling toolchain available from the
+ build system is automatically used from within QEMU simply by
+ calling <filename>distcc</filename>.
+ You can accomplish this by defining the cross-compiler variable
+ (e.g. <filename>export CC="distcc"</filename>).
+ Alternatively, if you are using a suitable SDK image or the
+ appropriate stand-alone toolchain is present, the toolchain is
+ also automatically used.
+ </para>
+
+ <note>
+ Several mechanisms exist that let you connect to the system
+ running on the QEMU emulator:
+ <itemizedlist>
+ <listitem><para>
+ QEMU provides a framebuffer interface that makes standard
+ consoles available.
+ </para></listitem>
+ <listitem><para>
+ Generally, headless embedded devices have a serial port.
+ If so, you can configure the operating system of the
+ running image to use that port to run a console.
+ The connection uses standard IP networking.
+ </para></listitem>
+ <listitem><para>
+ SSH servers exist in some QEMU images.
+ The <filename>core-image-sato</filename> QEMU image has a
+ Dropbear secure shell (SSH) server that runs with the root
+ password disabled.
+ The <filename>core-image-full-cmdline</filename> and
+ <filename>core-image-lsb</filename> QEMU images
+ have OpenSSH instead of Dropbear.
+ Including these SSH servers allow you to use standard
+ <filename>ssh</filename> and <filename>scp</filename>
+ commands.
+ The <filename>core-image-minimal</filename> QEMU image,
+ however, contains no SSH server.
+ </para></listitem>
+ <listitem><para>
+ You can use a provided, user-space NFS server to boot
+ the QEMU session using a local copy of the root
+ filesystem on the host.
+ In order to make this connection, you must extract a
+ root filesystem tarball by using the
+ <filename>runqemu-extract-sdk</filename> command.
+ After running the command, you must then point the
+ <filename>runqemu</filename>
+ script to the extracted directory instead of a root
+ filesystem image file.
+ See the
+ "<ulink url='&YOCTO_DOCS_DEV_URL;#qemu-running-under-a-network-file-system-nfs-server'>Running Under a Network File System (NFS) Server</ulink>"
+ section in the Yocto Project Development Tasks Manual for
+ more information.
+ </para></listitem>
+ </itemizedlist>
+ </note>
+ </section>
+
+ <section id='qemu-command-line-syntax'>
+ <title>QEMU Command-Line Syntax</title>
+
+ <para>
+ The basic <filename>runqemu</filename> command syntax is as
+ follows:
+ <literallayout class='monospaced'>
+ $ runqemu [<replaceable>option</replaceable> ] [...]
+ </literallayout>
+ Based on what you provide on the command line,
+ <filename>runqemu</filename> does a good job of figuring out what
+ you are trying to do.
+ For example, by default, QEMU looks for the most recently built
+ image according to the timestamp when it needs to look for an
+ image.
+ Minimally, through the use of options, you must provide either
+ a machine name, a virtual machine image
+ (<filename>*wic.vmdk</filename>), or a kernel image
+ (<filename>*.bin</filename>).
+ </para>
+
+ <para>
+ Following is the command-line help output for the
+ <filename>runqemu</filename> command:
+ <literallayout class='monospaced'>
+ $ runqemu --help
+
+ Usage: you can run this script with any valid combination
+ of the following environment variables (in any order):
+ KERNEL - the kernel image file to use
+ ROOTFS - the rootfs image file or nfsroot directory to use
+ MACHINE - the machine name (optional, autodetected from KERNEL filename if unspecified)
+ Simplified QEMU command-line options can be passed with:
+ nographic - disable video console
+ serial - enable a serial console on /dev/ttyS0
+ slirp - enable user networking, no root privileges is required
+ kvm - enable KVM when running x86/x86_64 (VT-capable CPU required)
+ kvm-vhost - enable KVM with vhost when running x86/x86_64 (VT-capable CPU required)
+ publicvnc - enable a VNC server open to all hosts
+ audio - enable audio
+ [*/]ovmf* - OVMF firmware file or base name for booting with UEFI
+ tcpserial=<port> - specify tcp serial port number
+ biosdir=<dir> - specify custom bios dir
+ biosfilename=<filename> - specify bios filename
+ qemuparams=<xyz> - specify custom parameters to QEMU
+ bootparams=<xyz> - specify custom kernel parameters during boot
+ help, -h, --help: print this text
+
+ Examples:
+ runqemu
+ runqemu qemuarm
+ runqemu tmp/deploy/images/qemuarm
+ runqemu tmp/deploy/images/qemux86/<qemuboot.conf>
+ runqemu qemux86-64 core-image-sato ext4
+ runqemu qemux86-64 wic-image-minimal wic
+ runqemu path/to/bzImage-qemux86.bin path/to/nfsrootdir/ serial
+ runqemu qemux86 iso/hddimg/wic.vmdk/wic.qcow2/wic.vdi/ramfs/cpio.gz...
+ runqemu qemux86 qemuparams="-m 256"
+ runqemu qemux86 bootparams="psplash=false"
+ runqemu path/to/<image>-<machine>.wic
+ runqemu path/to/<image>-<machine>.wic.vmdk
+ </literallayout>
+ </para>
+ </section>
+
+ <section id='runqemu-command-line-options'>
+ <title><filename>runqemu</filename> Command-Line Options</title>
+
+ <para>
+ Following is a description of <filename>runqemu</filename>
+ options you can provide on the command line:
+ <note><title>Tip</title>
+ If you do provide some "illegal" option combination or perhaps
+ you do not provide enough in the way of options,
+ <filename>runqemu</filename> provides appropriate error
+ messaging to help you correct the problem.
+ </note>
+ <itemizedlist>
+ <listitem><para>
+ <replaceable>QEMUARCH</replaceable>:
+ The QEMU machine architecture, which must be "qemuarm",
+ "qemuarm64", "qemumips", "qemumips64", "qemuppc",
+ "qemux86", or "qemux86-64".
+ </para></listitem>
+ <listitem><para>
+ <filename><replaceable>VM</replaceable></filename>:
+ The virtual machine image, which must be a
+ <filename>.wic.vmdk</filename> file.
+ Use this option when you want to boot a
+ <filename>.wic.vmdk</filename> image.
+ The image filename you provide must contain one of the
+ following strings: "qemux86-64", "qemux86", "qemuarm",
+ "qemumips64", "qemumips", "qemuppc", or "qemush4".
+ </para></listitem>
+ <listitem><para>
+ <replaceable>ROOTFS</replaceable>:
+ A root filesystem that has one of the following
+ filetype extensions: "ext2", "ext3", "ext4", "jffs2",
+ "nfs", or "btrfs".
+ If the filename you provide for this option uses “nfs”, it
+ must provide an explicit root filesystem path.
+ </para></listitem>
+ <listitem><para>
+ <replaceable>KERNEL</replaceable>:
+ A kernel image, which is a <filename>.bin</filename> file.
+ When you provide a <filename>.bin</filename> file,
+ <filename>runqemu</filename> detects it and assumes the
+ file is a kernel image.
+ </para></listitem>
+ <listitem><para>
+ <replaceable>MACHINE</replaceable>:
+ The architecture of the QEMU machine, which must be one
+ of the following: "qemux86", "qemux86-64", "qemuarm",
+ "qemuarm64", "qemumips", “qemumips64", or "qemuppc".
+ The <replaceable>MACHINE</replaceable> and
+ <replaceable>QEMUARCH</replaceable> options are basically
+ identical.
+ If you do not provide a <replaceable>MACHINE</replaceable>
+ option, <filename>runqemu</filename> tries to determine
+ it based on other options.
+ </para></listitem>
+ <listitem><para>
+ <filename>ramfs</filename>:
+ Indicates you are booting an initial RAM disk (initramfs)
+ image, which means the <filename>FSTYPE</filename> is
+ <filename>cpio.gz</filename>.
+ </para></listitem>
+ <listitem><para>
+ <filename>iso</filename>:
+ Indicates you are booting an ISO image, which means the
+ <filename>FSTYPE</filename> is
+ <filename>.iso</filename>.
+ </para></listitem>
+ <listitem><para>
+ <filename>nographic</filename>:
+ Disables the video console, which sets the console to
+ "ttys0".
+ </para></listitem>
+ <listitem><para>
+ <filename>serial</filename>:
+ Enables a serial console on
+ <filename>/dev/ttyS0</filename>.
+ </para></listitem>
+ <listitem><para>
+ <filename>biosdir</filename>:
+ Establishes a custom directory for BIOS, VGA BIOS and
+ keymaps.
+ </para></listitem>
+ <listitem><para>
+ <filename>biosfilename</filename>:
+ Establishes a custom BIOS name.
+ </para></listitem>
+ <listitem><para>
+ <filename>qemuparams=\"<replaceable>xyz</replaceable>\"</filename>:
+ Specifies custom QEMU parameters.
+ Use this option to pass options other than the simple
+ "kvm" and "serial" options.
+ </para></listitem>
+ <listitem><para><filename>bootparams=\"<replaceable>xyz</replaceable>\"</filename>:
+ Specifies custom boot parameters for the kernel.
+ </para></listitem>
+ <listitem><para>
+ <filename>audio</filename>:
+ Enables audio in QEMU.
+ The <replaceable>MACHINE</replaceable> option must be
+ either "qemux86" or "qemux86-64" in order for audio to be
+ enabled.
+ Additionally, the <filename>snd_intel8x0</filename>
+ or <filename>snd_ens1370</filename> driver must be
+ installed in linux guest.
+ </para></listitem>
+ <listitem><para>
+ <filename>slirp</filename>:
+ Enables "slirp" networking, which is a different way
+ of networking that does not need root access
+ but also is not as easy to use or comprehensive
+ as the default.
+ </para></listitem>
+ <listitem><para id='kvm-cond'>
+ <filename>kvm</filename>:
+ Enables KVM when running "qemux86" or "qemux86-64"
+ QEMU architectures.
+ For KVM to work, all the following conditions must be met:
+ <itemizedlist>
+ <listitem><para>
+ Your <replaceable>MACHINE</replaceable> must be either
+qemux86" or "qemux86-64".
+ </para></listitem>
+ <listitem><para>
+ Your build host has to have the KVM modules
+ installed, which are
+ <filename>/dev/kvm</filename>.
+ </para></listitem>
+ <listitem><para>
+ The build host <filename>/dev/kvm</filename>
+ directory has to be both writable and readable.
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <filename>kvm-vhost</filename>:
+ Enables KVM with VHOST support when running "qemux86"
+ or "qemux86-64" QEMU architectures.
+ For KVM with VHOST to work, the following conditions must
+ be met:
+ <itemizedlist>
+ <listitem><para>
+ <link linkend='kvm-cond'>kvm</link> option
+ conditions must be met.
+ </para></listitem>
+ <listitem><para>
+ Your build host has to have virtio net device, which
+ are <filename>/dev/vhost-net</filename>.
+ </para></listitem>
+ <listitem><para>
+ The build host <filename>/dev/vhost-net</filename>
+ directory has to be either readable or writable
+ and “slirp-enabled”.
+ </para></listitem>
+ </itemizedlist>
+ </para></listitem>
+ <listitem><para>
+ <filename>publicvnc</filename>:
+ Enables a VNC server open to all hosts.
+ </para></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+</section>
+
<section id='maintaining-build-output-quality'>
<title>Maintaining Build Output Quality</title>
@@ -1099,15 +1473,15 @@
<link linkend='var-BUILDHISTORY_COMMIT'><filename>BUILDHISTORY_COMMIT</filename></link>
variable to "1" at the end of your
<filename>conf/local.conf</filename> file found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>:
+ <link linkend='build-directory'>Build Directory</link>:
<literallayout class='monospaced'>
INHERIT += "buildhistory"
BUILDHISTORY_COMMIT = "1"
</literallayout>
- Enabling build history as previously described
- causes the build process to collect build
- output information and commit it to a local
- <ulink url='&YOCTO_DOCS_DEV_URL;#git'>Git</ulink> repository.
+ Enabling build history as previously described causes the
+ OpenEmbedded build system to collect build output information and
+ commit it as a single commit to a local
+ <link linkend='git'>Git</link> repository.
<note>
Enabling build history increases your build times slightly,
particularly for images, and increases the amount of disk
@@ -1357,7 +1731,7 @@
you can enable writing only image information without
any history by adding the following to your
<filename>conf/local.conf</filename> file found in the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>:
+ <link linkend='build-directory'>Build Directory</link>:
<literallayout class='monospaced'>
INHERIT += "buildhistory"
BUILDHISTORY_COMMIT = "0"
@@ -1643,7 +2017,7 @@
<filename>sync()</filename> calls into the
file system on the principle that if there was a significant
failure, the
- <ulink url='&YOCTO_DOCS_DEV_URL;#build-directory'>Build Directory</ulink>
+ <link linkend='build-directory'>Build Directory</link>
contents could easily be rebuilt.
</para></listitem>
<listitem><para>