ref-manual: Updates to deal with installing packages in initramfs
Fixes [YOCTO #4961] Documented the user requirement to use PACKAGE_INSTALL to specify packages for installation into an initramfs image. Normally, you use IMAGE_INSTALL. To account for this user model, I updated the PACKAGE_INSTALL and IMAGE_INSTALL variables. I also added a bit more information to the "Images" chapter item that talks about the core-image-minimal-initramfs image. (From yocto-docs rev: a1ad649cf310f281a7de584d5b9a1820ca99d4eb) Signed-off-by: Scott Rifenbark <scott.m.rifenbark@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
c42cadfa6b
commit
cc3f3821a0
|
@ -61,10 +61,14 @@
|
||||||
The image includes headers and libraries you can use in a host development
|
The image includes headers and libraries you can use in a host development
|
||||||
environment.
|
environment.
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
<listitem><para><emphasis><filename>core-image-minimal-initramfs</filename>:</emphasis>
|
<listitem><para id='images-core-image-minimal-initramfs'><emphasis><filename>core-image-minimal-initramfs</filename>:</emphasis>
|
||||||
A <filename>core-image-minimal</filename> image that has the Minimal RAM-based
|
A <filename>core-image-minimal</filename> image that has the Minimal RAM-based
|
||||||
Initial Root Filesystem (<filename>initramfs</filename>) as part of the kernel,
|
Initial Root Filesystem (initramfs) as part of the kernel,
|
||||||
which allows the system to find the first “init” program more efficiently.
|
which allows the system to find the first “init” program more efficiently.
|
||||||
|
See the
|
||||||
|
<link linkend='var-PACKAGE_INSTALL'><filename>PACKAGE_INSTALL</filename></link>
|
||||||
|
variable for additional information helpful when working with
|
||||||
|
initramfs images.
|
||||||
</para></listitem>
|
</para></listitem>
|
||||||
<listitem><para><emphasis><filename>core-image-minimal-mtdutils</filename>:</emphasis>
|
<listitem><para><emphasis><filename>core-image-minimal-mtdutils</filename>:</emphasis>
|
||||||
A <filename>core-image-minimal</filename> image that has support
|
A <filename>core-image-minimal</filename> image that has support
|
||||||
|
|
|
@ -2962,33 +2962,52 @@
|
||||||
<glossdef>
|
<glossdef>
|
||||||
<para>
|
<para>
|
||||||
Specifies the packages to install into an image.
|
Specifies the packages to install into an image.
|
||||||
The <filename>IMAGE_INSTALL</filename> variable is a mechanism for an image
|
The <filename>IMAGE_INSTALL</filename> variable is a
|
||||||
recipe and you should use it with care to avoid ordering issues.
|
mechanism for an image recipe and you should use it
|
||||||
|
with care to avoid ordering issues.
|
||||||
|
<note>
|
||||||
|
When working with an
|
||||||
|
<link linkend='images-core-image-minimal-initramfs'><filename>core-image-minimal-initramfs</filename></link>
|
||||||
|
image, do not use the <filename>IMAGE_INSTALL</filename>
|
||||||
|
variable to specify packages for installation.
|
||||||
|
Instead, use the
|
||||||
|
<link linkend='var-PACKAGE_INSTALL'><filename>PACKAGE_INSTALL</filename></link>
|
||||||
|
variable, which allows the initial RAM disk (initramfs)
|
||||||
|
recipe to use a fixed set of packages and not be
|
||||||
|
affected by <filename>IMAGE_INSTALL</filename>.
|
||||||
|
</note>
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Image recipes set <filename>IMAGE_INSTALL</filename> to specify the
|
Image recipes set <filename>IMAGE_INSTALL</filename>
|
||||||
packages to install into an image through <filename>image.bbclass</filename>.
|
to specify the packages to install into an image through
|
||||||
Additionally, "helper" classes exist, such as <filename>core-image.bbclass</filename>,
|
<filename>image.bbclass</filename>.
|
||||||
that can take
|
Additionally, "helper" classes exist, such as
|
||||||
<filename><link linkend='var-IMAGE_FEATURES'>IMAGE_FEATURES</link></filename> lists
|
<filename>core-image.bbclass</filename>, that can take
|
||||||
and turn these into auto-generated entries in
|
<filename><link linkend='var-IMAGE_FEATURES'>IMAGE_FEATURES</link></filename>
|
||||||
<filename>IMAGE_INSTALL</filename> in addition to its default contents.
|
lists and turn these into auto-generated entries in
|
||||||
|
<filename>IMAGE_INSTALL</filename> in addition to its
|
||||||
|
default contents.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
Using <filename>IMAGE_INSTALL</filename> with the <filename>+=</filename>
|
Using <filename>IMAGE_INSTALL</filename> with the
|
||||||
operator from the <filename>/conf/local.conf</filename> file or from within
|
<filename>+=</filename> operator from the
|
||||||
an image recipe is not recommended as it can cause ordering issues.
|
<filename>/conf/local.conf</filename> file or from within
|
||||||
Since <filename>core-image.bbclass</filename> sets <filename>IMAGE_INSTALL</filename>
|
an image recipe is not recommended as it can cause ordering
|
||||||
to a default value using the <filename>?=</filename> operator, using a
|
issues.
|
||||||
<filename>+=</filename> operation against <filename>IMAGE_INSTALL</filename>
|
Since <filename>core-image.bbclass</filename> sets
|
||||||
will result in unexpected behavior when used in
|
<filename>IMAGE_INSTALL</filename> to a default value using
|
||||||
|
the <filename>?=</filename> operator, using a
|
||||||
|
<filename>+=</filename> operation against
|
||||||
|
<filename>IMAGE_INSTALL</filename> will result in
|
||||||
|
unexpected behavior when used in
|
||||||
<filename>conf/local.conf</filename>.
|
<filename>conf/local.conf</filename>.
|
||||||
Furthermore, the same operation from within an image recipe may or may not
|
Furthermore, the same operation from within an image
|
||||||
succeed depending on the specific situation.
|
recipe may or may not succeed depending on the specific
|
||||||
In both these cases, the behavior is contrary to how most users expect
|
situation.
|
||||||
the <filename>+=</filename> operator to work.
|
In both these cases, the behavior is contrary to how most
|
||||||
|
users expect the <filename>+=</filename> operator to work.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
<para>
|
<para>
|
||||||
|
@ -2996,8 +3015,8 @@
|
||||||
<literallayout class='monospaced'>
|
<literallayout class='monospaced'>
|
||||||
IMAGE_INSTALL_append = " package-name"
|
IMAGE_INSTALL_append = " package-name"
|
||||||
</literallayout>
|
</literallayout>
|
||||||
Be sure to include the space between the quotation character and the start of the
|
Be sure to include the space between the quotation character
|
||||||
package name or names.
|
and the start of the package name or names.
|
||||||
</para>
|
</para>
|
||||||
</glossdef>
|
</glossdef>
|
||||||
</glossentry>
|
</glossentry>
|
||||||
|
@ -5196,18 +5215,25 @@ recipes-graphics/xorg-font/font-alias_1.0.3.bb:PR = "${INC_PR}.3"
|
||||||
<para>
|
<para>
|
||||||
The final list of packages passed to the package manager
|
The final list of packages passed to the package manager
|
||||||
for installation into the image.
|
for installation into the image.
|
||||||
|
</para>
|
||||||
|
|
||||||
|
<para>
|
||||||
Because the package manager controls actual installation
|
Because the package manager controls actual installation
|
||||||
of all packages, the list of packages passed using
|
of all packages, the list of packages passed using
|
||||||
<filename>PACKAGE_INSTALL</filename> is not the final list
|
<filename>PACKAGE_INSTALL</filename> is not the final list
|
||||||
of packages that are actually installed.
|
of packages that are actually installed.
|
||||||
</para>
|
|
||||||
|
|
||||||
<para>
|
|
||||||
This variable is internal to the image construction
|
This variable is internal to the image construction
|
||||||
code.
|
code.
|
||||||
Use the
|
Consequently, in general, you should use the
|
||||||
<link linkend='var-IMAGE_INSTALL'><filename>IMAGE_INSTALL</filename></link>
|
<link linkend='var-IMAGE_INSTALL'><filename>IMAGE_INSTALL</filename></link>
|
||||||
variable to specify packages for installation.
|
variable to specify packages for installation.
|
||||||
|
The exception to this is when working with
|
||||||
|
the
|
||||||
|
<link linkend='images-core-image-minimal-initramfs'><filename>core-image-minimal-initramfs</filename></link>
|
||||||
|
image.
|
||||||
|
When working with an initial RAM disk (initramfs)
|
||||||
|
image, use the <filename>PACKAGE_INSTALL</filename>
|
||||||
|
variable.
|
||||||
</para>
|
</para>
|
||||||
</glossdef>
|
</glossdef>
|
||||||
</glossentry>
|
</glossentry>
|
||||||
|
|
Loading…
Reference in New Issue