1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-09 17:39:31 +00:00

manuals: document VIRTUAL-RUNTIME variables

Document the convention to use variables prefixed by VIRTUAL_RUNTIME.
Add references to the new term where possible.

Another reason is that such variables are recommended
in a warning issued by meta/classes-global/insane.bbclass

(From yocto-docs rev: 11e1ba97edac979868f199e43c1004db6678044c)

Signed-off-by: Michael Opdenacker <michael.opdenacker@bootlin.com>
Reported-by: Tim Orling <ticotimo@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Michael Opdenacker
2024-03-05 19:36:46 +01:00
committed by Richard Purdie
parent f9e1cfe9e8
commit dbcb74ef81
2 changed files with 36 additions and 9 deletions
+4 -4
View File
@@ -60,10 +60,10 @@ kernel.
All devices created by ``devtmpfs`` will be owned by ``root`` and have All devices created by ``devtmpfs`` will be owned by ``root`` and have
permissions ``0600``. permissions ``0600``.
To have more control over the device nodes, you can use a device manager To have more control over the device nodes, you can use a device manager like
like ``udev`` or ``busybox-mdev``. You choose the device manager by ``udev`` or ``busybox-mdev``. You choose the device manager by defining the
defining the ``VIRTUAL-RUNTIME_dev_manager`` variable in your machine or :term:`VIRTUAL-RUNTIME_dev_manager <VIRTUAL-RUNTIME>` variable in your machine
distro configuration file. Alternatively, you can set this variable in or distro configuration file. Alternatively, you can set this variable in
your ``local.conf`` configuration file:: your ``local.conf`` configuration file::
VIRTUAL-RUNTIME_dev_manager = "udev" VIRTUAL-RUNTIME_dev_manager = "udev"
+32 -5
View File
@@ -6750,11 +6750,11 @@ system and gives an overview of their function and contents.
.. note:: .. note::
A corresponding mechanism for virtual runtime dependencies A corresponding mechanism for virtual runtime dependencies (packages)
(packages) exists. However, the mechanism does not depend on any exists. However, the mechanism does not depend on any special
special functionality beyond ordinary variable assignments. For functionality beyond ordinary variable assignments. For example,
example, ``VIRTUAL-RUNTIME_dev_manager`` refers to the package of :term:`VIRTUAL-RUNTIME_dev_manager <VIRTUAL-RUNTIME>` refers to the
the component that manages the ``/dev`` directory. package of the component that manages the ``/dev`` directory.
Setting the "preferred provider" for runtime dependencies is as Setting the "preferred provider" for runtime dependencies is as
simple as using the following assignment in a configuration file:: simple as using the following assignment in a configuration file::
@@ -9866,6 +9866,33 @@ system and gives an overview of their function and contents.
Additionally, you should also set the Additionally, you should also set the
:term:`USERADD_ERROR_DYNAMIC` variable. :term:`USERADD_ERROR_DYNAMIC` variable.
:term:`VIRTUAL-RUNTIME`
:term:`VIRTUAL-RUNTIME` is a commonly used prefix for defining virtual
packages for runtime usage, typically for use in :term:`RDEPENDS`
or in image definitions.
An example is ``VIRTUAL-RUNTIME_base-utils`` that makes it possible
to either use BusyBox based utilities::
VIRTUAL-RUNTIME_base-utils = "busybox"
or their full featured implementations from GNU Coreutils
and other projects::
VIRTUAL-RUNTIME_base-utils = "packagegroup-core-base-utils"
Here are two examples using this virtual runtime package. The
first one is in :yocto_git:`initramfs-framework_1.0.bb
</poky/tree/meta/recipes-core/initrdscripts/initramfs-framework_1.0.bb?h=scarthgap>`::
RDEPENDS:${PN} += "${VIRTUAL-RUNTIME_base-utils}"
The second example is in the :yocto_git:`core-image-initramfs-boot
</poky/tree/meta/recipes-core/images/core-image-initramfs-boot.bb?h=scarthgap>`
image definition::
PACKAGE_INSTALL = "${INITRAMFS_SCRIPTS} ${VIRTUAL-RUNTIME_base-utils} base-passwd"
:term:`VOLATILE_LOG_DIR` :term:`VOLATILE_LOG_DIR`
Specifies the persistence of the target's ``/var/log`` directory, Specifies the persistence of the target's ``/var/log`` directory,
which is used to house postinstall target log files. which is used to house postinstall target log files.