diff options
author | Enrico Jörns <ejo@pengutronix.de> | 2025-01-19 23:10:05 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-01-29 10:41:59 +0000 |
commit | dfab86d2f4bdc131529d7e1705fc4b095afa8b54 (patch) | |
tree | a9aab217c27b47f1339828e29412afff852e4cc5 /documentation | |
parent | 5a38f96a33d75a120dba4f2e6157189a140ccb38 (diff) | |
download | poky-dfab86d2f4bdc131529d7e1705fc4b095afa8b54.tar.gz |
ref-manual: add documentation for the barebox class
This adds the initial documentation for the newly added barebox.bbclass
to the Reference Manual's class list.
It also adds the two most notable variables to the variable list.
(From yocto-docs rev: cc8179122441cdc26ff62511dcd97f7bf9bf7e3d)
Signed-off-by: Enrico Jörns <ejo@pengutronix.de>
Reviewed-by: Antonin Godard <antonin.godard@bootlin.com>
Signed-off-by: Antonin Godard <antonin.godard@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation')
-rw-r--r-- | documentation/ref-manual/classes.rst | 37 | ||||
-rw-r--r-- | documentation/ref-manual/variables.rst | 29 |
2 files changed, 66 insertions, 0 deletions
diff --git a/documentation/ref-manual/classes.rst b/documentation/ref-manual/classes.rst index 22c4301a49..8ad77319ec 100644 --- a/documentation/ref-manual/classes.rst +++ b/documentation/ref-manual/classes.rst | |||
@@ -128,6 +128,43 @@ It's useful to have some idea of how the tasks defined by the | |||
128 | - :ref:`ref-tasks-install` --- runs ``make install`` and | 128 | - :ref:`ref-tasks-install` --- runs ``make install`` and |
129 | passes in ``${``\ :term:`D`\ ``}`` as ``DESTDIR``. | 129 | passes in ``${``\ :term:`D`\ ``}`` as ``DESTDIR``. |
130 | 130 | ||
131 | .. _ref-classes-barebox: | ||
132 | |||
133 | ``barebox`` | ||
134 | =========== | ||
135 | |||
136 | The :ref:`ref-classes-barebox` class manages building the barebox bootloader. | ||
137 | |||
138 | If a file named ``defconfig`` is included in the :term:`SRC_URI`, it will be | ||
139 | copied to ``.config`` in the build directory and used as the barebox | ||
140 | configuration. | ||
141 | Instead of providing a ``defconfig`` file, you can set :term:`BAREBOX_CONFIG` | ||
142 | to a defconfig provided by the barebox source tree. | ||
143 | If neither ``defconfig`` nor :term:`BAREBOX_CONFIG` is specified, the class | ||
144 | will raise an error. | ||
145 | |||
146 | The :ref:`ref-classes-barebox` class supports config fragments and internally | ||
147 | includes the :ref:`ref-classes-cml1` class to provide `Kconfig | ||
148 | <https://docs.kernel.org/kbuild/kconfig-language.html>`__ support for | ||
149 | barebox, enabling tasks such as :ref:`ref-tasks-menuconfig` and | ||
150 | :ref:`ref-tasks-diffconfig`. | ||
151 | |||
152 | The generated barebox binaries are deployed to | ||
153 | :term:`DEPLOY_DIR_IMAGE` as well as installed to ``BAREBOX_INSTALL_PATH`` | ||
154 | (``/boot`` by default) making them part of the recipe’s base package. | ||
155 | This setup supports both using the barebox binaries as independent artifacts | ||
156 | and installing them into a rootfs. | ||
157 | :term:`BAREBOX_BINARY` can be used to select a distinct binary to deploy and | ||
158 | install. | ||
159 | If ``barebox`` is set as the :term:`EFI_PROVIDER`, the class will leverage | ||
160 | :oe_git:`conf/image-uefi.conf </openembedded-core/tree/meta/conf/image-uefi.conf>` | ||
161 | to define the default installation paths and naming conventions. | ||
162 | |||
163 | The compiled-in barebox environment can be extended by adding environment files | ||
164 | to the ``BAREBOX_ENV_DIR``. | ||
165 | The ``BAREBOX_FIRMWARE_DIR`` variable allows you to specify the firmware blob | ||
166 | search directory, enabling loading of additional firmware like TF-A or OP-TEE. | ||
167 | |||
131 | .. _ref-classes-base: | 168 | .. _ref-classes-base: |
132 | 169 | ||
133 | ``base`` | 170 | ``base`` |
diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst index 702a6caf87..8b996f216b 100644 --- a/documentation/ref-manual/variables.rst +++ b/documentation/ref-manual/variables.rst | |||
@@ -293,6 +293,35 @@ system and gives an overview of their function and contents. | |||
293 | :term:`PACKAGE_EXCLUDE` variables for related | 293 | :term:`PACKAGE_EXCLUDE` variables for related |
294 | information. | 294 | information. |
295 | 295 | ||
296 | :term:`BAREBOX_BINARY` | ||
297 | When using the :ref:`ref-classes-barebox` class, this variable allows you | ||
298 | to specify a particular binary that should be deployed and installed. | ||
299 | |||
300 | The barebox build system can build multiple barebox binaries at once. | ||
301 | By default, all built binaries will be deployed and installed under their | ||
302 | original name. | ||
303 | |||
304 | Here is an example usage of this variable:: | ||
305 | |||
306 | BAREBOX_BINARY = "barebox-boundarydevices-imx6dl-nitrogen6x-1g.img" | ||
307 | |||
308 | :term:`BAREBOX_CONFIG` | ||
309 | When using the :ref:`ref-classes-barebox` class, this variable allows you | ||
310 | to specify the name of the barebox defconfig to build. | ||
311 | The name must be a defconfig file known to the barebox build environment. | ||
312 | This variable is mainly useful for generic use cases where a dedicated | ||
313 | configuration is not required. | ||
314 | The :ref:`ref-classes-barebox` class itself already sets it for some QEMU | ||
315 | machines:: | ||
316 | |||
317 | BAREBOX_CONFIG:qemuarm = "multi_v7_defconfig" | ||
318 | BAREBOX_CONFIG:qemuarm64 = "multi_v8_defconfig" | ||
319 | BAREBOX_CONFIG:qemux86-64 = "efi_defconfig" | ||
320 | |||
321 | Except for these, the default value of :term:`BAREBOX_CONFIG` is empty. | ||
322 | For more information on how to provide a barebox configuration, see the | ||
323 | :ref:`ref-classes-barebox` class. | ||
324 | |||
296 | :term:`BASE_LIB` | 325 | :term:`BASE_LIB` |
297 | The library directory name for the CPU or Application Binary | 326 | The library directory name for the CPU or Application Binary |
298 | Interface (ABI) tune. The :term:`BASE_LIB` applies only in the Multilib | 327 | Interface (ABI) tune. The :term:`BASE_LIB` applies only in the Multilib |