blob: 0603ba93c5cb5371c2565f2190966693c7758e00 [file] [log] [blame]
Andrew Geisslerf0343792020-11-18 10:42:21 -06001.. SPDX-License-Identifier: CC-BY-SA-2.0-UK
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002
3******************
4Variables Glossary
5******************
6
7This chapter lists common variables used in the OpenEmbedded build
8system and gives an overview of their function and contents.
9
Andrew Geisslerf0343792020-11-18 10:42:21 -060010:term:`A <ABIEXTENSION>` :term:`B` :term:`C <CACHE>`
11:term:`D` :term:`E <EFI_PROVIDER>` :term:`F <FEATURE_PACKAGES>`
12:term:`G <GCCPIE>` :term:`H <HOMEPAGE>` :term:`I <ICECC_DISABLED>`
13:term:`K <KARCH>` :term:`L <LABELS>` :term:`M <MACHINE>`
14:term:`N <NATIVELSBSTRING>` :term:`O <OBJCOPY>` :term:`P`
15:term:`R <RANLIB>` :term:`S` :term:`T`
16:term:`U <UBOOT_CONFIG>` :term:`V <VOLATILE_LOG_DIR>`
17:term:`W <WARN_QA>` :term:`X <XSERVER>`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050018
19.. glossary::
20
Andrew Geisslerf0343792020-11-18 10:42:21 -060021 :term:`ABIEXTENSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050022 Extension to the Application Binary Interface (ABI) field of the GNU
23 canonical architecture name (e.g. "eabi").
24
25 ABI extensions are set in the machine include files. For example, the
26 ``meta/conf/machine/include/arm/arch-arm.inc`` file sets the
27 following extension:
28 ::
29
30 ABIEXTENSION = "eabi"
31
Andrew Geisslerf0343792020-11-18 10:42:21 -060032 :term:`ALLOW_EMPTY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050033 Specifies whether to produce an output package even if it is empty.
34 By default, BitBake does not produce empty packages. This default
35 behavior can cause issues when there is an
36 :term:`RDEPENDS` or some other hard runtime
37 requirement on the existence of the package.
38
39 Like all package-controlling variables, you must always use them in
40 conjunction with a package name override, as in:
41 ::
42
43 ALLOW_EMPTY_${PN} = "1"
44 ALLOW_EMPTY_${PN}-dev = "1"
45 ALLOW_EMPTY_${PN}-staticdev = "1"
46
Andrew Geisslerf0343792020-11-18 10:42:21 -060047 :term:`ALTERNATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050048 Lists commands in a package that need an alternative binary naming
49 scheme. Sometimes the same command is provided in multiple packages.
50 When this occurs, the OpenEmbedded build system needs to use the
51 alternatives system to create a different binary naming scheme so the
52 commands can co-exist.
53
54 To use the variable, list out the package's commands that also exist
55 as part of another package. For example, if the ``busybox`` package
56 has four commands that also exist as part of another package, you
57 identify them as follows:
58 ::
59
60 ALTERNATIVE_busybox = "sh sed test bracket"
61
62 For more information on the alternatives system, see the
63 ":ref:`update-alternatives.bbclass <ref-classes-update-alternatives>`"
64 section.
65
Andrew Geisslerf0343792020-11-18 10:42:21 -060066 :term:`ALTERNATIVE_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050067 Used by the alternatives system to map duplicated commands to actual
68 locations. For example, if the ``bracket`` command provided by the
69 ``busybox`` package is duplicated through another package, you must
70 use the ``ALTERNATIVE_LINK_NAME`` variable to specify the actual
71 location:
72 ::
73
74 ALTERNATIVE_LINK_NAME[bracket] = "/usr/bin/["
75
76 In this example, the binary for the ``bracket`` command (i.e. ``[``)
77 from the ``busybox`` package resides in ``/usr/bin/``.
78
79 .. note::
80
Andrew Geissler4c19ea12020-10-27 13:52:24 -050081 If ``ALTERNATIVE_LINK_NAME`` is not defined, it defaults to ``${bindir}/name``.
Andrew Geisslerc9f78652020-09-18 14:11:35 -050082
83 For more information on the alternatives system, see the
84 ":ref:`update-alternatives.bbclass <ref-classes-update-alternatives>`"
85 section.
86
Andrew Geisslerf0343792020-11-18 10:42:21 -060087 :term:`ALTERNATIVE_PRIORITY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -050088 Used by the alternatives system to create default priorities for
89 duplicated commands. You can use the variable to create a single
90 default regardless of the command name or package, a default for
91 specific duplicated commands regardless of the package, or a default
92 for specific commands tied to particular packages. Here are the
93 available syntax forms:
94 ::
95
96 ALTERNATIVE_PRIORITY = "priority"
97 ALTERNATIVE_PRIORITY[name] = "priority"
98 ALTERNATIVE_PRIORITY_pkg[name] = "priority"
99
100 For more information on the alternatives system, see the
101 ":ref:`update-alternatives.bbclass <ref-classes-update-alternatives>`"
102 section.
103
Andrew Geisslerf0343792020-11-18 10:42:21 -0600104 :term:`ALTERNATIVE_TARGET`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500105 Used by the alternatives system to create default link locations for
106 duplicated commands. You can use the variable to create a single
107 default location for all duplicated commands regardless of the
108 command name or package, a default for specific duplicated commands
109 regardless of the package, or a default for specific commands tied to
110 particular packages. Here are the available syntax forms:
111 ::
112
113 ALTERNATIVE_TARGET = "target"
114 ALTERNATIVE_TARGET[name] = "target"
115 ALTERNATIVE_TARGET_pkg[name] = "target"
116
117 .. note::
118
119 If ``ALTERNATIVE_TARGET`` is not defined, it inherits the value
120 from the :term:`ALTERNATIVE_LINK_NAME` variable.
121
122 If ``ALTERNATIVE_LINK_NAME`` and ``ALTERNATIVE_TARGET`` are the
123 same, the target for ``ALTERNATIVE_TARGET`` has "``.{BPN}``"
124 appended to it.
125
126 Finally, if the file referenced has not been renamed, the
127 alternatives system will rename it to avoid the need to rename
128 alternative files in the :ref:`ref-tasks-install`
129 task while retaining support for the command if necessary.
130
131 For more information on the alternatives system, see the
132 ":ref:`update-alternatives.bbclass <ref-classes-update-alternatives>`"
133 section.
134
Andrew Geisslerf0343792020-11-18 10:42:21 -0600135 :term:`APPEND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500136 An override list of append strings for each target specified with
137 :term:`LABELS`.
138
139 See the :ref:`grub-efi <ref-classes-grub-efi>` class for more
140 information on how this variable is used.
141
Andrew Geisslerf0343792020-11-18 10:42:21 -0600142 :term:`AR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500143 The minimal command and arguments used to run ``ar``.
144
Andrew Geisslerf0343792020-11-18 10:42:21 -0600145 :term:`ARCHIVER_MODE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500146 When used with the :ref:`archiver <ref-classes-archiver>` class,
147 determines the type of information used to create a released archive.
148 You can use this variable to create archives of patched source,
149 original source, configured source, and so forth by employing the
150 following variable flags (varflags):
151 ::
152
153 ARCHIVER_MODE[src] = "original" # Uses original (unpacked) source files.
154 ARCHIVER_MODE[src] = "patched" # Uses patched source files. This is the default.
155 ARCHIVER_MODE[src] = "configured" # Uses configured source files.
156 ARCHIVER_MODE[diff] = "1" # Uses patches between do_unpack and do_patch.
157 ARCHIVER_MODE[diff-exclude] ?= "file file ..." # Lists files and directories to exclude from diff.
158 ARCHIVER_MODE[dumpdata] = "1" # Uses environment data.
159 ARCHIVER_MODE[recipe] = "1" # Uses recipe and include files.
160 ARCHIVER_MODE[srpm] = "1" # Uses RPM package files.
161
162 For information on how the variable works, see the
163 ``meta/classes/archiver.bbclass`` file in the :term:`Source Directory`.
164
Andrew Geisslerf0343792020-11-18 10:42:21 -0600165 :term:`AS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500166 Minimal command and arguments needed to run the assembler.
167
Andrew Geisslerf0343792020-11-18 10:42:21 -0600168 :term:`ASSUME_PROVIDED`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500169 Lists recipe names (:term:`PN` values) BitBake does not
170 attempt to build. Instead, BitBake assumes these recipes have already
171 been built.
172
173 In OpenEmbedded-Core, ``ASSUME_PROVIDED`` mostly specifies native
174 tools that should not be built. An example is ``git-native``, which
175 when specified, allows for the Git binary from the host to be used
176 rather than building ``git-native``.
177
Andrew Geisslerf0343792020-11-18 10:42:21 -0600178 :term:`ASSUME_SHLIBS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500179 Provides additional ``shlibs`` provider mapping information, which
180 adds to or overwrites the information provided automatically by the
181 system. Separate multiple entries using spaces.
182
183 As an example, use the following form to add an ``shlib`` provider of
184 shlibname in packagename with the optional version:
185 ::
186
187 shlibname:packagename[_version]
188
189 Here is an example that adds a shared library named ``libEGL.so.1``
190 as being provided by the ``libegl-implementation`` package:
191 ::
192
193 ASSUME_SHLIBS = "libEGL.so.1:libegl-implementation"
194
Andrew Geisslerf0343792020-11-18 10:42:21 -0600195 :term:`AUTHOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500196 The email address used to contact the original author or authors in
197 order to send patches and forward bugs.
198
Andrew Geisslerf0343792020-11-18 10:42:21 -0600199 :term:`AUTO_LIBNAME_PKGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500200 When the :ref:`debian <ref-classes-debian>` class is inherited,
201 which is the default behavior, ``AUTO_LIBNAME_PKGS`` specifies which
202 packages should be checked for libraries and renamed according to
203 Debian library package naming.
204
205 The default value is "${PACKAGES}", which causes the debian class to
206 act on all packages that are explicitly generated by the recipe.
207
Andrew Geisslerf0343792020-11-18 10:42:21 -0600208 :term:`AUTO_SYSLINUXMENU`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500209 Enables creating an automatic menu for the syslinux bootloader. You
210 must set this variable in your recipe. The
211 :ref:`syslinux <ref-classes-syslinux>` class checks this variable.
212
Andrew Geisslerf0343792020-11-18 10:42:21 -0600213 :term:`AUTOREV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500214 When ``SRCREV`` is set to the value of this variable, it specifies to
215 use the latest source revision in the repository. Here is an example:
216 ::
217
218 SRCREV = "${AUTOREV}"
219
220 If you use the previous statement to retrieve the latest version of
221 software, you need to be sure :term:`PV` contains
222 ``${``\ :term:`SRCPV`\ ``}``. For example, suppose you
223 have a kernel recipe that inherits the
224 :ref:`kernel <ref-classes-kernel>` class and you use the previous
225 statement. In this example, ``${SRCPV}`` does not automatically get
226 into ``PV``. Consequently, you need to change ``PV`` in your recipe
227 so that it does contain ``${SRCPV}``.
228
229 For more information see the
230 ":ref:`dev-manual/dev-manual-common-tasks:automatically incrementing a package version number`"
231 section in the Yocto Project Development Tasks Manual.
232
Andrew Geisslerf0343792020-11-18 10:42:21 -0600233 :term:`AVAILABLE_LICENSES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500234 List of licenses found in the directories specified by
235 :term:`COMMON_LICENSE_DIR` and
236 :term:`LICENSE_PATH`.
237
238 .. note::
239
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500240 It is assumed that all changes to ``COMMON_LICENSE_DIR`` and
241 ``LICENSE_PATH`` have been done before ``AVAILABLE_LICENSES``
242 is defined (in :ref:`ref-classes-license`).
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500243
Andrew Geisslerf0343792020-11-18 10:42:21 -0600244 :term:`AVAILTUNES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500245 The list of defined CPU and Application Binary Interface (ABI)
246 tunings (i.e. "tunes") available for use by the OpenEmbedded build
247 system.
248
249 The list simply presents the tunes that are available. Not all tunes
250 may be compatible with a particular machine configuration, or with
251 each other in a
252 :ref:`Multilib <dev-manual/dev-manual-common-tasks:combining multiple versions of library files into one image>`
253 configuration.
254
255 To add a tune to the list, be sure to append it with spaces using the
256 "+=" BitBake operator. Do not simply replace the list by using the
257 "=" operator. See the
258 ":ref:`Basic Syntax <bitbake:bitbake-user-manual/bitbake-user-manual-metadata:basic syntax>`" section in the BitBake
259 User Manual for more information.
260
Andrew Geisslerf0343792020-11-18 10:42:21 -0600261 :term:`B`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500262 The directory within the :term:`Build Directory` in
263 which the OpenEmbedded build system places generated objects during a
264 recipe's build process. By default, this directory is the same as the
265 :term:`S` directory, which is defined as:
266 ::
267
268 S = "${WORKDIR}/${BP}"
269
270 You can separate the (``S``) directory and the directory pointed to
271 by the ``B`` variable. Most Autotools-based recipes support
272 separating these directories. The build system defaults to using
273 separate directories for ``gcc`` and some kernel recipes.
274
Andrew Geisslerf0343792020-11-18 10:42:21 -0600275 :term:`BAD_RECOMMENDATIONS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500276 Lists "recommended-only" packages to not install. Recommended-only
277 packages are packages installed only through the
278 :term:`RRECOMMENDS` variable. You can prevent any
279 of these "recommended" packages from being installed by listing them
280 with the ``BAD_RECOMMENDATIONS`` variable:
281 ::
282
283 BAD_RECOMMENDATIONS = "package_name package_name package_name ..."
284
285 You can set this variable globally in your ``local.conf`` file or you
286 can attach it to a specific image recipe by using the recipe name
287 override:
288 ::
289
290 BAD_RECOMMENDATIONS_pn-target_image = "package_name"
291
292 It is important to realize that if you choose to not install packages
293 using this variable and some other packages are dependent on them
294 (i.e. listed in a recipe's :term:`RDEPENDS`
295 variable), the OpenEmbedded build system ignores your request and
296 will install the packages to avoid dependency errors.
297
298 Support for this variable exists only when using the IPK and RPM
299 packaging backend. Support does not exist for DEB.
300
301 See the :term:`NO_RECOMMENDATIONS` and the
302 :term:`PACKAGE_EXCLUDE` variables for related
303 information.
304
Andrew Geisslerf0343792020-11-18 10:42:21 -0600305 :term:`BASE_LIB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500306 The library directory name for the CPU or Application Binary
307 Interface (ABI) tune. The ``BASE_LIB`` applies only in the Multilib
308 context. See the ":ref:`dev-manual/dev-manual-common-tasks:combining multiple versions of library files into one image`"
309 section in the Yocto Project Development Tasks Manual for information
310 on Multilib.
311
312 The ``BASE_LIB`` variable is defined in the machine include files in
313 the :term:`Source Directory`. If Multilib is not
314 being used, the value defaults to "lib".
315
Andrew Geisslerf0343792020-11-18 10:42:21 -0600316 :term:`BASE_WORKDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500317 Points to the base of the work directory for all recipes. The default
318 value is "${TMPDIR}/work".
319
Andrew Geisslerf0343792020-11-18 10:42:21 -0600320 :term:`BB_ALLOWED_NETWORKS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500321 Specifies a space-delimited list of hosts that the fetcher is allowed
322 to use to obtain the required source code. Following are
323 considerations surrounding this variable:
324
325 - This host list is only used if ``BB_NO_NETWORK`` is either not set
326 or set to "0".
327
328 - Limited support for wildcard matching against the beginning of
329 host names exists. For example, the following setting matches
330 ``git.gnu.org``, ``ftp.gnu.org``, and ``foo.git.gnu.org``.
331 ::
332
333 BB_ALLOWED_NETWORKS = "*.gnu.org"
334
335 .. note::
336
337 The use of the "``*``" character only works at the beginning of
338 a host name and it must be isolated from the remainder of the
339 host name. You cannot use the wildcard character in any other
340 location of the name or combined with the front part of the
341 name.
342
343 For example, ``*.foo.bar`` is supported, while ``*aa.foo.bar``
344 is not.
345
346 - Mirrors not in the host list are skipped and logged in debug.
347
348 - Attempts to access networks not in the host list cause a failure.
349
350 Using ``BB_ALLOWED_NETWORKS`` in conjunction with
351 :term:`PREMIRRORS` is very useful. Adding the host
352 you want to use to ``PREMIRRORS`` results in the source code being
353 fetched from an allowed location and avoids raising an error when a
354 host that is not allowed is in a :term:`SRC_URI`
355 statement. This is because the fetcher does not attempt to use the
356 host listed in ``SRC_URI`` after a successful fetch from the
357 ``PREMIRRORS`` occurs.
358
Andrew Geisslerf0343792020-11-18 10:42:21 -0600359 :term:`BB_DANGLINGAPPENDS_WARNONLY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500360 Defines how BitBake handles situations where an append file
361 (``.bbappend``) has no corresponding recipe file (``.bb``). This
362 condition often occurs when layers get out of sync (e.g. ``oe-core``
363 bumps a recipe version and the old recipe no longer exists and the
364 other layer has not been updated to the new version of the recipe
365 yet).
366
367 The default fatal behavior is safest because it is the sane reaction
368 given something is out of sync. It is important to realize when your
369 changes are no longer being applied.
370
371 You can change the default behavior by setting this variable to "1",
372 "yes", or "true" in your ``local.conf`` file, which is located in the
373 :term:`Build Directory`: Here is an example:
374 ::
375
376 BB_DANGLINGAPPENDS_WARNONLY = "1"
377
Andrew Geisslerf0343792020-11-18 10:42:21 -0600378 :term:`BB_DISKMON_DIRS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500379 Monitors disk space and available inodes during the build and allows
380 you to control the build based on these parameters.
381
382 Disk space monitoring is disabled by default. To enable monitoring,
383 add the ``BB_DISKMON_DIRS`` variable to your ``conf/local.conf`` file
384 found in the :term:`Build Directory`. Use the
385 following form:
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500386
387 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500388
389 BB_DISKMON_DIRS = "action,dir,threshold [...]"
390
391 where:
392
393 action is:
394 ABORT: Immediately abort the build when
395 a threshold is broken.
396 STOPTASKS: Stop the build after the currently
397 executing tasks have finished when
398 a threshold is broken.
399 WARN: Issue a warning but continue the
400 build when a threshold is broken.
401 Subsequent warnings are issued as
402 defined by the BB_DISKMON_WARNINTERVAL
403 variable, which must be defined in
404 the conf/local.conf file.
405
406 dir is:
407 Any directory you choose. You can specify one or
408 more directories to monitor by separating the
409 groupings with a space. If two directories are
410 on the same device, only the first directory
411 is monitored.
412
413 threshold is:
414 Either the minimum available disk space,
415 the minimum number of free inodes, or
416 both. You must specify at least one. To
417 omit one or the other, simply omit the value.
418 Specify the threshold using G, M, K for Gbytes,
419 Mbytes, and Kbytes, respectively. If you do
420 not specify G, M, or K, Kbytes is assumed by
421 default. Do not use GB, MB, or KB.
422
423 Here are some examples:
424 ::
425
426 BB_DISKMON_DIRS = "ABORT,${TMPDIR},1G,100K WARN,${SSTATE_DIR},1G,100K"
427 BB_DISKMON_DIRS = "STOPTASKS,${TMPDIR},1G"
428 BB_DISKMON_DIRS = "ABORT,${TMPDIR},,100K"
429
430 The first example works only if you also provide the
431 :term:`BB_DISKMON_WARNINTERVAL`
432 variable in the ``conf/local.conf``. This example causes the build
433 system to immediately abort when either the disk space in
434 ``${TMPDIR}`` drops below 1 Gbyte or the available free inodes drops
435 below 100 Kbytes. Because two directories are provided with the
436 variable, the build system also issue a warning when the disk space
437 in the ``${SSTATE_DIR}`` directory drops below 1 Gbyte or the number
438 of free inodes drops below 100 Kbytes. Subsequent warnings are issued
439 during intervals as defined by the ``BB_DISKMON_WARNINTERVAL``
440 variable.
441
442 The second example stops the build after all currently executing
443 tasks complete when the minimum disk space in the ``${TMPDIR}``
444 directory drops below 1 Gbyte. No disk monitoring occurs for the free
445 inodes in this case.
446
447 The final example immediately aborts the build when the number of
448 free inodes in the ``${TMPDIR}`` directory drops below 100 Kbytes. No
449 disk space monitoring for the directory itself occurs in this case.
450
Andrew Geisslerf0343792020-11-18 10:42:21 -0600451 :term:`BB_DISKMON_WARNINTERVAL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500452 Defines the disk space and free inode warning intervals. To set these
453 intervals, define the variable in your ``conf/local.conf`` file in
454 the :term:`Build Directory`.
455
456 If you are going to use the ``BB_DISKMON_WARNINTERVAL`` variable, you
457 must also use the :term:`BB_DISKMON_DIRS`
458 variable and define its action as "WARN". During the build,
459 subsequent warnings are issued each time disk space or number of free
460 inodes further reduces by the respective interval.
461
462 If you do not provide a ``BB_DISKMON_WARNINTERVAL`` variable and you
463 do use ``BB_DISKMON_DIRS`` with the "WARN" action, the disk
464 monitoring interval defaults to the following:
465 ::
466
467 BB_DISKMON_WARNINTERVAL = "50M,5K"
468
469 When specifying the variable in your configuration file, use the
470 following form:
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500471
472 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500473
474 BB_DISKMON_WARNINTERVAL = "disk_space_interval,disk_inode_interval"
475
476 where:
477
478 disk_space_interval is:
479 An interval of memory expressed in either
480 G, M, or K for Gbytes, Mbytes, or Kbytes,
481 respectively. You cannot use GB, MB, or KB.
482
483 disk_inode_interval is:
484 An interval of free inodes expressed in either
485 G, M, or K for Gbytes, Mbytes, or Kbytes,
486 respectively. You cannot use GB, MB, or KB.
487
488 Here is an example:
489 ::
490
491 BB_DISKMON_DIRS = "WARN,${SSTATE_DIR},1G,100K"
492 BB_DISKMON_WARNINTERVAL = "50M,5K"
493
494 These variables cause the
495 OpenEmbedded build system to issue subsequent warnings each time the
496 available disk space further reduces by 50 Mbytes or the number of
497 free inodes further reduces by 5 Kbytes in the ``${SSTATE_DIR}``
498 directory. Subsequent warnings based on the interval occur each time
499 a respective interval is reached beyond the initial warning (i.e. 1
500 Gbytes and 100 Kbytes).
501
Andrew Geisslerf0343792020-11-18 10:42:21 -0600502 :term:`BB_GENERATE_MIRROR_TARBALLS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500503 Causes tarballs of the source control repositories (e.g. Git
504 repositories), including metadata, to be placed in the
505 :term:`DL_DIR` directory.
506
507 For performance reasons, creating and placing tarballs of these
508 repositories is not the default action by the OpenEmbedded build
509 system.
510 ::
511
512 BB_GENERATE_MIRROR_TARBALLS = "1"
513
514 Set this variable in your
515 ``local.conf`` file in the :term:`Build Directory`.
516
517 Once you have the tarballs containing your source files, you can
518 clean up your ``DL_DIR`` directory by deleting any Git or other
519 source control work directories.
520
Andrew Geisslerf0343792020-11-18 10:42:21 -0600521 :term:`BB_NUMBER_THREADS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500522 The maximum number of tasks BitBake should run in parallel at any one
523 time. The OpenEmbedded build system automatically configures this
524 variable to be equal to the number of cores on the build system. For
525 example, a system with a dual core processor that also uses
526 hyper-threading causes the ``BB_NUMBER_THREADS`` variable to default
527 to "4".
528
529 For single socket systems (i.e. one CPU), you should not have to
530 override this variable to gain optimal parallelism during builds.
531 However, if you have very large systems that employ multiple physical
532 CPUs, you might want to make sure the ``BB_NUMBER_THREADS`` variable
533 is not set higher than "20".
534
535 For more information on speeding up builds, see the
536 ":ref:`dev-manual/dev-manual-common-tasks:speeding up a build`"
537 section in the Yocto Project Development Tasks Manual.
538
Andrew Geisslerf0343792020-11-18 10:42:21 -0600539 :term:`BB_SERVER_TIMEOUT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500540 Specifies the time (in seconds) after which to unload the BitBake
541 server due to inactivity. Set ``BB_SERVER_TIMEOUT`` to determine how
542 long the BitBake server stays resident between invocations.
543
544 For example, the following statement in your ``local.conf`` file
545 instructs the server to be unloaded after 20 seconds of inactivity:
546 ::
547
548 BB_SERVER_TIMEOUT = "20"
549
550 If you want the server to never be unloaded,
551 set ``BB_SERVER_TIMEOUT`` to "-1".
552
Andrew Geisslerf0343792020-11-18 10:42:21 -0600553 :term:`BBCLASSEXTEND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500554 Allows you to extend a recipe so that it builds variants of the
555 software. Common variants for recipes exist such as "natives" like
556 ``quilt-native``, which is a copy of Quilt built to run on the build
557 system; "crosses" such as ``gcc-cross``, which is a compiler built to
558 run on the build machine but produces binaries that run on the target
559 :term:`MACHINE`; "nativesdk", which targets the SDK
560 machine instead of ``MACHINE``; and "mulitlibs" in the form
561 "``multilib:``\ multilib_name".
562
563 To build a different variant of the recipe with a minimal amount of
564 code, it usually is as simple as adding the following to your recipe:
565 ::
566
567 BBCLASSEXTEND =+ "native nativesdk"
568 BBCLASSEXTEND =+ "multilib:multilib_name"
569
570 .. note::
571
572 Internally, the ``BBCLASSEXTEND`` mechanism generates recipe
573 variants by rewriting variable values and applying overrides such
574 as ``_class-native``. For example, to generate a native version of
575 a recipe, a :term:`DEPENDS` on "foo" is rewritten
576 to a ``DEPENDS`` on "foo-native".
577
578 Even when using ``BBCLASSEXTEND``, the recipe is only parsed once.
579 Parsing once adds some limitations. For example, it is not
580 possible to include a different file depending on the variant,
581 since ``include`` statements are processed when the recipe is
582 parsed.
583
Andrew Geisslerf0343792020-11-18 10:42:21 -0600584 :term:`BBFILE_COLLECTIONS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500585 Lists the names of configured layers. These names are used to find
586 the other ``BBFILE_*`` variables. Typically, each layer will append
587 its name to this variable in its ``conf/layer.conf`` file.
588
Andrew Geisslerf0343792020-11-18 10:42:21 -0600589 :term:`BBFILE_PATTERN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500590 Variable that expands to match files from
591 :term:`BBFILES` in a particular layer. This variable
592 is used in the ``conf/layer.conf`` file and must be suffixed with the
593 name of the specific layer (e.g. ``BBFILE_PATTERN_emenlow``).
594
Andrew Geisslerf0343792020-11-18 10:42:21 -0600595 :term:`BBFILE_PRIORITY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500596 Assigns the priority for recipe files in each layer.
597
598 This variable is useful in situations where the same recipe appears
599 in more than one layer. Setting this variable allows you to
600 prioritize a layer against other layers that contain the same recipe
601 - effectively letting you control the precedence for the multiple
602 layers. The precedence established through this variable stands
603 regardless of a recipe's version (:term:`PV` variable). For
604 example, a layer that has a recipe with a higher ``PV`` value but for
605 which the ``BBFILE_PRIORITY`` is set to have a lower precedence still
606 has a lower precedence.
607
608 A larger value for the ``BBFILE_PRIORITY`` variable results in a
609 higher precedence. For example, the value 6 has a higher precedence
610 than the value 5. If not specified, the ``BBFILE_PRIORITY`` variable
611 is set based on layer dependencies (see the ``LAYERDEPENDS`` variable
612 for more information. The default priority, if unspecified for a
613 layer with no dependencies, is the lowest defined priority + 1 (or 1
614 if no priorities are defined).
615
616 .. tip::
617
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500618 You can use the command ``bitbake-layers show-layers``
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500619 to list all configured layers along with their priorities.
620
Andrew Geisslerf0343792020-11-18 10:42:21 -0600621 :term:`BBFILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500622 A space-separated list of recipe files BitBake uses to build
623 software.
624
625 When specifying recipe files, you can pattern match using Python's
626 `glob <https://docs.python.org/3/library/glob.html>`_ syntax.
627 For details on the syntax, see the documentation by following the
628 previous link.
629
Andrew Geisslerf0343792020-11-18 10:42:21 -0600630 :term:`BBFILES_DYNAMIC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500631 Activates content when identified layers are present. You identify
632 the layers by the collections that the layers define.
633
634 Use the ``BBFILES_DYNAMIC`` variable to avoid ``.bbappend`` files
635 whose corresponding ``.bb`` file is in a layer that attempts to
636 modify other layers through ``.bbappend`` but does not want to
637 introduce a hard dependency on those other layers.
638
639 Use the following form for ``BBFILES_DYNAMIC``:
640 collection_name:filename_pattern The following example identifies two
641 collection names and two filename patterns:
642 ::
643
644 BBFILES_DYNAMIC += " \
645 clang-layer:${LAYERDIR}/bbappends/meta-clang/*/*/*.bbappend \
646 core:${LAYERDIR}/bbappends/openembedded-core/meta/*/*/*.bbappend \
647 "
648
649 This next example shows an error message that occurs because invalid
650 entries are found, which cause parsing to abort:
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500651
652 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500653
654 ERROR: BBFILES_DYNAMIC entries must be of the form <collection name>:<filename pattern>, not:
655 /work/my-layer/bbappends/meta-security-isafw/*/*/*.bbappend
656 /work/my-layer/bbappends/openembedded-core/meta/*/*/*.bbappend
657
Andrew Geisslerf0343792020-11-18 10:42:21 -0600658 :term:`BBINCLUDELOGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500659 Variable that controls how BitBake displays logs on build failure.
660
Andrew Geisslerf0343792020-11-18 10:42:21 -0600661 :term:`BBINCLUDELOGS_LINES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500662 If :term:`BBINCLUDELOGS` is set, specifies the
663 maximum number of lines from the task log file to print when
664 reporting a failed task. If you do not set ``BBINCLUDELOGS_LINES``,
665 the entire log is printed.
666
Andrew Geisslerf0343792020-11-18 10:42:21 -0600667 :term:`BBLAYERS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500668 Lists the layers to enable during the build. This variable is defined
669 in the ``bblayers.conf`` configuration file in the :term:`Build Directory`.
670 Here is an example:
671 ::
672
673 BBLAYERS = " \
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500674 /home/scottrif/poky/meta \
675 /home/scottrif/poky/meta-poky \
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500676 /home/scottrif/poky/meta-yocto-bsp \
677 /home/scottrif/poky/meta-mykernel \
678 "
679
680 This example enables four layers, one of which is a custom,
681 user-defined layer named ``meta-mykernel``.
682
Andrew Geisslerf0343792020-11-18 10:42:21 -0600683 :term:`BBMASK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500684 Prevents BitBake from processing recipes and recipe append files.
685
686 You can use the ``BBMASK`` variable to "hide" these ``.bb`` and
687 ``.bbappend`` files. BitBake ignores any recipe or recipe append
688 files that match any of the expressions. It is as if BitBake does not
689 see them at all. Consequently, matching files are not parsed or
690 otherwise used by BitBake.
691
692 The values you provide are passed to Python's regular expression
693 compiler. Consequently, the syntax follows Python's Regular
694 Expression (re) syntax. The expressions are compared against the full
695 paths to the files. For complete syntax information, see Python's
Andrew Geisslerc3d88e42020-10-02 09:45:00 -0500696 documentation at https://docs.python.org/3/library/re.html#regular-expression-syntax.
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500697
698 The following example uses a complete regular expression to tell
699 BitBake to ignore all recipe and recipe append files in the
700 ``meta-ti/recipes-misc/`` directory:
701 ::
702
703 BBMASK = "meta-ti/recipes-misc/"
704
705 If you want to mask out multiple directories or recipes, you can
706 specify multiple regular expression fragments. This next example
707 masks out multiple directories and individual recipes: ::
708
709 BBMASK += "/meta-ti/recipes-misc/ meta-ti/recipes-ti/packagegroup/"
710 BBMASK += "/meta-oe/recipes-support/"
711 BBMASK += "/meta-foo/.*/openldap"
712 BBMASK += "opencv.*\.bbappend"
713 BBMASK += "lzma"
714
715 .. note::
716
717 When specifying a directory name, use the trailing slash character
718 to ensure you match just that directory name.
719
Andrew Geisslerf0343792020-11-18 10:42:21 -0600720 :term:`BBMULTICONFIG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500721 Specifies each additional separate configuration when you are
722 building targets with multiple configurations. Use this variable in
723 your ``conf/local.conf`` configuration file. Specify a
724 multiconfigname for each configuration file you are using. For
725 example, the following line specifies three configuration files:
726 ::
727
728 BBMULTICONFIG = "configA configB configC"
729
730 Each configuration file you
731 use must reside in the :term:`Build Directory`
732 ``conf/multiconfig`` directory (e.g.
733 build_directory\ ``/conf/multiconfig/configA.conf``).
734
735 For information on how to use ``BBMULTICONFIG`` in an environment
736 that supports building targets with multiple configurations, see the
737 ":ref:`dev-building-images-for-multiple-targets-using-multiple-configurations`"
738 section in the Yocto Project Development Tasks Manual.
739
Andrew Geisslerf0343792020-11-18 10:42:21 -0600740 :term:`BBPATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500741 Used by BitBake to locate ``.bbclass`` and configuration files. This
742 variable is analogous to the ``PATH`` variable.
743
744 .. note::
745
746 If you run BitBake from a directory outside of the
747 Build Directory
748 , you must be sure to set
749 BBPATH
750 to point to the Build Directory. Set the variable as you would any
751 environment variable and then run BitBake:
752 ::
753
754 $ BBPATH = "build_directory"
755 $ export BBPATH
756 $ bitbake target
757
758
Andrew Geisslerf0343792020-11-18 10:42:21 -0600759 :term:`BBSERVER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500760 If defined in the BitBake environment, ``BBSERVER`` points to the
761 BitBake remote server.
762
763 Use the following format to export the variable to the BitBake
764 environment:
765 ::
766
767 export BBSERVER=localhost:$port
768
769 By default, ``BBSERVER`` also appears in
770 :term:`bitbake:BB_HASHBASE_WHITELIST`.
771 Consequently, ``BBSERVER`` is excluded from checksum and dependency
772 data.
773
Andrew Geisslerf0343792020-11-18 10:42:21 -0600774 :term:`BINCONFIG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500775 When inheriting the
776 :ref:`binconfig-disabled <ref-classes-binconfig-disabled>` class,
777 this variable specifies binary configuration scripts to disable in
778 favor of using ``pkg-config`` to query the information. The
779 ``binconfig-disabled`` class will modify the specified scripts to
780 return an error so that calls to them can be easily found and
781 replaced.
782
783 To add multiple scripts, separate them by spaces. Here is an example
784 from the ``libpng`` recipe:
785 ::
786
787 BINCONFIG = "${bindir}/libpng-config ${bindir}/libpng16-config"
788
Andrew Geisslerf0343792020-11-18 10:42:21 -0600789 :term:`BINCONFIG_GLOB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500790 When inheriting the :ref:`binconfig <ref-classes-binconfig>` class,
791 this variable specifies a wildcard for configuration scripts that
792 need editing. The scripts are edited to correct any paths that have
793 been set up during compilation so that they are correct for use when
794 installed into the sysroot and called by the build processes of other
795 recipes.
796
797 .. note::
798
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500799 The ``BINCONFIG_GLOB`` variable uses
800 `shell globbing <https://tldp.org/LDP/abs/html/globbingref.html>`__,
801 which is recognition and expansion of wildcards during pattern
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500802 matching. Shell globbing is very similar to
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500803 `fnmatch <https://docs.python.org/3/library/fnmatch.html#module-fnmatch>`__
804 and `glob <https://docs.python.org/3/library/glob.html>`__.
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500805
806 For more information on how this variable works, see
807 ``meta/classes/binconfig.bbclass`` in the :term:`Source Directory`.
808 You can also find general
809 information on the class in the
810 ":ref:`binconfig.bbclass <ref-classes-binconfig>`" section.
811
Andrew Geisslerf0343792020-11-18 10:42:21 -0600812 :term:`BP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500813 The base recipe name and version but without any special recipe name
814 suffix (i.e. ``-native``, ``lib64-``, and so forth). ``BP`` is
815 comprised of the following:
816 ::
817
818 ${BPN}-${PV}
819
Andrew Geisslerf0343792020-11-18 10:42:21 -0600820 :term:`BPN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500821 This variable is a version of the :term:`PN` variable with
822 common prefixes and suffixes removed, such as ``nativesdk-``,
823 ``-cross``, ``-native``, and multilib's ``lib64-`` and ``lib32-``.
824 The exact lists of prefixes and suffixes removed are specified by the
825 :term:`MLPREFIX` and
826 :term:`SPECIAL_PKGSUFFIX` variables,
827 respectively.
828
Andrew Geisslerf0343792020-11-18 10:42:21 -0600829 :term:`BUGTRACKER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500830 Specifies a URL for an upstream bug tracking website for a recipe.
831 The OpenEmbedded build system does not use this variable. Rather, the
832 variable is a useful pointer in case a bug in the software being
833 built needs to be manually reported.
834
Andrew Geisslerf0343792020-11-18 10:42:21 -0600835 :term:`BUILD_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500836 Specifies the architecture of the build host (e.g. ``i686``). The
837 OpenEmbedded build system sets the value of ``BUILD_ARCH`` from the
838 machine name reported by the ``uname`` command.
839
Andrew Geisslerf0343792020-11-18 10:42:21 -0600840 :term:`BUILD_AS_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500841 Specifies the architecture-specific assembler flags for the build
842 host. By default, the value of ``BUILD_AS_ARCH`` is empty.
843
Andrew Geisslerf0343792020-11-18 10:42:21 -0600844 :term:`BUILD_CC_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500845 Specifies the architecture-specific C compiler flags for the build
846 host. By default, the value of ``BUILD_CC_ARCH`` is empty.
847
Andrew Geisslerf0343792020-11-18 10:42:21 -0600848 :term:`BUILD_CCLD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500849 Specifies the linker command to be used for the build host when the C
850 compiler is being used as the linker. By default, ``BUILD_CCLD``
851 points to GCC and passes as arguments the value of
852 :term:`BUILD_CC_ARCH`, assuming
853 ``BUILD_CC_ARCH`` is set.
854
Andrew Geisslerf0343792020-11-18 10:42:21 -0600855 :term:`BUILD_CFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500856 Specifies the flags to pass to the C compiler when building for the
857 build host. When building in the ``-native`` context,
858 :term:`CFLAGS` is set to the value of this variable by
859 default.
860
Andrew Geisslerf0343792020-11-18 10:42:21 -0600861 :term:`BUILD_CPPFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500862 Specifies the flags to pass to the C preprocessor (i.e. to both the C
863 and the C++ compilers) when building for the build host. When
864 building in the ``-native`` context, :term:`CPPFLAGS`
865 is set to the value of this variable by default.
866
Andrew Geisslerf0343792020-11-18 10:42:21 -0600867 :term:`BUILD_CXXFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500868 Specifies the flags to pass to the C++ compiler when building for the
869 build host. When building in the ``-native`` context,
870 :term:`CXXFLAGS` is set to the value of this variable
871 by default.
872
Andrew Geisslerf0343792020-11-18 10:42:21 -0600873 :term:`BUILD_FC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500874 Specifies the Fortran compiler command for the build host. By
875 default, ``BUILD_FC`` points to Gfortran and passes as arguments the
876 value of :term:`BUILD_CC_ARCH`, assuming
877 ``BUILD_CC_ARCH`` is set.
878
Andrew Geisslerf0343792020-11-18 10:42:21 -0600879 :term:`BUILD_LD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500880 Specifies the linker command for the build host. By default,
881 ``BUILD_LD`` points to the GNU linker (ld) and passes as arguments
882 the value of :term:`BUILD_LD_ARCH`, assuming
883 ``BUILD_LD_ARCH`` is set.
884
Andrew Geisslerf0343792020-11-18 10:42:21 -0600885 :term:`BUILD_LD_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500886 Specifies architecture-specific linker flags for the build host. By
887 default, the value of ``BUILD_LD_ARCH`` is empty.
888
Andrew Geisslerf0343792020-11-18 10:42:21 -0600889 :term:`BUILD_LDFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500890 Specifies the flags to pass to the linker when building for the build
891 host. When building in the ``-native`` context,
892 :term:`LDFLAGS` is set to the value of this variable
893 by default.
894
Andrew Geisslerf0343792020-11-18 10:42:21 -0600895 :term:`BUILD_OPTIMIZATION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500896 Specifies the optimization flags passed to the C compiler when
897 building for the build host or the SDK. The flags are passed through
898 the :term:`BUILD_CFLAGS` and
899 :term:`BUILDSDK_CFLAGS` default values.
900
901 The default value of the ``BUILD_OPTIMIZATION`` variable is "-O2
902 -pipe".
903
Andrew Geisslerf0343792020-11-18 10:42:21 -0600904 :term:`BUILD_OS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500905 Specifies the operating system in use on the build host (e.g.
906 "linux"). The OpenEmbedded build system sets the value of
907 ``BUILD_OS`` from the OS reported by the ``uname`` command - the
908 first word, converted to lower-case characters.
909
Andrew Geisslerf0343792020-11-18 10:42:21 -0600910 :term:`BUILD_PREFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500911 The toolchain binary prefix used for native recipes. The OpenEmbedded
912 build system uses the ``BUILD_PREFIX`` value to set the
913 :term:`TARGET_PREFIX` when building for
914 ``native`` recipes.
915
Andrew Geisslerf0343792020-11-18 10:42:21 -0600916 :term:`BUILD_STRIP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500917 Specifies the command to be used to strip debugging symbols from
918 binaries produced for the build host. By default, ``BUILD_STRIP``
919 points to
920 ``${``\ :term:`BUILD_PREFIX`\ ``}strip``.
921
Andrew Geisslerf0343792020-11-18 10:42:21 -0600922 :term:`BUILD_SYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500923 Specifies the system, including the architecture and the operating
924 system, to use when building for the build host (i.e. when building
925 ``native`` recipes).
926
927 The OpenEmbedded build system automatically sets this variable based
928 on :term:`BUILD_ARCH`,
929 :term:`BUILD_VENDOR`, and
930 :term:`BUILD_OS`. You do not need to set the
931 ``BUILD_SYS`` variable yourself.
932
Andrew Geisslerf0343792020-11-18 10:42:21 -0600933 :term:`BUILD_VENDOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500934 Specifies the vendor name to use when building for the build host.
935 The default value is an empty string ("").
936
Andrew Geisslerf0343792020-11-18 10:42:21 -0600937 :term:`BUILDDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500938 Points to the location of the :term:`Build Directory`.
939 You can define this directory indirectly through the
Andrew Geissler4c19ea12020-10-27 13:52:24 -0500940 :ref:`structure-core-script` script by passing in a Build
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500941 Directory path when you run the script. If you run the script and do
942 not provide a Build Directory path, the ``BUILDDIR`` defaults to
943 ``build`` in the current directory.
944
Andrew Geisslerf0343792020-11-18 10:42:21 -0600945 :term:`BUILDHISTORY_COMMIT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500946 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
947 class, this variable specifies whether or not to commit the build
948 history output in a local Git repository. If set to "1", this local
949 repository will be maintained automatically by the ``buildhistory``
950 class and a commit will be created on every build for changes to each
951 top-level subdirectory of the build history output (images, packages,
952 and sdk). If you want to track changes to build history over time,
953 you should set this value to "1".
954
955 By default, the ``buildhistory`` class does not commit the build
956 history output in a local Git repository:
957 ::
958
959 BUILDHISTORY_COMMIT ?= "0"
960
Andrew Geisslerf0343792020-11-18 10:42:21 -0600961 :term:`BUILDHISTORY_COMMIT_AUTHOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500962 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
963 class, this variable specifies the author to use for each Git commit.
964 In order for the ``BUILDHISTORY_COMMIT_AUTHOR`` variable to work, the
965 :term:`BUILDHISTORY_COMMIT` variable must
966 be set to "1".
967
968 Git requires that the value you provide for the
969 ``BUILDHISTORY_COMMIT_AUTHOR`` variable takes the form of "name
970 email@host". Providing an email address or host that is not valid
971 does not produce an error.
972
973 By default, the ``buildhistory`` class sets the variable as follows:
974 ::
975
976 BUILDHISTORY_COMMIT_AUTHOR ?= "buildhistory <buildhistory@${DISTRO}>"
977
Andrew Geisslerf0343792020-11-18 10:42:21 -0600978 :term:`BUILDHISTORY_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500979 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
980 class, this variable specifies the directory in which build history
981 information is kept. For more information on how the variable works,
982 see the ``buildhistory.class``.
983
984 By default, the ``buildhistory`` class sets the directory as follows:
985 ::
986
987 BUILDHISTORY_DIR ?= "${TOPDIR}/buildhistory"
988
Andrew Geisslerf0343792020-11-18 10:42:21 -0600989 :term:`BUILDHISTORY_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -0500990 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
991 class, this variable specifies the build history features to be
992 enabled. For more information on how build history works, see the
993 ":ref:`dev-manual/dev-manual-common-tasks:maintaining build output quality`"
994 section in the Yocto Project Development Tasks Manual.
995
996 You can specify these features in the form of a space-separated list:
997
998 - *image:* Analysis of the contents of images, which includes the
999 list of installed packages among other things.
1000
1001 - *package:* Analysis of the contents of individual packages.
1002
1003 - *sdk:* Analysis of the contents of the software development kit
1004 (SDK).
1005
1006 - *task:* Save output file signatures for
1007 :ref:`shared state <overview-manual/overview-manual-concepts:shared state cache>`
1008 (sstate) tasks.
1009 This saves one file per task and lists the SHA-256 checksums for
1010 each file staged (i.e. the output of the task).
1011
1012 By default, the ``buildhistory`` class enables the following
1013 features:
1014 ::
1015
1016 BUILDHISTORY_FEATURES ?= "image package sdk"
1017
Andrew Geisslerf0343792020-11-18 10:42:21 -06001018 :term:`BUILDHISTORY_IMAGE_FILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001019 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
1020 class, this variable specifies a list of paths to files copied from
1021 the image contents into the build history directory under an
1022 "image-files" directory in the directory for the image, so that you
1023 can track the contents of each file. The default is to copy
1024 ``/etc/passwd`` and ``/etc/group``, which allows you to monitor for
1025 changes in user and group entries. You can modify the list to include
1026 any file. Specifying an invalid path does not produce an error.
1027 Consequently, you can include files that might not always be present.
1028
1029 By default, the ``buildhistory`` class provides paths to the
1030 following files:
1031 ::
1032
1033 BUILDHISTORY_IMAGE_FILES ?= "/etc/passwd /etc/group"
1034
Andrew Geisslerf0343792020-11-18 10:42:21 -06001035 :term:`BUILDHISTORY_PUSH_REPO`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001036 When inheriting the :ref:`buildhistory <ref-classes-buildhistory>`
1037 class, this variable optionally specifies a remote repository to
1038 which build history pushes Git changes. In order for
1039 ``BUILDHISTORY_PUSH_REPO`` to work,
1040 :term:`BUILDHISTORY_COMMIT` must be set to
1041 "1".
1042
1043 The repository should correspond to a remote address that specifies a
1044 repository as understood by Git, or alternatively to a remote name
1045 that you have set up manually using ``git remote`` within the local
1046 repository.
1047
1048 By default, the ``buildhistory`` class sets the variable as follows:
1049 ::
1050
1051 BUILDHISTORY_PUSH_REPO ?= ""
1052
Andrew Geisslerf0343792020-11-18 10:42:21 -06001053 :term:`BUILDSDK_CFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001054 Specifies the flags to pass to the C compiler when building for the
1055 SDK. When building in the ``nativesdk-`` context,
1056 :term:`CFLAGS` is set to the value of this variable by
1057 default.
1058
Andrew Geisslerf0343792020-11-18 10:42:21 -06001059 :term:`BUILDSDK_CPPFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001060 Specifies the flags to pass to the C pre-processor (i.e. to both the
1061 C and the C++ compilers) when building for the SDK. When building in
1062 the ``nativesdk-`` context, :term:`CPPFLAGS` is set
1063 to the value of this variable by default.
1064
Andrew Geisslerf0343792020-11-18 10:42:21 -06001065 :term:`BUILDSDK_CXXFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001066 Specifies the flags to pass to the C++ compiler when building for the
1067 SDK. When building in the ``nativesdk-`` context,
1068 :term:`CXXFLAGS` is set to the value of this variable
1069 by default.
1070
Andrew Geisslerf0343792020-11-18 10:42:21 -06001071 :term:`BUILDSDK_LDFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001072 Specifies the flags to pass to the linker when building for the SDK.
1073 When building in the ``nativesdk-`` context,
1074 :term:`LDFLAGS` is set to the value of this variable
1075 by default.
1076
Andrew Geisslerf0343792020-11-18 10:42:21 -06001077 :term:`BUILDSTATS_BASE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001078 Points to the location of the directory that holds build statistics
1079 when you use and enable the
1080 :ref:`buildstats <ref-classes-buildstats>` class. The
1081 ``BUILDSTATS_BASE`` directory defaults to
1082 ``${``\ :term:`TMPDIR`\ ``}/buildstats/``.
1083
Andrew Geisslerf0343792020-11-18 10:42:21 -06001084 :term:`BUSYBOX_SPLIT_SUID`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001085 For the BusyBox recipe, specifies whether to split the output
1086 executable file into two parts: one for features that require
1087 ``setuid root``, and one for the remaining features (i.e. those that
1088 do not require ``setuid root``).
1089
1090 The ``BUSYBOX_SPLIT_SUID`` variable defaults to "1", which results in
1091 splitting the output executable file. Set the variable to "0" to get
1092 a single output executable file.
1093
Andrew Geisslerf0343792020-11-18 10:42:21 -06001094 :term:`CACHE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001095 Specifies the directory BitBake uses to store a cache of the
1096 :term:`Metadata` so it does not need to be parsed every time
1097 BitBake is started.
1098
Andrew Geisslerf0343792020-11-18 10:42:21 -06001099 :term:`CC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001100 The minimal command and arguments used to run the C compiler.
1101
Andrew Geisslerf0343792020-11-18 10:42:21 -06001102 :term:`CFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001103 Specifies the flags to pass to the C compiler. This variable is
1104 exported to an environment variable and thus made visible to the
1105 software being built during the compilation step.
1106
1107 Default initialization for ``CFLAGS`` varies depending on what is
1108 being built:
1109
1110 - :term:`TARGET_CFLAGS` when building for the
1111 target
1112
1113 - :term:`BUILD_CFLAGS` when building for the
1114 build host (i.e. ``-native``)
1115
1116 - :term:`BUILDSDK_CFLAGS` when building for
1117 an SDK (i.e. ``nativesdk-``)
1118
Andrew Geisslerf0343792020-11-18 10:42:21 -06001119 :term:`CLASSOVERRIDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001120 An internal variable specifying the special class override that
1121 should currently apply (e.g. "class-target", "class-native", and so
1122 forth). The classes that use this variable (e.g.
1123 :ref:`native <ref-classes-native>`,
1124 :ref:`nativesdk <ref-classes-nativesdk>`, and so forth) set the
1125 variable to appropriate values.
1126
1127 .. note::
1128
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001129 ``CLASSOVERRIDE`` gets its default "class-target" value from the
1130 ``bitbake.conf`` file.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001131
1132 As an example, the following override allows you to install extra
1133 files, but only when building for the target:
1134 ::
1135
1136 do_install_append_class-target() {
1137 install my-extra-file ${D}${sysconfdir}
1138 }
1139
1140 Here is an example where ``FOO`` is set to
1141 "native" when building for the build host, and to "other" when not
1142 building for the build host:
1143 ::
1144
1145 FOO_class-native = "native"
1146 FOO = "other"
1147
1148 The underlying mechanism behind ``CLASSOVERRIDE`` is simply
1149 that it is included in the default value of
1150 :term:`OVERRIDES`.
1151
Andrew Geisslerf0343792020-11-18 10:42:21 -06001152 :term:`CLEANBROKEN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001153 If set to "1" within a recipe, ``CLEANBROKEN`` specifies that the
1154 ``make clean`` command does not work for the software being built.
1155 Consequently, the OpenEmbedded build system will not try to run
1156 ``make clean`` during the :ref:`ref-tasks-configure`
1157 task, which is the default behavior.
1158
Andrew Geisslerf0343792020-11-18 10:42:21 -06001159 :term:`COMBINED_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001160 Provides a list of hardware features that are enabled in both
1161 :term:`MACHINE_FEATURES` and
1162 :term:`DISTRO_FEATURES`. This select list of
1163 features contains features that make sense to be controlled both at
1164 the machine and distribution configuration level. For example, the
1165 "bluetooth" feature requires hardware support but should also be
1166 optional at the distribution level, in case the hardware supports
1167 Bluetooth but you do not ever intend to use it.
1168
Andrew Geisslerf0343792020-11-18 10:42:21 -06001169 :term:`COMMON_LICENSE_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001170 Points to ``meta/files/common-licenses`` in the
1171 :term:`Source Directory`, which is where generic license
1172 files reside.
1173
Andrew Geisslerf0343792020-11-18 10:42:21 -06001174 :term:`COMPATIBLE_HOST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001175 A regular expression that resolves to one or more hosts (when the
1176 recipe is native) or one or more targets (when the recipe is
1177 non-native) with which a recipe is compatible. The regular expression
1178 is matched against :term:`HOST_SYS`. You can use the
1179 variable to stop recipes from being built for classes of systems with
1180 which the recipes are not compatible. Stopping these builds is
1181 particularly useful with kernels. The variable also helps to increase
1182 parsing speed since the build system skips parsing recipes not
1183 compatible with the current system.
1184
Andrew Geisslerf0343792020-11-18 10:42:21 -06001185 :term:`COMPATIBLE_MACHINE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001186 A regular expression that resolves to one or more target machines
1187 with which a recipe is compatible. The regular expression is matched
1188 against :term:`MACHINEOVERRIDES`. You can use
1189 the variable to stop recipes from being built for machines with which
1190 the recipes are not compatible. Stopping these builds is particularly
1191 useful with kernels. The variable also helps to increase parsing
1192 speed since the build system skips parsing recipes not compatible
1193 with the current machine.
1194
Andrew Geisslerf0343792020-11-18 10:42:21 -06001195 :term:`COMPLEMENTARY_GLOB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001196 Defines wildcards to match when installing a list of complementary
1197 packages for all the packages explicitly (or implicitly) installed in
1198 an image.
1199
1200 .. note::
1201
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001202 The ``COMPLEMENTARY_GLOB`` variable uses Unix filename pattern matching
1203 (`fnmatch <https://docs.python.org/3/library/fnmatch.html#module-fnmatch>`__),
1204 which is similar to the Unix style pathname pattern expansion
1205 (`glob <https://docs.python.org/3/library/glob.html>`__).
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001206
1207 The resulting list of complementary packages is associated with an
1208 item that can be added to
1209 :term:`IMAGE_FEATURES`. An example usage of
1210 this is the "dev-pkgs" item that when added to ``IMAGE_FEATURES``
1211 will install -dev packages (containing headers and other development
1212 files) for every package in the image.
1213
1214 To add a new feature item pointing to a wildcard, use a variable flag
1215 to specify the feature item name and use the value to specify the
1216 wildcard. Here is an example:
1217 ::
1218
1219 COMPLEMENTARY_GLOB[dev-pkgs] = '*-dev'
1220
Andrew Geisslerf0343792020-11-18 10:42:21 -06001221 :term:`COMPONENTS_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001222 Stores sysroot components for each recipe. The OpenEmbedded build
1223 system uses ``COMPONENTS_DIR`` when constructing recipe-specific
1224 sysroots for other recipes.
1225
1226 The default is
1227 "``${``\ :term:`STAGING_DIR`\ ``}-components``."
1228 (i.e.
1229 "``${``\ :term:`TMPDIR`\ ``}/sysroots-components``").
1230
Andrew Geisslerf0343792020-11-18 10:42:21 -06001231 :term:`CONF_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001232 Tracks the version of the local configuration file (i.e.
1233 ``local.conf``). The value for ``CONF_VERSION`` increments each time
1234 ``build/conf/`` compatibility changes.
1235
Andrew Geisslerf0343792020-11-18 10:42:21 -06001236 :term:`CONFFILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001237 Identifies editable or configurable files that are part of a package.
1238 If the Package Management System (PMS) is being used to update
1239 packages on the target system, it is possible that configuration
1240 files you have changed after the original installation and that you
1241 now want to remain unchanged are overwritten. In other words,
1242 editable files might exist in the package that you do not want reset
1243 as part of the package update process. You can use the ``CONFFILES``
1244 variable to list the files in the package that you wish to prevent
1245 the PMS from overwriting during this update process.
1246
1247 To use the ``CONFFILES`` variable, provide a package name override
1248 that identifies the resulting package. Then, provide a
1249 space-separated list of files. Here is an example:
1250 ::
1251
1252 CONFFILES_${PN} += "${sysconfdir}/file1 \
1253 ${sysconfdir}/file2 ${sysconfdir}/file3"
1254
1255 A relationship exists between the ``CONFFILES`` and ``FILES``
1256 variables. The files listed within ``CONFFILES`` must be a subset of
1257 the files listed within ``FILES``. Because the configuration files
1258 you provide with ``CONFFILES`` are simply being identified so that
1259 the PMS will not overwrite them, it makes sense that the files must
1260 already be included as part of the package through the ``FILES``
1261 variable.
1262
1263 .. note::
1264
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001265 When specifying paths as part of the ``CONFFILES`` variable, it is
1266 good practice to use appropriate path variables.
1267 For example, ``${sysconfdir}`` rather than ``/etc`` or ``${bindir}``
1268 rather than ``/usr/bin``. You can find a list of these variables at
1269 the top of the ``meta/conf/bitbake.conf`` file in the
1270 :term:`Source Directory`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001271
Andrew Geisslerf0343792020-11-18 10:42:21 -06001272 :term:`CONFIG_INITRAMFS_SOURCE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001273 Identifies the initial RAM filesystem (initramfs) source files. The
1274 OpenEmbedded build system receives and uses this kernel Kconfig
1275 variable as an environment variable. By default, the variable is set
1276 to null ("").
1277
1278 The ``CONFIG_INITRAMFS_SOURCE`` can be either a single cpio archive
1279 with a ``.cpio`` suffix or a space-separated list of directories and
1280 files for building the initramfs image. A cpio archive should contain
1281 a filesystem archive to be used as an initramfs image. Directories
1282 should contain a filesystem layout to be included in the initramfs
1283 image. Files should contain entries according to the format described
1284 by the ``usr/gen_init_cpio`` program in the kernel tree.
1285
1286 If you specify multiple directories and files, the initramfs image
1287 will be the aggregate of all of them.
1288
1289 For information on creating an initramfs, see the
1290 ":ref:`building-an-initramfs-image`" section
1291 in the Yocto Project Development Tasks Manual.
1292
Andrew Geisslerf0343792020-11-18 10:42:21 -06001293 :term:`CONFIG_SITE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001294 A list of files that contains ``autoconf`` test results relevant to
1295 the current build. This variable is used by the Autotools utilities
1296 when running ``configure``.
1297
Andrew Geisslerf0343792020-11-18 10:42:21 -06001298 :term:`CONFIGURE_FLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001299 The minimal arguments for GNU configure.
1300
Andrew Geisslerf0343792020-11-18 10:42:21 -06001301 :term:`CONFLICT_DISTRO_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001302 When inheriting the
1303 :ref:`distro_features_check <ref-classes-distro_features_check>`
1304 class, this variable identifies distribution features that would be
1305 in conflict should the recipe be built. In other words, if the
1306 ``CONFLICT_DISTRO_FEATURES`` variable lists a feature that also
1307 appears in ``DISTRO_FEATURES`` within the current configuration, an
1308 error occurs and the build stops.
1309
Andrew Geisslerf0343792020-11-18 10:42:21 -06001310 :term:`COPYLEFT_LICENSE_EXCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001311 A space-separated list of licenses to exclude from the source
1312 archived by the :ref:`archiver <ref-classes-archiver>` class. In
1313 other words, if a license in a recipe's
1314 :term:`LICENSE` value is in the value of
1315 ``COPYLEFT_LICENSE_EXCLUDE``, then its source is not archived by the
1316 class.
1317
1318 .. note::
1319
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001320 The ``COPYLEFT_LICENSE_EXCLUDE`` variable takes precedence over the
1321 :term:`COPYLEFT_LICENSE_INCLUDE` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001322
1323 The default value, which is "CLOSED Proprietary", for
1324 ``COPYLEFT_LICENSE_EXCLUDE`` is set by the
1325 :ref:`copyleft_filter <ref-classes-copyleft_filter>` class, which
1326 is inherited by the ``archiver`` class.
1327
Andrew Geisslerf0343792020-11-18 10:42:21 -06001328 :term:`COPYLEFT_LICENSE_INCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001329 A space-separated list of licenses to include in the source archived
1330 by the :ref:`archiver <ref-classes-archiver>` class. In other
1331 words, if a license in a recipe's :term:`LICENSE`
1332 value is in the value of ``COPYLEFT_LICENSE_INCLUDE``, then its
1333 source is archived by the class.
1334
1335 The default value is set by the
1336 :ref:`copyleft_filter <ref-classes-copyleft_filter>` class, which
1337 is inherited by the ``archiver`` class. The default value includes
1338 "GPL*", "LGPL*", and "AGPL*".
1339
Andrew Geisslerf0343792020-11-18 10:42:21 -06001340 :term:`COPYLEFT_PN_EXCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001341 A list of recipes to exclude in the source archived by the
1342 :ref:`archiver <ref-classes-archiver>` class. The
1343 ``COPYLEFT_PN_EXCLUDE`` variable overrides the license inclusion and
1344 exclusion caused through the
1345 :term:`COPYLEFT_LICENSE_INCLUDE` and
1346 :term:`COPYLEFT_LICENSE_EXCLUDE`
1347 variables, respectively.
1348
1349 The default value, which is "" indicating to not explicitly exclude
1350 any recipes by name, for ``COPYLEFT_PN_EXCLUDE`` is set by the
1351 :ref:`copyleft_filter <ref-classes-copyleft_filter>` class, which
1352 is inherited by the ``archiver`` class.
1353
Andrew Geisslerf0343792020-11-18 10:42:21 -06001354 :term:`COPYLEFT_PN_INCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001355 A list of recipes to include in the source archived by the
1356 :ref:`archiver <ref-classes-archiver>` class. The
1357 ``COPYLEFT_PN_INCLUDE`` variable overrides the license inclusion and
1358 exclusion caused through the
1359 :term:`COPYLEFT_LICENSE_INCLUDE` and
1360 :term:`COPYLEFT_LICENSE_EXCLUDE`
1361 variables, respectively.
1362
1363 The default value, which is "" indicating to not explicitly include
1364 any recipes by name, for ``COPYLEFT_PN_INCLUDE`` is set by the
1365 :ref:`copyleft_filter <ref-classes-copyleft_filter>` class, which
1366 is inherited by the ``archiver`` class.
1367
Andrew Geisslerf0343792020-11-18 10:42:21 -06001368 :term:`COPYLEFT_RECIPE_TYPES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001369 A space-separated list of recipe types to include in the source
1370 archived by the :ref:`archiver <ref-classes-archiver>` class.
1371 Recipe types are ``target``, ``native``, ``nativesdk``, ``cross``,
1372 ``crosssdk``, and ``cross-canadian``.
1373
1374 The default value, which is "target*", for ``COPYLEFT_RECIPE_TYPES``
1375 is set by the :ref:`copyleft_filter <ref-classes-copyleft_filter>`
1376 class, which is inherited by the ``archiver`` class.
1377
Andrew Geisslerf0343792020-11-18 10:42:21 -06001378 :term:`COPY_LIC_DIRS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001379 If set to "1" along with the
1380 :term:`COPY_LIC_MANIFEST` variable, the
1381 OpenEmbedded build system copies into the image the license files,
1382 which are located in ``/usr/share/common-licenses``, for each
1383 package. The license files are placed in directories within the image
1384 itself during build time.
1385
1386 .. note::
1387
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001388 The ``COPY_LIC_DIRS`` does not offer a path for adding licenses for
1389 newly installed packages to an image, which might be most suitable for
1390 read-only filesystems that cannot be upgraded. See the
1391 :term:`LICENSE_CREATE_PACKAGE` variable for additional information.
1392 You can also reference the ":ref:`dev-manual/dev-manual-common-tasks:providing license text`"
1393 section in the Yocto Project Development Tasks Manual for
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001394 information on providing license text.
1395
Andrew Geisslerf0343792020-11-18 10:42:21 -06001396 :term:`COPY_LIC_MANIFEST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001397 If set to "1", the OpenEmbedded build system copies the license
1398 manifest for the image to
1399 ``/usr/share/common-licenses/license.manifest`` within the image
1400 itself during build time.
1401
1402 .. note::
1403
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001404 The ``COPY_LIC_MANIFEST`` does not offer a path for adding licenses for
1405 newly installed packages to an image, which might be most suitable for
1406 read-only filesystems that cannot be upgraded. See the
1407 :term:`LICENSE_CREATE_PACKAGE` variable for additional information.
1408 You can also reference the ":ref:`dev-manual/dev-manual-common-tasks:providing license text`"
1409 section in the Yocto Project Development Tasks Manual for
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001410 information on providing license text.
1411
Andrew Geisslerf0343792020-11-18 10:42:21 -06001412 :term:`CORE_IMAGE_EXTRA_INSTALL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001413 Specifies the list of packages to be added to the image. You should
1414 only set this variable in the ``local.conf`` configuration file found
1415 in the :term:`Build Directory`.
1416
1417 This variable replaces ``POKY_EXTRA_INSTALL``, which is no longer
1418 supported.
1419
Andrew Geisslerf0343792020-11-18 10:42:21 -06001420 :term:`COREBASE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001421 Specifies the parent directory of the OpenEmbedded-Core Metadata
1422 layer (i.e. ``meta``).
1423
1424 It is an important distinction that ``COREBASE`` points to the parent
1425 of this layer and not the layer itself. Consider an example where you
1426 have cloned the Poky Git repository and retained the ``poky`` name
1427 for your local copy of the repository. In this case, ``COREBASE``
1428 points to the ``poky`` folder because it is the parent directory of
1429 the ``poky/meta`` layer.
1430
Andrew Geisslerf0343792020-11-18 10:42:21 -06001431 :term:`COREBASE_FILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001432 Lists files from the :term:`COREBASE` directory that
1433 should be copied other than the layers listed in the
1434 ``bblayers.conf`` file. The ``COREBASE_FILES`` variable exists for
1435 the purpose of copying metadata from the OpenEmbedded build system
1436 into the extensible SDK.
1437
1438 Explicitly listing files in ``COREBASE`` is needed because it
1439 typically contains build directories and other files that should not
1440 normally be copied into the extensible SDK. Consequently, the value
1441 of ``COREBASE_FILES`` is used in order to only copy the files that
1442 are actually needed.
1443
Andrew Geisslerf0343792020-11-18 10:42:21 -06001444 :term:`CPP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001445 The minimal command and arguments used to run the C preprocessor.
1446
Andrew Geisslerf0343792020-11-18 10:42:21 -06001447 :term:`CPPFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001448 Specifies the flags to pass to the C pre-processor (i.e. to both the
1449 C and the C++ compilers). This variable is exported to an environment
1450 variable and thus made visible to the software being built during the
1451 compilation step.
1452
1453 Default initialization for ``CPPFLAGS`` varies depending on what is
1454 being built:
1455
1456 - :term:`TARGET_CPPFLAGS` when building for
1457 the target
1458
1459 - :term:`BUILD_CPPFLAGS` when building for the
1460 build host (i.e. ``-native``)
1461
1462 - :term:`BUILDSDK_CPPFLAGS` when building
1463 for an SDK (i.e. ``nativesdk-``)
1464
Andrew Geisslerf0343792020-11-18 10:42:21 -06001465 :term:`CROSS_COMPILE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001466 The toolchain binary prefix for the target tools. The
1467 ``CROSS_COMPILE`` variable is the same as the
1468 :term:`TARGET_PREFIX` variable.
1469
1470 .. note::
1471
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001472 The OpenEmbedded build system sets the ``CROSS_COMPILE``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001473 variable only in certain contexts (e.g. when building for kernel
1474 and kernel module recipes).
1475
Andrew Geisslerf0343792020-11-18 10:42:21 -06001476 :term:`CVSDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001477 The directory in which files checked out under the CVS system are
1478 stored.
1479
Andrew Geisslerf0343792020-11-18 10:42:21 -06001480 :term:`CXX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001481 The minimal command and arguments used to run the C++ compiler.
1482
Andrew Geisslerf0343792020-11-18 10:42:21 -06001483 :term:`CXXFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001484 Specifies the flags to pass to the C++ compiler. This variable is
1485 exported to an environment variable and thus made visible to the
1486 software being built during the compilation step.
1487
1488 Default initialization for ``CXXFLAGS`` varies depending on what is
1489 being built:
1490
1491 - :term:`TARGET_CXXFLAGS` when building for
1492 the target
1493
1494 - :term:`BUILD_CXXFLAGS` when building for the
1495 build host (i.e. ``-native``)
1496
1497 - :term:`BUILDSDK_CXXFLAGS` when building
1498 for an SDK (i.e. ``nativesdk-``)
1499
Andrew Geisslerf0343792020-11-18 10:42:21 -06001500 :term:`D`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001501 The destination directory. The location in the :term:`Build Directory`
1502 where components are installed by the
1503 :ref:`ref-tasks-install` task. This location defaults
1504 to:
1505 ::
1506
1507 ${WORKDIR}/image
1508
1509 .. note::
1510
1511 Tasks that read from or write to this directory should run under
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001512 :ref:`fakeroot <overview-manual/overview-manual-concepts:fakeroot and pseudo>`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001513
Andrew Geisslerf0343792020-11-18 10:42:21 -06001514 :term:`DATE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001515 The date the build was started. Dates appear using the year, month,
1516 and day (YMD) format (e.g. "20150209" for February 9th, 2015).
1517
Andrew Geisslerf0343792020-11-18 10:42:21 -06001518 :term:`DATETIME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001519 The date and time on which the current build started. The format is
1520 suitable for timestamps.
1521
Andrew Geisslerf0343792020-11-18 10:42:21 -06001522 :term:`DEBIAN_NOAUTONAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001523 When the :ref:`debian <ref-classes-debian>` class is inherited,
1524 which is the default behavior, ``DEBIAN_NOAUTONAME`` specifies a
1525 particular package should not be renamed according to Debian library
1526 package naming. You must use the package name as an override when you
1527 set this variable. Here is an example from the ``fontconfig`` recipe:
1528 ::
1529
1530 DEBIAN_NOAUTONAME_fontconfig-utils = "1"
1531
Andrew Geisslerf0343792020-11-18 10:42:21 -06001532 :term:`DEBIANNAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001533 When the :ref:`debian <ref-classes-debian>` class is inherited,
1534 which is the default behavior, ``DEBIANNAME`` allows you to override
1535 the library name for an individual package. Overriding the library
1536 name in these cases is rare. You must use the package name as an
1537 override when you set this variable. Here is an example from the
1538 ``dbus`` recipe:
1539 ::
1540
1541 DEBIANNAME_${PN} = "dbus-1"
1542
Andrew Geisslerf0343792020-11-18 10:42:21 -06001543 :term:`DEBUG_BUILD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001544 Specifies to build packages with debugging information. This
1545 influences the value of the ``SELECTED_OPTIMIZATION`` variable.
1546
Andrew Geisslerf0343792020-11-18 10:42:21 -06001547 :term:`DEBUG_OPTIMIZATION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001548 The options to pass in ``TARGET_CFLAGS`` and ``CFLAGS`` when
1549 compiling a system for debugging. This variable defaults to "-O
1550 -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe".
1551
Andrew Geisslerf0343792020-11-18 10:42:21 -06001552 :term:`DEFAULT_PREFERENCE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001553 Specifies a weak bias for recipe selection priority.
1554
1555 The most common usage of this is variable is to set it to "-1" within
1556 a recipe for a development version of a piece of software. Using the
1557 variable in this way causes the stable version of the recipe to build
1558 by default in the absence of ``PREFERRED_VERSION`` being used to
1559 build the development version.
1560
1561 .. note::
1562
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001563 The bias provided by ``DEFAULT_PREFERENCE`` is weak and is overridden
1564 by :term:`BBFILE_PRIORITY` if that variable is different between two
1565 layers that contain different versions of the same recipe.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001566
Andrew Geisslerf0343792020-11-18 10:42:21 -06001567 :term:`DEFAULTTUNE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001568 The default CPU and Application Binary Interface (ABI) tunings (i.e.
1569 the "tune") used by the OpenEmbedded build system. The
1570 ``DEFAULTTUNE`` helps define
1571 :term:`TUNE_FEATURES`.
1572
1573 The default tune is either implicitly or explicitly set by the
1574 machine (:term:`MACHINE`). However, you can override
1575 the setting using available tunes as defined with
1576 :term:`AVAILTUNES`.
1577
Andrew Geisslerf0343792020-11-18 10:42:21 -06001578 :term:`DEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001579 Lists a recipe's build-time dependencies. These are dependencies on
1580 other recipes whose contents (e.g. headers and shared libraries) are
1581 needed by the recipe at build time.
1582
1583 As an example, consider a recipe ``foo`` that contains the following
1584 assignment:
1585 ::
1586
1587 DEPENDS = "bar"
1588
1589 The practical effect of the previous
1590 assignment is that all files installed by bar will be available in
1591 the appropriate staging sysroot, given by the
1592 :term:`STAGING_DIR* <STAGING_DIR>` variables, by the time the
1593 :ref:`ref-tasks-configure` task for ``foo`` runs.
1594 This mechanism is implemented by having ``do_configure`` depend on
1595 the :ref:`ref-tasks-populate_sysroot` task of
1596 each recipe listed in ``DEPENDS``, through a
1597 ``[``\ :ref:`deptask <bitbake:bitbake-user-manual/bitbake-user-manual-metadata:variable flags>`\ ``]``
1598 declaration in the :ref:`base <ref-classes-base>` class.
1599
1600 .. note::
1601
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001602 It seldom is necessary to reference, for example, ``STAGING_DIR_HOST``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001603 explicitly. The standard classes and build-related variables are
1604 configured to automatically use the appropriate staging sysroots.
1605
1606 As another example, ``DEPENDS`` can also be used to add utilities
1607 that run on the build machine during the build. For example, a recipe
1608 that makes use of a code generator built by the recipe ``codegen``
1609 might have the following:
1610 ::
1611
1612 DEPENDS = "codegen-native"
1613
1614 For more
1615 information, see the :ref:`native <ref-classes-native>` class and
1616 the :term:`EXTRANATIVEPATH` variable.
1617
1618 .. note::
1619
1620 - ``DEPENDS`` is a list of recipe names. Or, to be more precise,
1621 it is a list of :term:`PROVIDES` names, which
1622 usually match recipe names. Putting a package name such as
1623 "foo-dev" in ``DEPENDS`` does not make sense. Use "foo"
1624 instead, as this will put files from all the packages that make
1625 up ``foo``, which includes those from ``foo-dev``, into the
1626 sysroot.
1627
1628 - One recipe having another recipe in ``DEPENDS`` does not by
1629 itself add any runtime dependencies between the packages
1630 produced by the two recipes. However, as explained in the
1631 ":ref:`overview-manual/overview-manual-concepts:automatically added runtime dependencies`"
1632 section in the Yocto Project Overview and Concepts Manual,
1633 runtime dependencies will often be added automatically, meaning
1634 ``DEPENDS`` alone is sufficient for most recipes.
1635
1636 - Counterintuitively, ``DEPENDS`` is often necessary even for
1637 recipes that install precompiled components. For example, if
1638 ``libfoo`` is a precompiled library that links against
1639 ``libbar``, then linking against ``libfoo`` requires both
1640 ``libfoo`` and ``libbar`` to be available in the sysroot.
1641 Without a ``DEPENDS`` from the recipe that installs ``libfoo``
1642 to the recipe that installs ``libbar``, other recipes might
1643 fail to link against ``libfoo``.
1644
1645 For information on runtime dependencies, see the
1646 :term:`RDEPENDS` variable. You can also see the
1647 ":ref:`Tasks <bitbake:bitbake-user-manual/bitbake-user-manual-metadata:tasks>`" and
1648 ":ref:`Dependencies <bitbake:bitbake-user-manual/bitbake-user-manual-execution:dependencies>`" sections in the
1649 BitBake User Manual for additional information on tasks and
1650 dependencies.
1651
Andrew Geisslerf0343792020-11-18 10:42:21 -06001652 :term:`DEPLOY_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001653 Points to the general area that the OpenEmbedded build system uses to
1654 place images, packages, SDKs, and other output files that are ready
1655 to be used outside of the build system. By default, this directory
1656 resides within the :term:`Build Directory` as
1657 ``${TMPDIR}/deploy``.
1658
1659 For more information on the structure of the Build Directory, see
1660 ":ref:`ref-manual/ref-structure:the build directory - \`\`build/\`\``" section.
1661 For more detail on the contents of the ``deploy`` directory, see the
1662 ":ref:`Images <images-dev-environment>`", ":ref:`Package
1663 Feeds <package-feeds-dev-environment>`", and
1664 ":ref:`sdk-dev-environment`" sections all in the
1665 Yocto Project Overview and Concepts Manual.
1666
Andrew Geisslerf0343792020-11-18 10:42:21 -06001667 :term:`DEPLOY_DIR_DEB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001668 Points to the area that the OpenEmbedded build system uses to place
1669 Debian packages that are ready to be used outside of the build
1670 system. This variable applies only when
1671 :term:`PACKAGE_CLASSES` contains
1672 "package_deb".
1673
1674 The BitBake configuration file initially defines the
1675 ``DEPLOY_DIR_DEB`` variable as a sub-folder of
1676 :term:`DEPLOY_DIR`:
1677 ::
1678
1679 DEPLOY_DIR_DEB = "${DEPLOY_DIR}/deb"
1680
1681 The :ref:`package_deb <ref-classes-package_deb>` class uses the
1682 ``DEPLOY_DIR_DEB`` variable to make sure the
1683 :ref:`ref-tasks-package_write_deb` task
1684 writes Debian packages into the appropriate folder. For more
1685 information on how packaging works, see the ":ref:`Package
1686 Feeds <package-feeds-dev-environment>`" section
1687 in the Yocto Project Overview and Concepts Manual.
1688
Andrew Geisslerf0343792020-11-18 10:42:21 -06001689 :term:`DEPLOY_DIR_IMAGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001690 Points to the area that the OpenEmbedded build system uses to place
1691 images and other associated output files that are ready to be
1692 deployed onto the target machine. The directory is machine-specific
1693 as it contains the ``${MACHINE}`` name. By default, this directory
1694 resides within the :term:`Build Directory` as
1695 ``${DEPLOY_DIR}/images/${MACHINE}/``.
1696
1697 For more information on the structure of the Build Directory, see
1698 ":ref:`ref-manual/ref-structure:the build directory - \`\`build/\`\``" section.
1699 For more detail on the contents of the ``deploy`` directory, see the
1700 ":ref:`Images <images-dev-environment>`" and
1701 ":ref:`sdk-dev-environment`" sections both in
1702 the Yocto Project Overview and Concepts Manual.
1703
Andrew Geisslerf0343792020-11-18 10:42:21 -06001704 :term:`DEPLOY_DIR_IPK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001705 Points to the area that the OpenEmbedded build system uses to place
1706 IPK packages that are ready to be used outside of the build system.
1707 This variable applies only when
1708 :term:`PACKAGE_CLASSES` contains
1709 "package_ipk".
1710
1711 The BitBake configuration file initially defines this variable as a
1712 sub-folder of :term:`DEPLOY_DIR`:
1713 ::
1714
1715 DEPLOY_DIR_IPK = "${DEPLOY_DIR}/ipk"
1716
1717 The :ref:`package_ipk <ref-classes-package_ipk>` class uses the
1718 ``DEPLOY_DIR_IPK`` variable to make sure the
1719 :ref:`ref-tasks-package_write_ipk` task
1720 writes IPK packages into the appropriate folder. For more information
1721 on how packaging works, see the ":ref:`Package
1722 Feeds <package-feeds-dev-environment>`" section
1723 in the Yocto Project Overview and Concepts Manual.
1724
Andrew Geisslerf0343792020-11-18 10:42:21 -06001725 :term:`DEPLOY_DIR_RPM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001726 Points to the area that the OpenEmbedded build system uses to place
1727 RPM packages that are ready to be used outside of the build system.
1728 This variable applies only when
1729 :term:`PACKAGE_CLASSES` contains
1730 "package_rpm".
1731
1732 The BitBake configuration file initially defines this variable as a
1733 sub-folder of :term:`DEPLOY_DIR`:
1734 ::
1735
1736 DEPLOY_DIR_RPM = "${DEPLOY_DIR}/rpm"
1737
1738 The :ref:`package_rpm <ref-classes-package_rpm>` class uses the
1739 ``DEPLOY_DIR_RPM`` variable to make sure the
1740 :ref:`ref-tasks-package_write_rpm` task
1741 writes RPM packages into the appropriate folder. For more information
1742 on how packaging works, see the ":ref:`Package
1743 Feeds <package-feeds-dev-environment>`" section
1744 in the Yocto Project Overview and Concepts Manual.
1745
Andrew Geisslerf0343792020-11-18 10:42:21 -06001746 :term:`DEPLOY_DIR_TAR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001747 Points to the area that the OpenEmbedded build system uses to place
1748 tarballs that are ready to be used outside of the build system. This
1749 variable applies only when
1750 :term:`PACKAGE_CLASSES` contains
1751 "package_tar".
1752
1753 The BitBake configuration file initially defines this variable as a
1754 sub-folder of :term:`DEPLOY_DIR`:
1755 ::
1756
1757 DEPLOY_DIR_TAR = "${DEPLOY_DIR}/tar"
1758
1759 The :ref:`package_tar <ref-classes-package_tar>` class uses the
1760 ``DEPLOY_DIR_TAR`` variable to make sure the
1761 :ref:`ref-tasks-package_write_tar` task
1762 writes TAR packages into the appropriate folder. For more information
1763 on how packaging works, see the ":ref:`Package
1764 Feeds <package-feeds-dev-environment>`" section
1765 in the Yocto Project Overview and Concepts Manual.
1766
Andrew Geisslerf0343792020-11-18 10:42:21 -06001767 :term:`DEPLOYDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001768 When inheriting the :ref:`deploy <ref-classes-deploy>` class, the
1769 ``DEPLOYDIR`` points to a temporary work area for deployed files that
1770 is set in the ``deploy`` class as follows:
1771 ::
1772
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001773 DEPLOYDIR = "${WORKDIR}/deploy-${PN}"
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001774
1775 Recipes inheriting the ``deploy`` class should copy files to be
1776 deployed into ``DEPLOYDIR``, and the class will take care of copying
1777 them into :term:`DEPLOY_DIR_IMAGE`
1778 afterwards.
1779
Andrew Geisslerf0343792020-11-18 10:42:21 -06001780 :term:`DESCRIPTION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001781 The package description used by package managers. If not set,
1782 ``DESCRIPTION`` takes the value of the :term:`SUMMARY`
1783 variable.
1784
Andrew Geisslerf0343792020-11-18 10:42:21 -06001785 :term:`DISTRO`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001786 The short name of the distribution. For information on the long name
1787 of the distribution, see the :term:`DISTRO_NAME`
1788 variable.
1789
1790 The ``DISTRO`` variable corresponds to a distribution configuration
1791 file whose root name is the same as the variable's argument and whose
1792 filename extension is ``.conf``. For example, the distribution
1793 configuration file for the Poky distribution is named ``poky.conf``
1794 and resides in the ``meta-poky/conf/distro`` directory of the
1795 :term:`Source Directory`.
1796
1797 Within that ``poky.conf`` file, the ``DISTRO`` variable is set as
1798 follows:
1799 ::
1800
1801 DISTRO = "poky"
1802
1803 Distribution configuration files are located in a ``conf/distro``
1804 directory within the :term:`Metadata` that contains the
1805 distribution configuration. The value for ``DISTRO`` must not contain
1806 spaces, and is typically all lower-case.
1807
1808 .. note::
1809
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001810 If the ``DISTRO`` variable is blank, a set of default configurations
1811 are used, which are specified within
1812 ``meta/conf/distro/defaultsetup.conf`` also in the Source Directory.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001813
Andrew Geisslerf0343792020-11-18 10:42:21 -06001814 :term:`DISTRO_CODENAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001815 Specifies a codename for the distribution being built.
1816
Andrew Geisslerf0343792020-11-18 10:42:21 -06001817 :term:`DISTRO_EXTRA_RDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001818 Specifies a list of distro-specific packages to add to all images.
1819 This variable takes affect through ``packagegroup-base`` so the
1820 variable only really applies to the more full-featured images that
1821 include ``packagegroup-base``. You can use this variable to keep
1822 distro policy out of generic images. As with all other distro
1823 variables, you set this variable in the distro ``.conf`` file.
1824
Andrew Geisslerf0343792020-11-18 10:42:21 -06001825 :term:`DISTRO_EXTRA_RRECOMMENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001826 Specifies a list of distro-specific packages to add to all images if
1827 the packages exist. The packages might not exist or be empty (e.g.
1828 kernel modules). The list of packages are automatically installed but
1829 you can remove them.
1830
Andrew Geisslerf0343792020-11-18 10:42:21 -06001831 :term:`DISTRO_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001832 The software support you want in your distribution for various
1833 features. You define your distribution features in the distribution
1834 configuration file.
1835
1836 In most cases, the presence or absence of a feature in
1837 ``DISTRO_FEATURES`` is translated to the appropriate option supplied
1838 to the configure script during the
1839 :ref:`ref-tasks-configure` task for recipes that
1840 optionally support the feature. For example, specifying "x11" in
1841 ``DISTRO_FEATURES``, causes every piece of software built for the
1842 target that can optionally support X11 to have its X11 support
1843 enabled.
1844
1845 Two more examples are Bluetooth and NFS support. For a more complete
1846 list of features that ships with the Yocto Project and that you can
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001847 provide with this variable, see the ":ref:`ref-features-distro`" section.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001848
Andrew Geisslerf0343792020-11-18 10:42:21 -06001849 :term:`DISTRO_FEATURES_BACKFILL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001850 Features to be added to ``DISTRO_FEATURES`` if not also present in
1851 ``DISTRO_FEATURES_BACKFILL_CONSIDERED``.
1852
1853 This variable is set in the ``meta/conf/bitbake.conf`` file. It is
1854 not intended to be user-configurable. It is best to just reference
1855 the variable to see which distro features are being backfilled for
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001856 all distro configurations. See the ":ref:`ref-features-backfill`" section
1857 for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001858
Andrew Geisslerf0343792020-11-18 10:42:21 -06001859 :term:`DISTRO_FEATURES_BACKFILL_CONSIDERED`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001860 Features from ``DISTRO_FEATURES_BACKFILL`` that should not be
1861 backfilled (i.e. added to ``DISTRO_FEATURES``) during the build. See
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001862 the ":ref:`ref-features-backfill`" section for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001863
Andrew Geisslerf0343792020-11-18 10:42:21 -06001864 :term:`DISTRO_FEATURES_DEFAULT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001865 A convenience variable that gives you the default list of distro
1866 features with the exception of any features specific to the C library
1867 (``libc``).
1868
1869 When creating a custom distribution, you might find it useful to be
1870 able to reuse the default
1871 :term:`DISTRO_FEATURES` options without the
1872 need to write out the full set. Here is an example that uses
1873 ``DISTRO_FEATURES_DEFAULT`` from a custom distro configuration file:
1874 ::
1875
1876 DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULT} myfeature"
1877
Andrew Geisslerf0343792020-11-18 10:42:21 -06001878 :term:`DISTRO_FEATURES_FILTER_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001879 Specifies a list of features that if present in the target
1880 :term:`DISTRO_FEATURES` value should be
1881 included in ``DISTRO_FEATURES`` when building native recipes. This
1882 variable is used in addition to the features filtered using the
1883 :term:`DISTRO_FEATURES_NATIVE`
1884 variable.
1885
Andrew Geisslerf0343792020-11-18 10:42:21 -06001886 :term:`DISTRO_FEATURES_FILTER_NATIVESDK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001887 Specifies a list of features that if present in the target
1888 :term:`DISTRO_FEATURES` value should be
1889 included in ``DISTRO_FEATURES`` when building nativesdk recipes. This
1890 variable is used in addition to the features filtered using the
1891 :term:`DISTRO_FEATURES_NATIVESDK`
1892 variable.
1893
Andrew Geisslerf0343792020-11-18 10:42:21 -06001894 :term:`DISTRO_FEATURES_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001895 Specifies a list of features that should be included in
1896 :term:`DISTRO_FEATURES` when building native
1897 recipes. This variable is used in addition to the features filtered
1898 using the
1899 :term:`DISTRO_FEATURES_FILTER_NATIVE`
1900 variable.
1901
Andrew Geisslerf0343792020-11-18 10:42:21 -06001902 :term:`DISTRO_FEATURES_NATIVESDK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001903 Specifies a list of features that should be included in
1904 :term:`DISTRO_FEATURES` when building
1905 nativesdk recipes. This variable is used in addition to the features
1906 filtered using the
1907 :term:`DISTRO_FEATURES_FILTER_NATIVESDK`
1908 variable.
1909
Andrew Geisslerf0343792020-11-18 10:42:21 -06001910 :term:`DISTRO_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001911 The long name of the distribution. For information on the short name
1912 of the distribution, see the :term:`DISTRO` variable.
1913
1914 The ``DISTRO_NAME`` variable corresponds to a distribution
1915 configuration file whose root name is the same as the variable's
1916 argument and whose filename extension is ``.conf``. For example, the
1917 distribution configuration file for the Poky distribution is named
1918 ``poky.conf`` and resides in the ``meta-poky/conf/distro`` directory
1919 of the :term:`Source Directory`.
1920
1921 Within that ``poky.conf`` file, the ``DISTRO_NAME`` variable is set
1922 as follows:
1923 ::
1924
1925 DISTRO_NAME = "Poky (Yocto Project Reference Distro)"
1926
1927 Distribution configuration files are located in a ``conf/distro``
1928 directory within the :term:`Metadata` that contains the
1929 distribution configuration.
1930
1931 .. note::
1932
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001933 If the ``DISTRO_NAME`` variable is blank, a set of default
1934 configurations are used, which are specified within
1935 ``meta/conf/distro/defaultsetup.conf`` also in the Source Directory.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001936
Andrew Geisslerf0343792020-11-18 10:42:21 -06001937 :term:`DISTRO_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001938 The version of the distribution.
1939
Andrew Geisslerf0343792020-11-18 10:42:21 -06001940 :term:`DISTROOVERRIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001941 A colon-separated list of overrides specific to the current
1942 distribution. By default, this list includes the value of
1943 :term:`DISTRO`.
1944
1945 You can extend ``DISTROOVERRIDES`` to add extra overrides that should
1946 apply to the distribution.
1947
1948 The underlying mechanism behind ``DISTROOVERRIDES`` is simply that it
1949 is included in the default value of
1950 :term:`OVERRIDES`.
1951
Andrew Geisslerf0343792020-11-18 10:42:21 -06001952 :term:`DL_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001953 The central download directory used by the build process to store
1954 downloads. By default, ``DL_DIR`` gets files suitable for mirroring
1955 for everything except Git repositories. If you want tarballs of Git
1956 repositories, use the
1957 :term:`BB_GENERATE_MIRROR_TARBALLS`
1958 variable.
1959
1960 You can set this directory by defining the ``DL_DIR`` variable in the
1961 ``conf/local.conf`` file. This directory is self-maintaining and you
1962 should not have to touch it. By default, the directory is
1963 ``downloads`` in the :term:`Build Directory`.
1964 ::
1965
1966 #DL_DIR ?= "${TOPDIR}/downloads"
1967
1968 To specify a different download directory,
1969 simply remove the comment from the line and provide your directory.
1970
1971 During a first build, the system downloads many different source code
1972 tarballs from various upstream projects. Downloading can take a
1973 while, particularly if your network connection is slow. Tarballs are
1974 all stored in the directory defined by ``DL_DIR`` and the build
1975 system looks there first to find source tarballs.
1976
1977 .. note::
1978
1979 When wiping and rebuilding, you can preserve this directory to
1980 speed up this part of subsequent builds.
1981
1982 You can safely share this directory between multiple builds on the
1983 same development machine. For additional information on how the build
1984 process gets source files when working behind a firewall or proxy
Andrew Geissler4c19ea12020-10-27 13:52:24 -05001985 server, see this specific question in the ":doc:`faq`"
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001986 chapter. You can also refer to the
1987 ":yocto_wiki:`Working Behind a Network Proxy </wiki/Working_Behind_a_Network_Proxy>`"
1988 Wiki page.
1989
Andrew Geisslerf0343792020-11-18 10:42:21 -06001990 :term:`DOC_COMPRESS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05001991 When inheriting the :ref:`compress_doc <ref-classes-compress_doc>`
1992 class, this variable sets the compression policy used when the
1993 OpenEmbedded build system compresses man pages and info pages. By
1994 default, the compression method used is gz (gzip). Other policies
1995 available are xz and bz2.
1996
1997 For information on policies and on how to use this variable, see the
1998 comments in the ``meta/classes/compress_doc.bbclass`` file.
1999
Andrew Geisslerf0343792020-11-18 10:42:21 -06002000 :term:`EFI_PROVIDER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002001 When building bootable images (i.e. where ``hddimg``, ``iso``, or
2002 ``wic.vmdk`` is in :term:`IMAGE_FSTYPES`), the
2003 ``EFI_PROVIDER`` variable specifies the EFI bootloader to use. The
2004 default is "grub-efi", but "systemd-boot" can be used instead.
2005
2006 See the :ref:`systemd-boot <ref-classes-systemd-boot>` and
2007 :ref:`image-live <ref-classes-image-live>` classes for more
2008 information.
2009
Andrew Geisslerf0343792020-11-18 10:42:21 -06002010 :term:`ENABLE_BINARY_LOCALE_GENERATION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002011 Variable that controls which locales for ``glibc`` are generated
2012 during the build (useful if the target device has 64Mbytes of RAM or
2013 less).
2014
Andrew Geisslerf0343792020-11-18 10:42:21 -06002015 :term:`ERR_REPORT_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002016 When used with the :ref:`report-error <ref-classes-report-error>`
2017 class, specifies the path used for storing the debug files created by
2018 the :ref:`error reporting
2019 tool <dev-manual/dev-manual-common-tasks:using the error reporting tool>`, which
2020 allows you to submit build errors you encounter to a central
2021 database. By default, the value of this variable is
2022 ``${``\ :term:`LOG_DIR`\ ``}/error-report``.
2023
2024 You can set ``ERR_REPORT_DIR`` to the path you want the error
2025 reporting tool to store the debug files as follows in your
2026 ``local.conf`` file:
2027 ::
2028
2029 ERR_REPORT_DIR = "path"
2030
Andrew Geisslerf0343792020-11-18 10:42:21 -06002031 :term:`ERROR_QA`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002032 Specifies the quality assurance checks whose failures are reported as
2033 errors by the OpenEmbedded build system. You set this variable in
2034 your distribution configuration file. For a list of the checks you
2035 can control with this variable, see the
2036 ":ref:`insane.bbclass <ref-classes-insane>`" section.
2037
Andrew Geisslerf0343792020-11-18 10:42:21 -06002038 :term:`EXCLUDE_FROM_SHLIBS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002039 Triggers the OpenEmbedded build system's shared libraries resolver to
2040 exclude an entire package when scanning for shared libraries.
2041
2042 .. note::
2043
2044 The shared libraries resolver's functionality results in part from
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002045 the internal function ``package_do_shlibs``, which is part of the
2046 :ref:`ref-tasks-package` task. You should be aware that the shared
2047 libraries resolver might implicitly define some dependencies between
2048 packages.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002049
2050 The ``EXCLUDE_FROM_SHLIBS`` variable is similar to the
2051 :term:`PRIVATE_LIBS` variable, which excludes a
2052 package's particular libraries only and not the whole package.
2053
2054 Use the ``EXCLUDE_FROM_SHLIBS`` variable by setting it to "1" for a
2055 particular package:
2056 ::
2057
2058 EXCLUDE_FROM_SHLIBS = "1"
2059
Andrew Geisslerf0343792020-11-18 10:42:21 -06002060 :term:`EXCLUDE_FROM_WORLD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002061 Directs BitBake to exclude a recipe from world builds (i.e.
2062 ``bitbake world``). During world builds, BitBake locates, parses and
2063 builds all recipes found in every layer exposed in the
2064 ``bblayers.conf`` configuration file.
2065
2066 To exclude a recipe from a world build using this variable, set the
2067 variable to "1" in the recipe.
2068
2069 .. note::
2070
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002071 Recipes added to ``EXCLUDE_FROM_WORLD`` may still be built during a
2072 world build in order to satisfy dependencies of other recipes. Adding
2073 a recipe to ``EXCLUDE_FROM_WORLD`` only ensures that the recipe is not
2074 explicitly added to the list of build targets in a world build.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002075
Andrew Geisslerf0343792020-11-18 10:42:21 -06002076 :term:`EXTENDPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002077 Used with file and pathnames to create a prefix for a recipe's
2078 version based on the recipe's :term:`PE` value. If ``PE``
2079 is set and greater than zero for a recipe, ``EXTENDPE`` becomes that
2080 value (e.g if ``PE`` is equal to "1" then ``EXTENDPE`` becomes "1").
2081 If a recipe's ``PE`` is not set (the default) or is equal to zero,
2082 ``EXTENDPE`` becomes "".
2083
2084 See the :term:`STAMP` variable for an example.
2085
Andrew Geisslerf0343792020-11-18 10:42:21 -06002086 :term:`EXTENDPKGV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002087 The full package version specification as it appears on the final
2088 packages produced by a recipe. The variable's value is normally used
2089 to fix a runtime dependency to the exact same version of another
2090 package in the same recipe:
2091 ::
2092
2093 RDEPENDS_${PN}-additional-module = "${PN} (= ${EXTENDPKGV})"
2094
2095 The dependency relationships are intended to force the package
2096 manager to upgrade these types of packages in lock-step.
2097
Andrew Geisslerf0343792020-11-18 10:42:21 -06002098 :term:`EXTERNAL_KERNEL_TOOLS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002099 When set, the ``EXTERNAL_KERNEL_TOOLS`` variable indicates that these
2100 tools are not in the source tree.
2101
2102 When kernel tools are available in the tree, they are preferred over
2103 any externally installed tools. Setting the ``EXTERNAL_KERNEL_TOOLS``
2104 variable tells the OpenEmbedded build system to prefer the installed
2105 external tools. See the
2106 :ref:`kernel-yocto <ref-classes-kernel-yocto>` class in
2107 ``meta/classes`` to see how the variable is used.
2108
Andrew Geisslerf0343792020-11-18 10:42:21 -06002109 :term:`EXTERNALSRC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002110 When inheriting the :ref:`externalsrc <ref-classes-externalsrc>`
2111 class, this variable points to the source tree, which is outside of
2112 the OpenEmbedded build system. When set, this variable sets the
2113 :term:`S` variable, which is what the OpenEmbedded build
2114 system uses to locate unpacked recipe source code.
2115
2116 For more information on ``externalsrc.bbclass``, see the
2117 ":ref:`externalsrc.bbclass <ref-classes-externalsrc>`" section. You
2118 can also find information on how to use this variable in the
2119 ":ref:`dev-manual/dev-manual-common-tasks:building software from an external source`"
2120 section in the Yocto Project Development Tasks Manual.
2121
Andrew Geisslerf0343792020-11-18 10:42:21 -06002122 :term:`EXTERNALSRC_BUILD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002123 When inheriting the :ref:`externalsrc <ref-classes-externalsrc>`
2124 class, this variable points to the directory in which the recipe's
2125 source code is built, which is outside of the OpenEmbedded build
2126 system. When set, this variable sets the :term:`B` variable,
2127 which is what the OpenEmbedded build system uses to locate the Build
2128 Directory.
2129
2130 For more information on ``externalsrc.bbclass``, see the
2131 ":ref:`externalsrc.bbclass <ref-classes-externalsrc>`" section. You
2132 can also find information on how to use this variable in the
2133 ":ref:`dev-manual/dev-manual-common-tasks:building software from an external source`"
2134 section in the Yocto Project Development Tasks Manual.
2135
Andrew Geisslerf0343792020-11-18 10:42:21 -06002136 :term:`EXTRA_AUTORECONF`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002137 For recipes inheriting the :ref:`autotools <ref-classes-autotools>`
2138 class, you can use ``EXTRA_AUTORECONF`` to specify extra options to
2139 pass to the ``autoreconf`` command that is executed during the
2140 :ref:`ref-tasks-configure` task.
2141
2142 The default value is "--exclude=autopoint".
2143
Andrew Geisslerf0343792020-11-18 10:42:21 -06002144 :term:`EXTRA_IMAGE_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002145 A list of additional features to include in an image. When listing
2146 more than one feature, separate them with a space.
2147
2148 Typically, you configure this variable in your ``local.conf`` file,
2149 which is found in the :term:`Build Directory`.
2150 Although you can use this variable from within a recipe, best
2151 practices dictate that you do not.
2152
2153 .. note::
2154
2155 To enable primary features from within the image recipe, use the
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002156 :term:`IMAGE_FEATURES` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002157
2158 Here are some examples of features you can add:
2159
2160 - "dbg-pkgs" - Adds -dbg packages for all installed packages including
2161 symbol information for debugging and profiling.
2162
2163 - "debug-tweaks" - Makes an image suitable for debugging. For example, allows root logins without passwords and
2164 enables post-installation logging. See the 'allow-empty-password' and
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002165 'post-install-logging' features in the ":ref:`ref-features-image`"
2166 section for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002167 - "dev-pkgs" - Adds -dev packages for all installed packages. This is
2168 useful if you want to develop against the libraries in the image.
2169 - "read-only-rootfs" - Creates an image whose root filesystem is
2170 read-only. See the
2171 ":ref:`dev-manual/dev-manual-common-tasks:creating a read-only root filesystem`"
2172 section in the Yocto Project Development Tasks Manual for more
2173 information
2174 - "tools-debug" - Adds debugging tools such as gdb and strace.
2175 - "tools-sdk" - Adds development tools such as gcc, make,
2176 pkgconfig and so forth.
2177 - "tools-testapps" - Adds useful testing tools
2178 such as ts_print, aplay, arecord and so forth.
2179
2180 For a complete list of image features that ships with the Yocto
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002181 Project, see the ":ref:`ref-features-image`" section.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002182
2183 For an example that shows how to customize your image by using this
2184 variable, see the ":ref:`usingpoky-extend-customimage-imagefeatures`"
2185 section in the Yocto Project Development Tasks Manual.
2186
Andrew Geisslerf0343792020-11-18 10:42:21 -06002187 :term:`EXTRA_IMAGECMD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002188 Specifies additional options for the image creation command that has
2189 been specified in :term:`IMAGE_CMD`. When setting
2190 this variable, use an override for the associated image type. Here is
2191 an example:
2192 ::
2193
2194 EXTRA_IMAGECMD_ext3 ?= "-i 4096"
2195
Andrew Geisslerf0343792020-11-18 10:42:21 -06002196 :term:`EXTRA_IMAGEDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002197 A list of recipes to build that do not provide packages for
2198 installing into the root filesystem.
2199
2200 Sometimes a recipe is required to build the final image but is not
2201 needed in the root filesystem. You can use the ``EXTRA_IMAGEDEPENDS``
2202 variable to list these recipes and thus specify the dependencies. A
2203 typical example is a required bootloader in a machine configuration.
2204
2205 .. note::
2206
2207 To add packages to the root filesystem, see the various
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002208 \*:term:`RDEPENDS` and \*:term:`RRECOMMENDS` variables.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002209
Andrew Geisslerf0343792020-11-18 10:42:21 -06002210 :term:`EXTRANATIVEPATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002211 A list of subdirectories of
2212 ``${``\ :term:`STAGING_BINDIR_NATIVE`\ ``}``
2213 added to the beginning of the environment variable ``PATH``. As an
2214 example, the following prepends
2215 "${STAGING_BINDIR_NATIVE}/foo:${STAGING_BINDIR_NATIVE}/bar:" to
2216 ``PATH``:
2217 ::
2218
2219 EXTRANATIVEPATH = "foo bar"
2220
Andrew Geisslerf0343792020-11-18 10:42:21 -06002221 :term:`EXTRA_OECMAKE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002222 Additional `CMake <https://cmake.org/overview/>`__ options. See the
2223 :ref:`cmake <ref-classes-cmake>` class for additional information.
2224
Andrew Geisslerf0343792020-11-18 10:42:21 -06002225 :term:`EXTRA_OECONF`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002226 Additional ``configure`` script options. See
2227 :term:`PACKAGECONFIG_CONFARGS` for
2228 additional information on passing configure script options.
2229
Andrew Geisslerf0343792020-11-18 10:42:21 -06002230 :term:`EXTRA_OEMAKE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002231 Additional GNU ``make`` options.
2232
2233 Because the ``EXTRA_OEMAKE`` defaults to "", you need to set the
2234 variable to specify any required GNU options.
2235
2236 :term:`PARALLEL_MAKE` and
2237 :term:`PARALLEL_MAKEINST` also make use of
2238 ``EXTRA_OEMAKE`` to pass the required flags.
2239
Andrew Geisslerf0343792020-11-18 10:42:21 -06002240 :term:`EXTRA_OESCONS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002241 When inheriting the :ref:`scons <ref-classes-scons>` class, this
2242 variable specifies additional configuration options you want to pass
2243 to the ``scons`` command line.
2244
Andrew Geisslerf0343792020-11-18 10:42:21 -06002245 :term:`EXTRA_USERS_PARAMS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002246 When inheriting the :ref:`extrausers <ref-classes-extrausers>`
2247 class, this variable provides image level user and group operations.
2248 This is a more global method of providing user and group
2249 configuration as compared to using the
2250 :ref:`useradd <ref-classes-useradd>` class, which ties user and
2251 group configurations to a specific recipe.
2252
2253 The set list of commands you can configure using the
2254 ``EXTRA_USERS_PARAMS`` is shown in the ``extrausers`` class. These
2255 commands map to the normal Unix commands of the same names:
2256 ::
2257
2258 # EXTRA_USERS_PARAMS = "\
2259 # useradd -p '' tester; \
2260 # groupadd developers; \
2261 # userdel nobody; \
2262 # groupdel -g video; \
2263 # groupmod -g 1020 developers; \
2264 # usermod -s /bin/sh tester; \
2265 # "
2266
Andrew Geisslerf0343792020-11-18 10:42:21 -06002267 :term:`FEATURE_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002268 Defines one or more packages to include in an image when a specific
2269 item is included in :term:`IMAGE_FEATURES`.
2270 When setting the value, ``FEATURE_PACKAGES`` should have the name of
2271 the feature item as an override. Here is an example:
2272 ::
2273
2274 FEATURE_PACKAGES_widget = "package1 package2"
2275
2276 In this example, if "widget" were added to ``IMAGE_FEATURES``,
2277 package1 and package2 would be included in the image.
2278
2279 .. note::
2280
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002281 Packages installed by features defined through ``FEATURE_PACKAGES``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002282 are often package groups. While similarly named, you should not
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002283 confuse the ``FEATURE_PACKAGES`` variable with package groups, which
2284 are discussed elsewhere in the documentation.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002285
Andrew Geisslerf0343792020-11-18 10:42:21 -06002286 :term:`FEED_DEPLOYDIR_BASE_URI`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002287 Points to the base URL of the server and location within the
2288 document-root that provides the metadata and packages required by
2289 OPKG to support runtime package management of IPK packages. You set
2290 this variable in your ``local.conf`` file.
2291
2292 Consider the following example:
2293 ::
2294
2295 FEED_DEPLOYDIR_BASE_URI = "http://192.168.7.1/BOARD-dir"
2296
2297 This example assumes you are serving
2298 your packages over HTTP and your databases are located in a directory
2299 named ``BOARD-dir``, which is underneath your HTTP server's
2300 document-root. In this case, the OpenEmbedded build system generates
2301 a set of configuration files for you in your target that work with
2302 the feed.
2303
Andrew Geisslerf0343792020-11-18 10:42:21 -06002304 :term:`FILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002305 The list of files and directories that are placed in a package. The
2306 :term:`PACKAGES` variable lists the packages
2307 generated by a recipe.
2308
2309 To use the ``FILES`` variable, provide a package name override that
2310 identifies the resulting package. Then, provide a space-separated
2311 list of files or paths that identify the files you want included as
2312 part of the resulting package. Here is an example:
2313 ::
2314
2315 FILES_${PN} += "${bindir}/mydir1 ${bindir}/mydir2/myfile"
2316
2317 .. note::
2318
2319 - When specifying files or paths, you can pattern match using
2320 Python's
2321 `glob <https://docs.python.org/3/library/glob.html>`_
2322 syntax. For details on the syntax, see the documentation by
2323 following the previous link.
2324
2325 - When specifying paths as part of the ``FILES`` variable, it is
2326 good practice to use appropriate path variables. For example,
2327 use ``${sysconfdir}`` rather than ``/etc``, or ``${bindir}``
2328 rather than ``/usr/bin``. You can find a list of these
2329 variables at the top of the ``meta/conf/bitbake.conf`` file in
2330 the :term:`Source Directory`. You will also
2331 find the default values of the various ``FILES_*`` variables in
2332 this file.
2333
2334 If some of the files you provide with the ``FILES`` variable are
2335 editable and you know they should not be overwritten during the
2336 package update process by the Package Management System (PMS), you
2337 can identify these files so that the PMS will not overwrite them. See
2338 the :term:`CONFFILES` variable for information on
2339 how to identify these files to the PMS.
2340
Andrew Geisslerf0343792020-11-18 10:42:21 -06002341 :term:`FILES_SOLIBSDEV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002342 Defines the file specification to match
2343 :term:`SOLIBSDEV`. In other words,
2344 ``FILES_SOLIBSDEV`` defines the full path name of the development
2345 symbolic link (symlink) for shared libraries on the target platform.
2346
2347 The following statement from the ``bitbake.conf`` shows how it is
2348 set:
2349 ::
2350
2351 FILES_SOLIBSDEV ?= "${base_libdir}/lib*${SOLIBSDEV} ${libdir}/lib*${SOLIBSDEV}"
2352
Andrew Geisslerf0343792020-11-18 10:42:21 -06002353 :term:`FILESEXTRAPATHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002354 Extends the search path the OpenEmbedded build system uses when
2355 looking for files and patches as it processes recipes and append
2356 files. The default directories BitBake uses when it processes recipes
2357 are initially defined by the :term:`FILESPATH`
2358 variable. You can extend ``FILESPATH`` variable by using
2359 ``FILESEXTRAPATHS``.
2360
2361 Best practices dictate that you accomplish this by using
2362 ``FILESEXTRAPATHS`` from within a ``.bbappend`` file and that you
2363 prepend paths as follows:
2364 ::
2365
2366 FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
2367
2368 In the above example, the build system first
2369 looks for files in a directory that has the same name as the
2370 corresponding append file.
2371
2372 .. note::
2373
2374 When extending ``FILESEXTRAPATHS``, be sure to use the immediate
2375 expansion (``:=``) operator. Immediate expansion makes sure that
2376 BitBake evaluates :term:`THISDIR` at the time the
2377 directive is encountered rather than at some later time when
2378 expansion might result in a directory that does not contain the
2379 files you need.
2380
2381 Also, include the trailing separating colon character if you are
2382 prepending. The trailing colon character is necessary because you
2383 are directing BitBake to extend the path by prepending directories
2384 to the search path.
2385
2386 Here is another common use:
2387 ::
2388
2389 FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
2390
2391 In this example, the build system extends the
2392 ``FILESPATH`` variable to include a directory named ``files`` that is
2393 in the same directory as the corresponding append file.
2394
2395 This next example specifically adds three paths:
2396 ::
2397
2398 FILESEXTRAPATHS_prepend := "path_1:path_2:path_3:"
2399
2400 A final example shows how you can extend the search path and include
2401 a :term:`MACHINE`-specific override, which is useful
2402 in a BSP layer:
2403 ::
2404
2405 FILESEXTRAPATHS_prepend_intel-x86-common := "${THISDIR}/${PN}:"
2406
2407 The previous statement appears in the
2408 ``linux-yocto-dev.bbappend`` file, which is found in the
2409 :ref:`overview-manual/overview-manual-development-environment:yocto project source repositories` in
2410 ``meta-intel/common/recipes-kernel/linux``. Here, the machine
2411 override is a special :term:`PACKAGE_ARCH`
2412 definition for multiple ``meta-intel`` machines.
2413
2414 .. note::
2415
2416 For a layer that supports a single BSP, the override could just be
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002417 the value of ``MACHINE``.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002418
2419 By prepending paths in ``.bbappend`` files, you allow multiple append
2420 files that reside in different layers but are used for the same
2421 recipe to correctly extend the path.
2422
Andrew Geisslerf0343792020-11-18 10:42:21 -06002423 :term:`FILESOVERRIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002424 A subset of :term:`OVERRIDES` used by the
2425 OpenEmbedded build system for creating
2426 :term:`FILESPATH`. The ``FILESOVERRIDES`` variable
2427 uses overrides to automatically extend the
2428 :term:`FILESPATH` variable. For an example of how
2429 that works, see the :term:`FILESPATH` variable
2430 description. Additionally, you find more information on how overrides
2431 are handled in the
2432 ":ref:`bitbake:bitbake-user-manual/bitbake-user-manual-metadata:conditional syntax (overrides)`"
2433 section of the BitBake User Manual.
2434
2435 By default, the ``FILESOVERRIDES`` variable is defined as:
2436 ::
2437
2438 FILESOVERRIDES = "${TRANSLATED_TARGET_ARCH}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}"
2439
2440 .. note::
2441
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002442 Do not hand-edit the ``FILESOVERRIDES`` variable. The values match up
2443 with expected overrides and are used in an expected manner by the
2444 build system.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002445
Andrew Geisslerf0343792020-11-18 10:42:21 -06002446 :term:`FILESPATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002447 The default set of directories the OpenEmbedded build system uses
2448 when searching for patches and files.
2449
2450 During the build process, BitBake searches each directory in
2451 ``FILESPATH`` in the specified order when looking for files and
2452 patches specified by each ``file://`` URI in a recipe's
2453 :term:`SRC_URI` statements.
2454
2455 The default value for the ``FILESPATH`` variable is defined in the
2456 ``base.bbclass`` class found in ``meta/classes`` in the
2457 :term:`Source Directory`:
2458 ::
2459
2460 FILESPATH = "${@base_set_filespath(["${FILE_DIRNAME}/${BP}", \
2461 "${FILE_DIRNAME}/${BPN}", "${FILE_DIRNAME}/files"], d)}"
2462
2463 The
2464 ``FILESPATH`` variable is automatically extended using the overrides
2465 from the :term:`FILESOVERRIDES` variable.
2466
2467 .. note::
2468
2469 - Do not hand-edit the ``FILESPATH`` variable. If you want the
2470 build system to look in directories other than the defaults,
2471 extend the ``FILESPATH`` variable by using the
2472 :term:`FILESEXTRAPATHS` variable.
2473
2474 - Be aware that the default ``FILESPATH`` directories do not map
2475 to directories in custom layers where append files
2476 (``.bbappend``) are used. If you want the build system to find
2477 patches or files that reside with your append files, you need
2478 to extend the ``FILESPATH`` variable by using the
2479 ``FILESEXTRAPATHS`` variable.
2480
2481 You can take advantage of this searching behavior in useful ways. For
2482 example, consider a case where the following directory structure
2483 exists for general and machine-specific configurations:
2484 ::
2485
2486 files/defconfig
2487 files/MACHINEA/defconfig
2488 files/MACHINEB/defconfig
2489
2490 Also in the example, the ``SRC_URI`` statement contains
2491 "file://defconfig". Given this scenario, you can set
2492 :term:`MACHINE` to "MACHINEA" and cause the build
2493 system to use files from ``files/MACHINEA``. Set ``MACHINE`` to
2494 "MACHINEB" and the build system uses files from ``files/MACHINEB``.
2495 Finally, for any machine other than "MACHINEA" and "MACHINEB", the
2496 build system uses files from ``files/defconfig``.
2497
2498 You can find out more about the patching process in the
2499 ":ref:`patching-dev-environment`" section
2500 in the Yocto Project Overview and Concepts Manual and the
2501 ":ref:`new-recipe-patching-code`" section in
2502 the Yocto Project Development Tasks Manual. See the
2503 :ref:`ref-tasks-patch` task as well.
2504
Andrew Geisslerf0343792020-11-18 10:42:21 -06002505 :term:`FILESYSTEM_PERMS_TABLES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002506 Allows you to define your own file permissions settings table as part
2507 of your configuration for the packaging process. For example, suppose
2508 you need a consistent set of custom permissions for a set of groups
2509 and users across an entire work project. It is best to do this in the
2510 packages themselves but this is not always possible.
2511
2512 By default, the OpenEmbedded build system uses the ``fs-perms.txt``,
2513 which is located in the ``meta/files`` folder in the :term:`Source Directory`.
2514 If you create your own file
2515 permissions setting table, you should place it in your layer or the
2516 distro's layer.
2517
2518 You define the ``FILESYSTEM_PERMS_TABLES`` variable in the
2519 ``conf/local.conf`` file, which is found in the :term:`Build Directory`,
2520 to point to your custom
2521 ``fs-perms.txt``. You can specify more than a single file permissions
2522 setting table. The paths you specify to these files must be defined
2523 within the :term:`BBPATH` variable.
2524
2525 For guidance on how to create your own file permissions settings
2526 table file, examine the existing ``fs-perms.txt``.
2527
Andrew Geisslerf0343792020-11-18 10:42:21 -06002528 :term:`FIT_GENERATE_KEYS`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002529 Decides whether to generate the keys for signing fitImage if they
2530 don't already exist. The keys are created in ``UBOOT_SIGN_KEYDIR``.
2531 The default value is 0.
2532
Andrew Geisslerf0343792020-11-18 10:42:21 -06002533 :term:`FIT_HASH_ALG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002534 Specifies the hash algorithm used in creating the FIT Image. For e.g. sha256.
2535
Andrew Geisslerf0343792020-11-18 10:42:21 -06002536 :term:`FIT_KEY_GENRSA_ARGS`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002537 Arguments to openssl genrsa for generating RSA private key for signing
2538 fitImage. The default value is "-F4". i.e. the public exponent 65537 to
2539 use.
2540
Andrew Geisslerf0343792020-11-18 10:42:21 -06002541 :term:`FIT_KEY_REQ_ARGS`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002542 Arguments to openssl req for generating certificate for signing fitImage.
2543 The default value is "-batch -new". batch for non interactive mode
2544 and new for generating new keys.
2545
Andrew Geisslerf0343792020-11-18 10:42:21 -06002546 :term:`FIT_KEY_SIGN_PKCS`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002547 Format for public key ceritifcate used in signing fitImage.
2548 The default value is "x509".
2549
Andrew Geisslerf0343792020-11-18 10:42:21 -06002550 :term:`FIT_SIGN_ALG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002551 Specifies the signature algorithm used in creating the FIT Image.
2552 For e.g. rsa2048.
2553
Andrew Geisslerf0343792020-11-18 10:42:21 -06002554 :term:`FIT_SIGN_NUMBITS`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002555 Size of private key in number of bits used in fitImage. The default
2556 value is "2048".
2557
Andrew Geisslerf0343792020-11-18 10:42:21 -06002558 :term:`FONT_EXTRA_RDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002559 When inheriting the :ref:`fontcache <ref-classes-fontcache>` class,
2560 this variable specifies the runtime dependencies for font packages.
2561 By default, the ``FONT_EXTRA_RDEPENDS`` is set to "fontconfig-utils".
2562
Andrew Geisslerf0343792020-11-18 10:42:21 -06002563 :term:`FONT_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002564 When inheriting the :ref:`fontcache <ref-classes-fontcache>` class,
2565 this variable identifies packages containing font files that need to
2566 be cached by Fontconfig. By default, the ``fontcache`` class assumes
2567 that fonts are in the recipe's main package (i.e.
2568 ``${``\ :term:`PN`\ ``}``). Use this variable if fonts you
2569 need are in a package other than that main package.
2570
Andrew Geisslerf0343792020-11-18 10:42:21 -06002571 :term:`FORCE_RO_REMOVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002572 Forces the removal of the packages listed in ``ROOTFS_RO_UNNEEDED``
2573 during the generation of the root filesystem.
2574
2575 Set the variable to "1" to force the removal of these packages.
2576
Andrew Geisslerf0343792020-11-18 10:42:21 -06002577 :term:`FULL_OPTIMIZATION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002578 The options to pass in ``TARGET_CFLAGS`` and ``CFLAGS`` when
2579 compiling an optimized system. This variable defaults to "-O2 -pipe
2580 ${DEBUG_FLAGS}".
2581
Andrew Geisslerf0343792020-11-18 10:42:21 -06002582 :term:`GCCPIE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002583 Enables Position Independent Executables (PIE) within the GNU C
2584 Compiler (GCC). Enabling PIE in the GCC makes Return Oriented
2585 Programming (ROP) attacks much more difficult to execute.
2586
2587 By default the ``security_flags.inc`` file enables PIE by setting the
2588 variable as follows:
2589 ::
2590
2591 GCCPIE ?= "--enable-default-pie"
2592
Andrew Geisslerf0343792020-11-18 10:42:21 -06002593 :term:`GCCVERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002594 Specifies the default version of the GNU C Compiler (GCC) used for
2595 compilation. By default, ``GCCVERSION`` is set to "8.x" in the
2596 ``meta/conf/distro/include/tcmode-default.inc`` include file:
2597 ::
2598
2599 GCCVERSION ?= "8.%"
2600
2601 You can override this value by setting it in a
2602 configuration file such as the ``local.conf``.
2603
Andrew Geisslerf0343792020-11-18 10:42:21 -06002604 :term:`GDB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002605 The minimal command and arguments to run the GNU Debugger.
2606
Andrew Geisslerf0343792020-11-18 10:42:21 -06002607 :term:`GITDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002608 The directory in which a local copy of a Git repository is stored
2609 when it is cloned.
2610
Andrew Geisslerf0343792020-11-18 10:42:21 -06002611 :term:`GLIBC_GENERATE_LOCALES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002612 Specifies the list of GLIBC locales to generate should you not wish
2613 to generate all LIBC locals, which can be time consuming.
2614
2615 .. note::
2616
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002617 If you specifically remove the locale ``en_US.UTF-8``, you must set
2618 :term:`IMAGE_LINGUAS` appropriately.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002619
2620 You can set ``GLIBC_GENERATE_LOCALES`` in your ``local.conf`` file.
2621 By default, all locales are generated.
2622 ::
2623
2624 GLIBC_GENERATE_LOCALES = "en_GB.UTF-8 en_US.UTF-8"
2625
Andrew Geisslerf0343792020-11-18 10:42:21 -06002626 :term:`GROUPADD_PARAM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002627 When inheriting the :ref:`useradd <ref-classes-useradd>` class,
2628 this variable specifies for a package what parameters should be
2629 passed to the ``groupadd`` command if you wish to add a group to the
2630 system when the package is installed.
2631
2632 Here is an example from the ``dbus`` recipe:
2633 ::
2634
2635 GROUPADD_PARAM_${PN} = "-r netdev"
2636
2637 For information on the standard Linux shell command
2638 ``groupadd``, see http://linux.die.net/man/8/groupadd.
2639
Andrew Geisslerf0343792020-11-18 10:42:21 -06002640 :term:`GROUPMEMS_PARAM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002641 When inheriting the :ref:`useradd <ref-classes-useradd>` class,
2642 this variable specifies for a package what parameters should be
2643 passed to the ``groupmems`` command if you wish to modify the members
2644 of a group when the package is installed.
2645
2646 For information on the standard Linux shell command ``groupmems``,
2647 see http://linux.die.net/man/8/groupmems.
2648
Andrew Geisslerf0343792020-11-18 10:42:21 -06002649 :term:`GRUB_GFXSERIAL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002650 Configures the GNU GRand Unified Bootloader (GRUB) to have graphics
2651 and serial in the boot menu. Set this variable to "1" in your
2652 ``local.conf`` or distribution configuration file to enable graphics
2653 and serial in the menu.
2654
2655 See the :ref:`grub-efi <ref-classes-grub-efi>` class for more
2656 information on how this variable is used.
2657
Andrew Geisslerf0343792020-11-18 10:42:21 -06002658 :term:`GRUB_OPTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002659 Additional options to add to the GNU GRand Unified Bootloader (GRUB)
2660 configuration. Use a semi-colon character (``;``) to separate
2661 multiple options.
2662
2663 The ``GRUB_OPTS`` variable is optional. See the
2664 :ref:`grub-efi <ref-classes-grub-efi>` class for more information
2665 on how this variable is used.
2666
Andrew Geisslerf0343792020-11-18 10:42:21 -06002667 :term:`GRUB_TIMEOUT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002668 Specifies the timeout before executing the default ``LABEL`` in the
2669 GNU GRand Unified Bootloader (GRUB).
2670
2671 The ``GRUB_TIMEOUT`` variable is optional. See the
2672 :ref:`grub-efi <ref-classes-grub-efi>` class for more information
2673 on how this variable is used.
2674
Andrew Geisslerf0343792020-11-18 10:42:21 -06002675 :term:`GTKIMMODULES_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002676 When inheriting the
2677 :ref:`gtk-immodules-cache <ref-classes-gtk-immodules-cache>` class,
2678 this variable specifies the packages that contain the GTK+ input
2679 method modules being installed when the modules are in packages other
2680 than the main package.
2681
Andrew Geisslerf0343792020-11-18 10:42:21 -06002682 :term:`HOMEPAGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002683 Website where more information about the software the recipe is
2684 building can be found.
2685
Andrew Geisslerf0343792020-11-18 10:42:21 -06002686 :term:`HOST_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002687 The name of the target architecture, which is normally the same as
2688 :term:`TARGET_ARCH`. The OpenEmbedded build system
2689 supports many architectures. Here is an example list of architectures
2690 supported. This list is by no means complete as the architecture is
2691 configurable:
2692
2693 - arm
2694 - i586
2695 - x86_64
2696 - powerpc
2697 - powerpc64
2698 - mips
2699 - mipsel
2700
Andrew Geisslerf0343792020-11-18 10:42:21 -06002701 :term:`HOST_CC_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002702 Specifies architecture-specific compiler flags that are passed to the
2703 C compiler.
2704
2705 Default initialization for ``HOST_CC_ARCH`` varies depending on what
2706 is being built:
2707
2708 - :term:`TARGET_CC_ARCH` when building for the
2709 target
2710
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002711 - :term:`BUILD_CC_ARCH` when building for the build host (i.e.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002712 ``-native``)
2713
2714 - ``BUILDSDK_CC_ARCH`` when building for an SDK (i.e.
2715 ``nativesdk-``)
2716
Andrew Geisslerf0343792020-11-18 10:42:21 -06002717 :term:`HOST_OS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002718 Specifies the name of the target operating system, which is normally
2719 the same as the :term:`TARGET_OS`. The variable can
2720 be set to "linux" for ``glibc``-based systems and to "linux-musl" for
2721 ``musl``. For ARM/EABI targets, there are also "linux-gnueabi" and
2722 "linux-musleabi" values possible.
2723
Andrew Geisslerf0343792020-11-18 10:42:21 -06002724 :term:`HOST_PREFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002725 Specifies the prefix for the cross-compile toolchain. ``HOST_PREFIX``
2726 is normally the same as :term:`TARGET_PREFIX`.
2727
Andrew Geisslerf0343792020-11-18 10:42:21 -06002728 :term:`HOST_SYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002729 Specifies the system, including the architecture and the operating
2730 system, for which the build is occurring in the context of the
2731 current recipe.
2732
2733 The OpenEmbedded build system automatically sets this variable based
2734 on :term:`HOST_ARCH`,
2735 :term:`HOST_VENDOR`, and
2736 :term:`HOST_OS` variables.
2737
2738 .. note::
2739
2740 You do not need to set the variable yourself.
2741
2742 Consider these two examples:
2743
2744 - Given a native recipe on a 32-bit x86 machine running Linux, the
2745 value is "i686-linux".
2746
2747 - Given a recipe being built for a little-endian MIPS target running
2748 Linux, the value might be "mipsel-linux".
2749
Andrew Geisslerf0343792020-11-18 10:42:21 -06002750 :term:`HOSTTOOLS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002751 A space-separated list (filter) of tools on the build host that
2752 should be allowed to be called from within build tasks. Using this
2753 filter helps reduce the possibility of host contamination. If a tool
2754 specified in the value of ``HOSTTOOLS`` is not found on the build
2755 host, the OpenEmbedded build system produces an error and the build
2756 is not started.
2757
2758 For additional information, see
2759 :term:`HOSTTOOLS_NONFATAL`.
2760
Andrew Geisslerf0343792020-11-18 10:42:21 -06002761 :term:`HOSTTOOLS_NONFATAL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002762 A space-separated list (filter) of tools on the build host that
2763 should be allowed to be called from within build tasks. Using this
2764 filter helps reduce the possibility of host contamination. Unlike
2765 :term:`HOSTTOOLS`, the OpenEmbedded build system
2766 does not produce an error if a tool specified in the value of
2767 ``HOSTTOOLS_NONFATAL`` is not found on the build host. Thus, you can
2768 use ``HOSTTOOLS_NONFATAL`` to filter optional host tools.
2769
Andrew Geisslerf0343792020-11-18 10:42:21 -06002770 :term:`HOST_VENDOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002771 Specifies the name of the vendor. ``HOST_VENDOR`` is normally the
2772 same as :term:`TARGET_VENDOR`.
2773
Andrew Geisslerf0343792020-11-18 10:42:21 -06002774 :term:`ICECC_DISABLED`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002775 Disables or enables the ``icecc`` (Icecream) function. For more
2776 information on this function and best practices for using this
2777 variable, see the ":ref:`icecc.bbclass <ref-classes-icecc>`"
2778 section.
2779
2780 Setting this variable to "1" in your ``local.conf`` disables the
2781 function:
2782 ::
2783
2784 ICECC_DISABLED ??= "1"
2785
2786 To enable the function, set the variable as follows:
2787 ::
2788
2789 ICECC_DISABLED = ""
2790
Andrew Geisslerf0343792020-11-18 10:42:21 -06002791 :term:`ICECC_ENV_EXEC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002792 Points to the ``icecc-create-env`` script that you provide. This
2793 variable is used by the :ref:`icecc <ref-classes-icecc>` class. You
2794 set this variable in your ``local.conf`` file.
2795
2796 If you do not point to a script that you provide, the OpenEmbedded
2797 build system uses the default script provided by the
2798 ``icecc-create-env.bb`` recipe, which is a modified version and not
2799 the one that comes with ``icecc``.
2800
Andrew Geisslerf0343792020-11-18 10:42:21 -06002801 :term:`ICECC_PARALLEL_MAKE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002802 Extra options passed to the ``make`` command during the
2803 :ref:`ref-tasks-compile` task that specify parallel
2804 compilation. This variable usually takes the form of "-j x", where x
2805 represents the maximum number of parallel threads ``make`` can run.
2806
2807 .. note::
2808
2809 The options passed affect builds on all enabled machines on the
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002810 network, which are machines running the ``iceccd`` daemon.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002811
2812 If your enabled machines support multiple cores, coming up with the
2813 maximum number of parallel threads that gives you the best
2814 performance could take some experimentation since machine speed,
2815 network lag, available memory, and existing machine loads can all
2816 affect build time. Consequently, unlike the
2817 :term:`PARALLEL_MAKE` variable, there is no
2818 rule-of-thumb for setting ``ICECC_PARALLEL_MAKE`` to achieve optimal
2819 performance.
2820
2821 If you do not set ``ICECC_PARALLEL_MAKE``, the build system does not
2822 use it (i.e. the system does not detect and assign the number of
2823 cores as is done with ``PARALLEL_MAKE``).
2824
Andrew Geisslerf0343792020-11-18 10:42:21 -06002825 :term:`ICECC_PATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002826 The location of the ``icecc`` binary. You can set this variable in
2827 your ``local.conf`` file. If your ``local.conf`` file does not define
2828 this variable, the :ref:`icecc <ref-classes-icecc>` class attempts
2829 to define it by locating ``icecc`` using ``which``.
2830
Andrew Geisslerf0343792020-11-18 10:42:21 -06002831 :term:`ICECC_USER_CLASS_BL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002832 Identifies user classes that you do not want the Icecream distributed
2833 compile support to consider. This variable is used by the
2834 :ref:`icecc <ref-classes-icecc>` class. You set this variable in
2835 your ``local.conf`` file.
2836
2837 When you list classes using this variable, you are "blacklisting"
2838 them from distributed compilation across remote hosts. Any classes
2839 you list will be distributed and compiled locally.
2840
Andrew Geisslerf0343792020-11-18 10:42:21 -06002841 :term:`ICECC_USER_PACKAGE_BL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002842 Identifies user recipes that you do not want the Icecream distributed
2843 compile support to consider. This variable is used by the
2844 :ref:`icecc <ref-classes-icecc>` class. You set this variable in
2845 your ``local.conf`` file.
2846
2847 When you list packages using this variable, you are "blacklisting"
2848 them from distributed compilation across remote hosts. Any packages
2849 you list will be distributed and compiled locally.
2850
Andrew Geisslerf0343792020-11-18 10:42:21 -06002851 :term:`ICECC_USER_PACKAGE_WL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002852 Identifies user recipes that use an empty
2853 :term:`PARALLEL_MAKE` variable that you want to
2854 force remote distributed compilation on using the Icecream
2855 distributed compile support. This variable is used by the
2856 :ref:`icecc <ref-classes-icecc>` class. You set this variable in
2857 your ``local.conf`` file.
2858
Andrew Geisslerf0343792020-11-18 10:42:21 -06002859 :term:`IMAGE_BASENAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002860 The base name of image output files. This variable defaults to the
2861 recipe name (``${``\ :term:`PN`\ ``}``).
2862
Andrew Geisslerf0343792020-11-18 10:42:21 -06002863 :term:`IMAGE_EFI_BOOT_FILES`
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002864 A space-separated list of files installed into the boot partition
2865 when preparing an image using the Wic tool with the
2866 ``bootimg-efi`` source plugin. By default,
2867 the files are
2868 installed under the same name as the source files. To change the
2869 installed name, separate it from the original name with a semi-colon
2870 (;). Source files need to be located in
2871 :term:`DEPLOY_DIR_IMAGE`. Here are two
2872 examples:
2873 ::
2874
2875 IMAGE_EFI_BOOT_FILES = "${KERNEL_IMAGETYPE};bz2"
2876 IMAGE_EFI_BOOT_FILES = "${KERNEL_IMAGETYPE} microcode.cpio"
2877
2878 Alternatively, source files can be picked up using a glob pattern. In
2879 this case, the destination file must have the same name as the base
2880 name of the source file path. To install files into a directory
2881 within the target location, pass its name after a semi-colon (;).
2882 Here are two examples:
2883 ::
2884
2885 IMAGE_EFI_BOOT_FILES = "boot/loader/*"
2886 IMAGE_EFI_BOOT_FILES = "boot/loader/*;boot/"
2887
2888 The first example
2889 installs all files from ``${DEPLOY_DIR_IMAGE}/boot/loader/``
2890 into the root of the target partition. The second example installs
2891 the same files into a ``boot`` directory within the target partition.
2892
2893 You can find information on how to use the Wic tool in the
2894 ":ref:`dev-manual/dev-manual-common-tasks:creating partitioned images using wic`"
2895 section of the Yocto Project Development Tasks Manual. Reference
2896 material for Wic is located in the
2897 ":doc:`../ref-manual/ref-kickstart`" chapter.
2898
Andrew Geisslerf0343792020-11-18 10:42:21 -06002899 :term:`IMAGE_BOOT_FILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002900 A space-separated list of files installed into the boot partition
2901 when preparing an image using the Wic tool with the
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05002902 ``bootimg-partition`` source plugin. By default,
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002903 the files are
2904 installed under the same name as the source files. To change the
2905 installed name, separate it from the original name with a semi-colon
2906 (;). Source files need to be located in
2907 :term:`DEPLOY_DIR_IMAGE`. Here are two
2908 examples:
2909 ::
2910
2911 IMAGE_BOOT_FILES = "u-boot.img uImage;kernel"
2912 IMAGE_BOOT_FILES = "u-boot.${UBOOT_SUFFIX} ${KERNEL_IMAGETYPE}"
2913
2914 Alternatively, source files can be picked up using a glob pattern. In
2915 this case, the destination file must have the same name as the base
2916 name of the source file path. To install files into a directory
2917 within the target location, pass its name after a semi-colon (;).
2918 Here are two examples:
2919 ::
2920
2921 IMAGE_BOOT_FILES = "bcm2835-bootfiles/*"
2922 IMAGE_BOOT_FILES = "bcm2835-bootfiles/*;boot/"
2923
2924 The first example
2925 installs all files from ``${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles``
2926 into the root of the target partition. The second example installs
2927 the same files into a ``boot`` directory within the target partition.
2928
2929 You can find information on how to use the Wic tool in the
2930 ":ref:`dev-manual/dev-manual-common-tasks:creating partitioned images using wic`"
2931 section of the Yocto Project Development Tasks Manual. Reference
2932 material for Wic is located in the
2933 ":doc:`../ref-manual/ref-kickstart`" chapter.
2934
Andrew Geisslerf0343792020-11-18 10:42:21 -06002935 :term:`IMAGE_CLASSES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002936 A list of classes that all images should inherit. You typically use
2937 this variable to specify the list of classes that register the
2938 different types of images the OpenEmbedded build system creates.
2939
2940 The default value for ``IMAGE_CLASSES`` is ``image_types``. You can
2941 set this variable in your ``local.conf`` or in a distribution
2942 configuration file.
2943
2944 For more information, see ``meta/classes/image_types.bbclass`` in the
2945 :term:`Source Directory`.
2946
Andrew Geisslerf0343792020-11-18 10:42:21 -06002947 :term:`IMAGE_CMD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002948 Specifies the command to create the image file for a specific image
2949 type, which corresponds to the value set set in
2950 :term:`IMAGE_FSTYPES`, (e.g. ``ext3``,
2951 ``btrfs``, and so forth). When setting this variable, you should use
2952 an override for the associated type. Here is an example:
2953 ::
2954
2955 IMAGE_CMD_jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} \
2956 --faketime --output=${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.jffs2 \
2957 ${EXTRA_IMAGECMD}"
2958
2959 You typically do not need to set this variable unless you are adding
2960 support for a new image type. For more examples on how to set this
2961 variable, see the :ref:`image_types <ref-classes-image_types>`
2962 class file, which is ``meta/classes/image_types.bbclass``.
2963
Andrew Geisslerf0343792020-11-18 10:42:21 -06002964 :term:`IMAGE_DEVICE_TABLES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002965 Specifies one or more files that contain custom device tables that
2966 are passed to the ``makedevs`` command as part of creating an image.
2967 These files list basic device nodes that should be created under
2968 ``/dev`` within the image. If ``IMAGE_DEVICE_TABLES`` is not set,
2969 ``files/device_table-minimal.txt`` is used, which is located by
2970 :term:`BBPATH`. For details on how you should write
2971 device table files, see ``meta/files/device_table-minimal.txt`` as an
2972 example.
2973
Andrew Geisslerf0343792020-11-18 10:42:21 -06002974 :term:`IMAGE_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002975 The primary list of features to include in an image. Typically, you
2976 configure this variable in an image recipe. Although you can use this
2977 variable from your ``local.conf`` file, which is found in the
2978 :term:`Build Directory`, best practices dictate that you do
2979 not.
2980
2981 .. note::
2982
2983 To enable extra features from outside the image recipe, use the
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002984 :term:`EXTRA_IMAGE_FEATURES` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002985
2986 For a list of image features that ships with the Yocto Project, see
Andrew Geissler4c19ea12020-10-27 13:52:24 -05002987 the ":ref:`ref-features-image`" section.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002988
2989 For an example that shows how to customize your image by using this
2990 variable, see the ":ref:`usingpoky-extend-customimage-imagefeatures`"
2991 section in the Yocto Project Development Tasks Manual.
2992
Andrew Geisslerf0343792020-11-18 10:42:21 -06002993 :term:`IMAGE_FSTYPES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05002994 Specifies the formats the OpenEmbedded build system uses during the
2995 build when creating the root filesystem. For example, setting
2996 ``IMAGE_FSTYPES`` as follows causes the build system to create root
2997 filesystems using two formats: ``.ext3`` and ``.tar.bz2``:
2998 ::
2999
3000 IMAGE_FSTYPES = "ext3 tar.bz2"
3001
3002 For the complete list of supported image formats from which you can
3003 choose, see :term:`IMAGE_TYPES`.
3004
3005 .. note::
3006
3007 - If an image recipe uses the "inherit image" line and you are
3008 setting ``IMAGE_FSTYPES`` inside the recipe, you must set
3009 ``IMAGE_FSTYPES`` prior to using the "inherit image" line.
3010
3011 - Due to the way the OpenEmbedded build system processes this
3012 variable, you cannot update its contents by using ``_append``
3013 or ``_prepend``. You must use the ``+=`` operator to add one or
3014 more options to the ``IMAGE_FSTYPES`` variable.
3015
Andrew Geisslerf0343792020-11-18 10:42:21 -06003016 :term:`IMAGE_INSTALL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003017 Used by recipes to specify the packages to install into an image
3018 through the :ref:`image <ref-classes-image>` class. Use the
3019 ``IMAGE_INSTALL`` variable with care to avoid ordering issues.
3020
3021 Image recipes set ``IMAGE_INSTALL`` to specify the packages to
3022 install into an image through ``image.bbclass``. Additionally,
3023 "helper" classes such as the
3024 :ref:`core-image <ref-classes-core-image>` class exist that can
3025 take lists used with ``IMAGE_FEATURES`` and turn them into
3026 auto-generated entries in ``IMAGE_INSTALL`` in addition to its
3027 default contents.
3028
3029 When you use this variable, it is best to use it as follows:
3030 ::
3031
3032 IMAGE_INSTALL_append = " package-name"
3033
3034 Be sure to include the space
3035 between the quotation character and the start of the package name or
3036 names.
3037
3038 .. note::
3039
3040 - When working with a
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003041 :ref:`core-image-minimal-initramfs <ref-manual/ref-images:images>`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003042 image, do not use the ``IMAGE_INSTALL`` variable to specify
3043 packages for installation. Instead, use the
3044 :term:`PACKAGE_INSTALL` variable, which
3045 allows the initial RAM filesystem (initramfs) recipe to use a
3046 fixed set of packages and not be affected by ``IMAGE_INSTALL``.
3047 For information on creating an initramfs, see the
3048 ":ref:`building-an-initramfs-image`"
3049 section in the Yocto Project Development Tasks Manual.
3050
3051 - Using ``IMAGE_INSTALL`` with the
3052 :ref:`+= <bitbake:appending-and-prepending>`
3053 BitBake operator within the ``/conf/local.conf`` file or from
3054 within an image recipe is not recommended. Use of this operator
3055 in these ways can cause ordering issues. Since
3056 ``core-image.bbclass`` sets ``IMAGE_INSTALL`` to a default
3057 value using the
3058 :ref:`?= <bitbake:bitbake-user-manual/bitbake-user-manual-metadata:setting a default value (?=)>`
3059 operator, using a ``+=`` operation against ``IMAGE_INSTALL``
3060 results in unexpected behavior when used within
3061 ``conf/local.conf``. Furthermore, the same operation from
3062 within an image recipe may or may not succeed depending on the
3063 specific situation. In both these cases, the behavior is
3064 contrary to how most users expect the ``+=`` operator to work.
3065
Andrew Geisslerf0343792020-11-18 10:42:21 -06003066 :term:`IMAGE_LINGUAS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003067 Specifies the list of locales to install into the image during the
3068 root filesystem construction process. The OpenEmbedded build system
3069 automatically splits locale files, which are used for localization,
3070 into separate packages. Setting the ``IMAGE_LINGUAS`` variable
3071 ensures that any locale packages that correspond to packages already
3072 selected for installation into the image are also installed. Here is
3073 an example:
3074 ::
3075
3076 IMAGE_LINGUAS = "pt-br de-de"
3077
3078 In this example, the build system ensures any Brazilian Portuguese
3079 and German locale files that correspond to packages in the image are
3080 installed (i.e. ``*-locale-pt-br`` and ``*-locale-de-de`` as well as
3081 ``*-locale-pt`` and ``*-locale-de``, since some software packages
3082 only provide locale files by language and not by country-specific
3083 language).
3084
3085 See the :term:`GLIBC_GENERATE_LOCALES`
3086 variable for information on generating GLIBC locales.
3087
Andrew Geisslerf0343792020-11-18 10:42:21 -06003088 :term:`IMAGE_MANIFEST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003089 The manifest file for the image. This file lists all the installed
3090 packages that make up the image. The file contains package
3091 information on a line-per-package basis as follows:
3092 ::
3093
3094 packagename packagearch version
3095
3096 The :ref:`image <ref-classes-image>` class defines the manifest
3097 file as follows:
3098 ::
3099
3100 IMAGE_MANIFEST ="${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.manifest"
3101
3102 The location is
3103 derived using the :term:`DEPLOY_DIR_IMAGE`
3104 and :term:`IMAGE_NAME` variables. You can find
3105 information on how the image is created in the ":ref:`image-generation-dev-environment`"
3106 section in the Yocto Project Overview and Concepts Manual.
3107
Andrew Geisslerf0343792020-11-18 10:42:21 -06003108 :term:`IMAGE_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003109 The name of the output image files minus the extension. This variable
3110 is derived using the :term:`IMAGE_BASENAME`,
3111 :term:`MACHINE`, and :term:`DATETIME`
3112 variables:
3113 ::
3114
3115 IMAGE_NAME = "${IMAGE_BASENAME}-${MACHINE}-${DATETIME}"
3116
Andrew Geisslerf0343792020-11-18 10:42:21 -06003117 :term:`IMAGE_OVERHEAD_FACTOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003118 Defines a multiplier that the build system applies to the initial
3119 image size for cases when the multiplier times the returned disk
3120 usage value for the image is greater than the sum of
3121 ``IMAGE_ROOTFS_SIZE`` and ``IMAGE_ROOTFS_EXTRA_SPACE``. The result of
3122 the multiplier applied to the initial image size creates free disk
3123 space in the image as overhead. By default, the build process uses a
3124 multiplier of 1.3 for this variable. This default value results in
3125 30% free disk space added to the image when this method is used to
3126 determine the final generated image size. You should be aware that
3127 post install scripts and the package management system uses disk
3128 space inside this overhead area. Consequently, the multiplier does
3129 not produce an image with all the theoretical free disk space. See
3130 ``IMAGE_ROOTFS_SIZE`` for information on how the build system
3131 determines the overall image size.
3132
3133 The default 30% free disk space typically gives the image enough room
3134 to boot and allows for basic post installs while still leaving a
3135 small amount of free disk space. If 30% free space is inadequate, you
3136 can increase the default value. For example, the following setting
3137 gives you 50% free space added to the image:
3138 ::
3139
3140 IMAGE_OVERHEAD_FACTOR = "1.5"
3141
3142 Alternatively, you can ensure a specific amount of free disk space is
3143 added to the image by using the ``IMAGE_ROOTFS_EXTRA_SPACE``
3144 variable.
3145
Andrew Geisslerf0343792020-11-18 10:42:21 -06003146 :term:`IMAGE_PKGTYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003147 Defines the package type (i.e. DEB, RPM, IPK, or TAR) used by the
3148 OpenEmbedded build system. The variable is defined appropriately by
3149 the :ref:`package_deb <ref-classes-package_deb>`,
3150 :ref:`package_rpm <ref-classes-package_rpm>`,
3151 :ref:`package_ipk <ref-classes-package_ipk>`, or
3152 :ref:`package_tar <ref-classes-package_tar>` class.
3153
3154 .. note::
3155
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003156 The ``package_tar`` class is broken and is not supported. It is
3157 recommended that you do not use it.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003158
3159 The :ref:`populate_sdk_* <ref-classes-populate-sdk-*>` and
3160 :ref:`image <ref-classes-image>` classes use the ``IMAGE_PKGTYPE``
3161 for packaging up images and SDKs.
3162
3163 You should not set the ``IMAGE_PKGTYPE`` manually. Rather, the
3164 variable is set indirectly through the appropriate
3165 :ref:`package_* <ref-classes-package>` class using the
3166 :term:`PACKAGE_CLASSES` variable. The
3167 OpenEmbedded build system uses the first package type (e.g. DEB, RPM,
3168 or IPK) that appears with the variable
3169
3170 .. note::
3171
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003172 Files using the ``.tar`` format are never used as a substitute
3173 packaging format for DEB, RPM, and IPK formatted files for your image
3174 or SDK.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003175
Andrew Geisslerf0343792020-11-18 10:42:21 -06003176 :term:`IMAGE_POSTPROCESS_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003177 Specifies a list of functions to call once the OpenEmbedded build
3178 system creates the final image output files. You can specify
3179 functions separated by semicolons:
3180 ::
3181
3182 IMAGE_POSTPROCESS_COMMAND += "function; ... "
3183
3184 If you need to pass the root filesystem path to a command within the
3185 function, you can use ``${IMAGE_ROOTFS}``, which points to the
3186 directory that becomes the root filesystem image. See the
3187 :term:`IMAGE_ROOTFS` variable for more
3188 information.
3189
Andrew Geisslerf0343792020-11-18 10:42:21 -06003190 :term:`IMAGE_PREPROCESS_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003191 Specifies a list of functions to call before the OpenEmbedded build
3192 system creates the final image output files. You can specify
3193 functions separated by semicolons:
3194 ::
3195
3196 IMAGE_PREPROCESS_COMMAND += "function; ... "
3197
3198 If you need to pass the root filesystem path to a command within the
3199 function, you can use ``${IMAGE_ROOTFS}``, which points to the
3200 directory that becomes the root filesystem image. See the
3201 :term:`IMAGE_ROOTFS` variable for more
3202 information.
3203
Andrew Geisslerf0343792020-11-18 10:42:21 -06003204 :term:`IMAGE_ROOTFS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003205 The location of the root filesystem while it is under construction
3206 (i.e. during the :ref:`ref-tasks-rootfs` task). This
3207 variable is not configurable. Do not change it.
3208
Andrew Geisslerf0343792020-11-18 10:42:21 -06003209 :term:`IMAGE_ROOTFS_ALIGNMENT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003210 Specifies the alignment for the output image file in Kbytes. If the
3211 size of the image is not a multiple of this value, then the size is
3212 rounded up to the nearest multiple of the value. The default value is
3213 "1". See :term:`IMAGE_ROOTFS_SIZE` for
3214 additional information.
3215
Andrew Geisslerf0343792020-11-18 10:42:21 -06003216 :term:`IMAGE_ROOTFS_EXTRA_SPACE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003217 Defines additional free disk space created in the image in Kbytes. By
3218 default, this variable is set to "0". This free disk space is added
3219 to the image after the build system determines the image size as
3220 described in ``IMAGE_ROOTFS_SIZE``.
3221
3222 This variable is particularly useful when you want to ensure that a
3223 specific amount of free disk space is available on a device after an
3224 image is installed and running. For example, to be sure 5 Gbytes of
3225 free disk space is available, set the variable as follows:
3226 ::
3227
3228 IMAGE_ROOTFS_EXTRA_SPACE = "5242880"
3229
3230 For example, the Yocto Project Build Appliance specifically requests
3231 40 Gbytes of extra space with the line:
3232 ::
3233
3234 IMAGE_ROOTFS_EXTRA_SPACE = "41943040"
3235
Andrew Geisslerf0343792020-11-18 10:42:21 -06003236 :term:`IMAGE_ROOTFS_SIZE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003237 Defines the size in Kbytes for the generated image. The OpenEmbedded
3238 build system determines the final size for the generated image using
3239 an algorithm that takes into account the initial disk space used for
3240 the generated image, a requested size for the image, and requested
3241 additional free disk space to be added to the image. Programatically,
3242 the build system determines the final size of the generated image as
3243 follows:
3244 ::
3245
3246 if (image-du * overhead) < rootfs-size:
3247 internal-rootfs-size = rootfs-size + xspace
3248 else:
3249 internal-rootfs-size = (image-du * overhead) + xspace
3250 where:
3251 image-du = Returned value of the du command on the image.
3252 overhead = IMAGE_OVERHEAD_FACTOR
3253 rootfs-size = IMAGE_ROOTFS_SIZE
3254 internal-rootfs-size = Initial root filesystem size before any modifications.
3255 xspace = IMAGE_ROOTFS_EXTRA_SPACE
3256
3257 See the :term:`IMAGE_OVERHEAD_FACTOR`
3258 and :term:`IMAGE_ROOTFS_EXTRA_SPACE`
3259 variables for related information.
3260
Andrew Geisslerf0343792020-11-18 10:42:21 -06003261 :term:`IMAGE_TYPEDEP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003262 Specifies a dependency from one image type on another. Here is an
3263 example from the :ref:`image-live <ref-classes-image-live>` class:
3264 ::
3265
3266 IMAGE_TYPEDEP_live = "ext3"
3267
3268 In the previous example, the variable ensures that when "live" is
3269 listed with the :term:`IMAGE_FSTYPES` variable,
3270 the OpenEmbedded build system produces an ``ext3`` image first since
3271 one of the components of the live image is an ``ext3`` formatted
3272 partition containing the root filesystem.
3273
Andrew Geisslerf0343792020-11-18 10:42:21 -06003274 :term:`IMAGE_TYPES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003275 Specifies the complete list of supported image types by default:
3276
3277 - btrfs
3278 - container
3279 - cpio
3280 - cpio.gz
3281 - cpio.lz4
3282 - cpio.lzma
3283 - cpio.xz
3284 - cramfs
3285 - ext2
3286 - ext2.bz2
3287 - ext2.gz
3288 - ext2.lzma
3289 - ext3
3290 - ext3.gz
3291 - ext4
3292 - ext4.gz
3293 - f2fs
3294 - hddimg
3295 - iso
3296 - jffs2
3297 - jffs2.sum
3298 - multiubi
3299 - squashfs
3300 - squashfs-lz4
3301 - squashfs-lzo
3302 - squashfs-xz
3303 - tar
3304 - tar.bz2
3305 - tar.gz
3306 - tar.lz4
3307 - tar.xz
3308 - tar.zst
3309 - ubi
3310 - ubifs
3311 - wic
3312 - wic.bz2
3313 - wic.gz
3314 - wic.lzma
3315
3316 For more information about these types of images, see
3317 ``meta/classes/image_types*.bbclass`` in the :term:`Source Directory`.
3318
Andrew Geisslerf0343792020-11-18 10:42:21 -06003319 :term:`INC_PR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003320 Helps define the recipe revision for recipes that share a common
3321 ``include`` file. You can think of this variable as part of the
3322 recipe revision as set from within an include file.
3323
3324 Suppose, for example, you have a set of recipes that are used across
3325 several projects. And, within each of those recipes the revision (its
3326 :term:`PR` value) is set accordingly. In this case, when
3327 the revision of those recipes changes, the burden is on you to find
3328 all those recipes and be sure that they get changed to reflect the
3329 updated version of the recipe. In this scenario, it can get
3330 complicated when recipes that are used in many places and provide
3331 common functionality are upgraded to a new revision.
3332
3333 A more efficient way of dealing with this situation is to set the
3334 ``INC_PR`` variable inside the ``include`` files that the recipes
3335 share and then expand the ``INC_PR`` variable within the recipes to
3336 help define the recipe revision.
3337
3338 The following provides an example that shows how to use the
3339 ``INC_PR`` variable given a common ``include`` file that defines the
3340 variable. Once the variable is defined in the ``include`` file, you
3341 can use the variable to set the ``PR`` values in each recipe. You
3342 will notice that when you set a recipe's ``PR`` you can provide more
3343 granular revisioning by appending values to the ``INC_PR`` variable:
3344 ::
3345
3346 recipes-graphics/xorg-font/xorg-font-common.inc:INC_PR = "r2"
3347 recipes-graphics/xorg-font/encodings_1.0.4.bb:PR = "${INC_PR}.1"
3348 recipes-graphics/xorg-font/font-util_1.3.0.bb:PR = "${INC_PR}.0"
3349 recipes-graphics/xorg-font/font-alias_1.0.3.bb:PR = "${INC_PR}.3"
3350
3351 The
3352 first line of the example establishes the baseline revision to be
3353 used for all recipes that use the ``include`` file. The remaining
3354 lines in the example are from individual recipes and show how the
3355 ``PR`` value is set.
3356
Andrew Geisslerf0343792020-11-18 10:42:21 -06003357 :term:`INCOMPATIBLE_LICENSE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003358 Specifies a space-separated list of license names (as they would
3359 appear in :term:`LICENSE`) that should be excluded
3360 from the build. Recipes that provide no alternatives to listed
3361 incompatible licenses are not built. Packages that are individually
3362 licensed with the specified incompatible licenses will be deleted.
3363
3364 .. note::
3365
3366 This functionality is only regularly tested using the following
3367 setting:
3368 ::
3369
3370 INCOMPATIBLE_LICENSE = "GPL-3.0 LGPL-3.0 AGPL-3.0"
3371
3372
3373 Although you can use other settings, you might be required to
3374 remove dependencies on or provide alternatives to components that
3375 are required to produce a functional system image.
3376
3377 .. note::
3378
3379 It is possible to define a list of licenses that are allowed to be
3380 used instead of the licenses that are excluded. To do this, define
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003381 a variable ``COMPATIBLE_LICENSES`` with the names of the licences
3382 that are allowed. Then define ``INCOMPATIBLE_LICENSE`` as:
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003383 ::
3384
3385 INCOMPATIBLE_LICENSE = "${@' '.join(sorted(set(d.getVar('AVAILABLE_LICENSES').split()) - set(d.getVar('COMPATIBLE_LICENSES').split())))}"
3386
3387
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003388 This will result in ``INCOMPATIBLE_LICENSE`` containing the names of
3389 all licences from :term:`AVAILABLE_LICENSES` except the ones specified
3390 in ``COMPATIBLE_LICENSES`` , thus only allowing the latter licences to
3391 be used.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003392
Andrew Geisslerf0343792020-11-18 10:42:21 -06003393 :term:`INHERIT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003394 Causes the named class or classes to be inherited globally. Anonymous
3395 functions in the class or classes are not executed for the base
3396 configuration and in each individual recipe. The OpenEmbedded build
3397 system ignores changes to ``INHERIT`` in individual recipes.
3398
3399 For more information on ``INHERIT``, see the
3400 :ref:`bitbake:bitbake-user-manual/bitbake-user-manual-metadata:\`\`inherit\`\` configuration directive`"
3401 section in the Bitbake User Manual.
3402
Andrew Geisslerf0343792020-11-18 10:42:21 -06003403 :term:`INHERIT_DISTRO`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003404 Lists classes that will be inherited at the distribution level. It is
3405 unlikely that you want to edit this variable.
3406
3407 The default value of the variable is set as follows in the
3408 ``meta/conf/distro/defaultsetup.conf`` file:
3409 ::
3410
3411 INHERIT_DISTRO ?= "debian devshell sstate license"
3412
Andrew Geisslerf0343792020-11-18 10:42:21 -06003413 :term:`INHIBIT_DEFAULT_DEPS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003414 Prevents the default dependencies, namely the C compiler and standard
3415 C library (libc), from being added to :term:`DEPENDS`.
3416 This variable is usually used within recipes that do not require any
3417 compilation using the C compiler.
3418
3419 Set the variable to "1" to prevent the default dependencies from
3420 being added.
3421
Andrew Geisslerf0343792020-11-18 10:42:21 -06003422 :term:`INHIBIT_PACKAGE_DEBUG_SPLIT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003423 Prevents the OpenEmbedded build system from splitting out debug
3424 information during packaging. By default, the build system splits out
3425 debugging information during the
3426 :ref:`ref-tasks-package` task. For more information on
3427 how debug information is split out, see the
3428 :term:`PACKAGE_DEBUG_SPLIT_STYLE`
3429 variable.
3430
3431 To prevent the build system from splitting out debug information
3432 during packaging, set the ``INHIBIT_PACKAGE_DEBUG_SPLIT`` variable as
3433 follows:
3434 ::
3435
3436 INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
3437
Andrew Geisslerf0343792020-11-18 10:42:21 -06003438 :term:`INHIBIT_PACKAGE_STRIP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003439 If set to "1", causes the build to not strip binaries in resulting
3440 packages and prevents the ``-dbg`` package from containing the source
3441 files.
3442
3443 By default, the OpenEmbedded build system strips binaries and puts
3444 the debugging symbols into ``${``\ :term:`PN`\ ``}-dbg``.
3445 Consequently, you should not set ``INHIBIT_PACKAGE_STRIP`` when you
3446 plan to debug in general.
3447
Andrew Geisslerf0343792020-11-18 10:42:21 -06003448 :term:`INHIBIT_SYSROOT_STRIP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003449 If set to "1", causes the build to not strip binaries in the
3450 resulting sysroot.
3451
3452 By default, the OpenEmbedded build system strips binaries in the
3453 resulting sysroot. When you specifically set the
3454 ``INHIBIT_SYSROOT_STRIP`` variable to "1" in your recipe, you inhibit
3455 this stripping.
3456
3457 If you want to use this variable, include the
3458 :ref:`staging <ref-classes-staging>` class. This class uses a
3459 ``sys_strip()`` function to test for the variable and acts
3460 accordingly.
3461
3462 .. note::
3463
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003464 Use of the ``INHIBIT_SYSROOT_STRIP`` variable occurs in rare and
3465 special circumstances. For example, suppose you are building
3466 bare-metal firmware by using an external GCC toolchain. Furthermore,
3467 even if the toolchain's binaries are strippable, other files exist
3468 that are needed for the build that are not strippable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003469
Andrew Geisslerf0343792020-11-18 10:42:21 -06003470 :term:`INITRAMFS_FSTYPES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003471 Defines the format for the output image of an initial RAM filesystem
3472 (initramfs), which is used during boot. Supported formats are the
3473 same as those supported by the
3474 :term:`IMAGE_FSTYPES` variable.
3475
3476 The default value of this variable, which is set in the
3477 ``meta/conf/bitbake.conf`` configuration file in the
3478 :term:`Source Directory`, is "cpio.gz". The Linux kernel's
3479 initramfs mechanism, as opposed to the initial RAM filesystem
3480 `initrd <https://en.wikipedia.org/wiki/Initrd>`__ mechanism, expects
3481 an optionally compressed cpio archive.
3482
Andrew Geisslerf0343792020-11-18 10:42:21 -06003483 :term:`INITRAMFS_IMAGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003484 Specifies the :term:`PROVIDES` name of an image
3485 recipe that is used to build an initial RAM filesystem (initramfs)
3486 image. In other words, the ``INITRAMFS_IMAGE`` variable causes an
3487 additional recipe to be built as a dependency to whatever root
3488 filesystem recipe you might be using (e.g. ``core-image-sato``). The
3489 initramfs image recipe you provide should set
3490 :term:`IMAGE_FSTYPES` to
3491 :term:`INITRAMFS_FSTYPES`.
3492
3493 An initramfs image provides a temporary root filesystem used for
3494 early system initialization (e.g. loading of modules needed to locate
3495 and mount the "real" root filesystem).
3496
3497 .. note::
3498
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003499 See the ``meta/recipes-core/images/core-image-minimal-initramfs.bb``
3500 recipe in the :term:`Source Directory`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003501 for an example initramfs recipe. To select this sample recipe as
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003502 the one built to provide the initramfs image, set ``INITRAMFS_IMAGE``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003503 to "core-image-minimal-initramfs".
3504
3505 You can also find more information by referencing the
3506 ``meta-poky/conf/local.conf.sample.extended`` configuration file in
3507 the Source Directory, the :ref:`image <ref-classes-image>` class,
3508 and the :ref:`kernel <ref-classes-kernel>` class to see how to use
3509 the ``INITRAMFS_IMAGE`` variable.
3510
3511 If ``INITRAMFS_IMAGE`` is empty, which is the default, then no
3512 initramfs image is built.
3513
3514 For more information, you can also see the
3515 :term:`INITRAMFS_IMAGE_BUNDLE`
3516 variable, which allows the generated image to be bundled inside the
3517 kernel image. Additionally, for information on creating an initramfs
3518 image, see the ":ref:`building-an-initramfs-image`" section
3519 in the Yocto Project Development Tasks Manual.
3520
Andrew Geisslerf0343792020-11-18 10:42:21 -06003521 :term:`INITRAMFS_IMAGE_BUNDLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003522 Controls whether or not the image recipe specified by
3523 :term:`INITRAMFS_IMAGE` is run through an
3524 extra pass
3525 (:ref:`ref-tasks-bundle_initramfs`) during
3526 kernel compilation in order to build a single binary that contains
3527 both the kernel image and the initial RAM filesystem (initramfs)
3528 image. This makes use of the
3529 :term:`CONFIG_INITRAMFS_SOURCE` kernel
3530 feature.
3531
3532 .. note::
3533
3534 Using an extra compilation pass to bundle the initramfs avoids a
3535 circular dependency between the kernel recipe and the initramfs
3536 recipe should the initramfs include kernel modules. Should that be
3537 the case, the initramfs recipe depends on the kernel for the
3538 kernel modules, and the kernel depends on the initramfs recipe
3539 since the initramfs is bundled inside the kernel image.
3540
3541 The combined binary is deposited into the ``tmp/deploy`` directory,
3542 which is part of the :term:`Build Directory`.
3543
3544 Setting the variable to "1" in a configuration file causes the
3545 OpenEmbedded build system to generate a kernel image with the
3546 initramfs specified in ``INITRAMFS_IMAGE`` bundled within:
3547 ::
3548
3549 INITRAMFS_IMAGE_BUNDLE = "1"
3550
3551 By default, the
3552 :ref:`kernel <ref-classes-kernel>` class sets this variable to a
3553 null string as follows:
3554 ::
3555
3556 INITRAMFS_IMAGE_BUNDLE ?= ""
3557
3558 .. note::
3559
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003560 You must set the ``INITRAMFS_IMAGE_BUNDLE`` variable in a
3561 configuration file. You cannot set the variable in a recipe file.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003562
3563 See the
3564 :yocto_git:`local.conf.sample.extended </cgit/cgit.cgi/poky/tree/meta-poky/conf/local.conf.sample.extended>`
3565 file for additional information. Also, for information on creating an
3566 initramfs, see the ":ref:`building-an-initramfs-image`" section
3567 in the Yocto Project Development Tasks Manual.
3568
Andrew Geisslerf0343792020-11-18 10:42:21 -06003569 :term:`INITRAMFS_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003570 The link name of the initial RAM filesystem image. This variable is
3571 set in the ``meta/classes/kernel-artifact-names.bbclass`` file as
3572 follows:
3573 ::
3574
3575 INITRAMFS_LINK_NAME ?= "initramfs-${KERNEL_ARTIFACT_LINK_NAME}"
3576
3577 The value of the
3578 ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same
3579 file, has the following value:
3580 ::
3581
3582 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
3583
3584 See the :term:`MACHINE` variable for additional
3585 information.
3586
Andrew Geisslerf0343792020-11-18 10:42:21 -06003587 :term:`INITRAMFS_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003588 The base name of the initial RAM filesystem image. This variable is
3589 set in the ``meta/classes/kernel-artifact-names.bbclass`` file as
3590 follows:
3591 ::
3592
3593 INITRAMFS_NAME ?= "initramfs-${KERNEL_ARTIFACT_NAME}"
3594
3595 The value of the :term:`KERNEL_ARTIFACT_NAME`
3596 variable, which is set in the same file, has the following value:
3597 ::
3598
3599 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
3600
Andrew Geisslerf0343792020-11-18 10:42:21 -06003601 :term:`INITRD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003602 Indicates list of filesystem images to concatenate and use as an
3603 initial RAM disk (``initrd``).
3604
3605 The ``INITRD`` variable is an optional variable used with the
3606 :ref:`image-live <ref-classes-image-live>` class.
3607
Andrew Geisslerf0343792020-11-18 10:42:21 -06003608 :term:`INITRD_IMAGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003609 When building a "live" bootable image (i.e. when
3610 :term:`IMAGE_FSTYPES` contains "live"),
3611 ``INITRD_IMAGE`` specifies the image recipe that should be built to
3612 provide the initial RAM disk image. The default value is
3613 "core-image-minimal-initramfs".
3614
3615 See the :ref:`image-live <ref-classes-image-live>` class for more
3616 information.
3617
Andrew Geisslerf0343792020-11-18 10:42:21 -06003618 :term:`INITSCRIPT_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003619 The filename of the initialization script as installed to
3620 ``${sysconfdir}/init.d``.
3621
3622 This variable is used in recipes when using ``update-rc.d.bbclass``.
3623 The variable is mandatory.
3624
Andrew Geisslerf0343792020-11-18 10:42:21 -06003625 :term:`INITSCRIPT_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003626 A list of the packages that contain initscripts. If multiple packages
3627 are specified, you need to append the package name to the other
3628 ``INITSCRIPT_*`` as an override.
3629
3630 This variable is used in recipes when using ``update-rc.d.bbclass``.
3631 The variable is optional and defaults to the :term:`PN`
3632 variable.
3633
Andrew Geisslerf0343792020-11-18 10:42:21 -06003634 :term:`INITSCRIPT_PARAMS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003635 Specifies the options to pass to ``update-rc.d``. Here is an example:
3636 ::
3637
3638 INITSCRIPT_PARAMS = "start 99 5 2 . stop 20 0 1 6 ."
3639
3640 In this example, the script has a runlevel of 99, starts the script
3641 in initlevels 2 and 5, and stops the script in levels 0, 1 and 6.
3642
3643 The variable's default value is "defaults", which is set in the
3644 :ref:`update-rc.d <ref-classes-update-rc.d>` class.
3645
3646 The value in ``INITSCRIPT_PARAMS`` is passed through to the
3647 ``update-rc.d`` command. For more information on valid parameters,
3648 please see the ``update-rc.d`` manual page at
Andrew Geisslerc3d88e42020-10-02 09:45:00 -05003649 https://manpages.debian.org/buster/init-system-helpers/update-rc.d.8.en.html
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003650
Andrew Geisslerf0343792020-11-18 10:42:21 -06003651 :term:`INSANE_SKIP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003652 Specifies the QA checks to skip for a specific package within a
3653 recipe. For example, to skip the check for symbolic link ``.so``
3654 files in the main package of a recipe, add the following to the
3655 recipe. The package name override must be used, which in this example
3656 is ``${PN}``:
3657 ::
3658
3659 INSANE_SKIP_${PN} += "dev-so"
3660
3661 See the ":ref:`insane.bbclass <ref-classes-insane>`" section for a
3662 list of the valid QA checks you can specify using this variable.
3663
Andrew Geisslerf0343792020-11-18 10:42:21 -06003664 :term:`INSTALL_TIMEZONE_FILE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003665 By default, the ``tzdata`` recipe packages an ``/etc/timezone`` file.
3666 Set the ``INSTALL_TIMEZONE_FILE`` variable to "0" at the
3667 configuration level to disable this behavior.
3668
Andrew Geisslerf0343792020-11-18 10:42:21 -06003669 :term:`IPK_FEED_URIS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003670 When the IPK backend is in use and package management is enabled on
3671 the target, you can use this variable to set up ``opkg`` in the
3672 target image to point to package feeds on a nominated server. Once
3673 the feed is established, you can perform installations or upgrades
3674 using the package manager at runtime.
3675
Andrew Geisslerf0343792020-11-18 10:42:21 -06003676 :term:`KARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003677 Defines the kernel architecture used when assembling the
3678 configuration. Architectures supported for this release are:
3679
3680 - powerpc
3681 - i386
3682 - x86_64
3683 - arm
3684 - qemu
3685 - mips
3686
3687 You define the ``KARCH`` variable in the :ref:`kernel-dev/kernel-dev-advanced:bsp descriptions`.
3688
Andrew Geisslerf0343792020-11-18 10:42:21 -06003689 :term:`KBRANCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003690 A regular expression used by the build process to explicitly identify
3691 the kernel branch that is validated, patched, and configured during a
3692 build. You must set this variable to ensure the exact kernel branch
3693 you want is being used by the build process.
3694
3695 Values for this variable are set in the kernel's recipe file and the
3696 kernel's append file. For example, if you are using the
3697 ``linux-yocto_4.12`` kernel, the kernel recipe file is the
3698 ``meta/recipes-kernel/linux/linux-yocto_4.12.bb`` file. ``KBRANCH``
3699 is set as follows in that kernel recipe file:
3700 ::
3701
3702 KBRANCH ?= "standard/base"
3703
3704 This variable is also used from the kernel's append file to identify
3705 the kernel branch specific to a particular machine or target
3706 hardware. Continuing with the previous kernel example, the kernel's
3707 append file (i.e. ``linux-yocto_4.12.bbappend``) is located in the
3708 BSP layer for a given machine. For example, the append file for the
3709 Beaglebone, EdgeRouter, and generic versions of both 32 and 64-bit IA
3710 machines (``meta-yocto-bsp``) is named
3711 ``meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend``.
3712 Here are the related statements from that append file:
3713 ::
3714
3715 KBRANCH_genericx86 = "standard/base"
3716 KBRANCH_genericx86-64 = "standard/base"
3717 KBRANCH_edgerouter = "standard/edgerouter"
3718 KBRANCH_beaglebone = "standard/beaglebone"
3719
3720 The ``KBRANCH`` statements
3721 identify the kernel branch to use when building for each supported
3722 BSP.
3723
Andrew Geisslerf0343792020-11-18 10:42:21 -06003724 :term:`KBUILD_DEFCONFIG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003725 When used with the :ref:`kernel-yocto <ref-classes-kernel-yocto>`
3726 class, specifies an "in-tree" kernel configuration file for use
3727 during a kernel build.
3728
3729 Typically, when using a ``defconfig`` to configure a kernel during a
3730 build, you place the file in your layer in the same manner as you
3731 would place patch files and configuration fragment files (i.e.
3732 "out-of-tree"). However, if you want to use a ``defconfig`` file that
3733 is part of the kernel tree (i.e. "in-tree"), you can use the
3734 ``KBUILD_DEFCONFIG`` variable and append the
3735 :term:`KMACHINE` variable to point to the
3736 ``defconfig`` file.
3737
3738 To use the variable, set it in the append file for your kernel recipe
3739 using the following form:
3740 ::
3741
3742 KBUILD_DEFCONFIG_KMACHINE ?= defconfig_file
3743
3744 Here is an example from a "raspberrypi2" ``KMACHINE`` build that uses
3745 a ``defconfig`` file named "bcm2709_defconfig":
3746 ::
3747
3748 KBUILD_DEFCONFIG_raspberrypi2 = "bcm2709_defconfig"
3749
3750 As an alternative, you can use the following within your append file:
3751 ::
3752
3753 KBUILD_DEFCONFIG_pn-linux-yocto ?= defconfig_file
3754
3755 For more
3756 information on how to use the ``KBUILD_DEFCONFIG`` variable, see the
3757 ":ref:`kernel-dev/kernel-dev-common:using an "in-tree" \`\`defconfig\`\` file`"
3758 section in the Yocto Project Linux Kernel Development Manual.
3759
Andrew Geisslerf0343792020-11-18 10:42:21 -06003760 :term:`KERNEL_ALT_IMAGETYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003761 Specifies an alternate kernel image type for creation in addition to
3762 the kernel image type specified using the
3763 :term:`KERNEL_IMAGETYPE` variable.
3764
Andrew Geisslerf0343792020-11-18 10:42:21 -06003765 :term:`KERNEL_ARTIFACT_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003766 Specifies the name of all of the build artifacts. You can change the
3767 name of the artifacts by changing the ``KERNEL_ARTIFACT_NAME``
3768 variable.
3769
3770 The value of ``KERNEL_ARTIFACT_NAME``, which is set in the
3771 ``meta/classes/kernel-artifact-names.bbclass`` file, has the
3772 following default value:
3773 ::
3774
3775 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
3776
3777 See the :term:`PKGE`, :term:`PKGV`, :term:`PKGR`, and :term:`MACHINE`
3778 variables for additional information.
3779
3780 .. note::
3781
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003782 The ``IMAGE_VERSION_SUFFIX`` variable is set to :term:`DATETIME`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003783
Andrew Geisslerf0343792020-11-18 10:42:21 -06003784 :term:`KERNEL_CLASSES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003785 A list of classes defining kernel image types that the
3786 :ref:`kernel <ref-classes-kernel>` class should inherit. You
3787 typically append this variable to enable extended image types. An
3788 example is the "kernel-fitimage", which enables fitImage support and
3789 resides in ``meta/classes/kernel-fitimage.bbclass``. You can register
3790 custom kernel image types with the ``kernel`` class using this
3791 variable.
3792
Andrew Geisslerf0343792020-11-18 10:42:21 -06003793 :term:`KERNEL_DEVICETREE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003794 Specifies the name of the generated Linux kernel device tree (i.e.
3795 the ``.dtb``) file.
3796
3797 .. note::
3798
3799 Legacy support exists for specifying the full path to the device
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003800 tree. However, providing just the ``.dtb`` file is preferred.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003801
3802 In order to use this variable, the
3803 :ref:`kernel-devicetree <ref-classes-kernel-devicetree>` class must
3804 be inherited.
3805
Andrew Geisslerf0343792020-11-18 10:42:21 -06003806 :term:`KERNEL_DTB_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003807 The link name of the kernel device tree binary (DTB). This variable
3808 is set in the ``meta/classes/kernel-artifact-names.bbclass`` file as
3809 follows:
3810 ::
3811
3812 KERNEL_DTB_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
3813
3814 The
3815 value of the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in
3816 the same file, has the following value:
3817 ::
3818
3819 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
3820
3821 See the :term:`MACHINE` variable for additional
3822 information.
3823
Andrew Geisslerf0343792020-11-18 10:42:21 -06003824 :term:`KERNEL_DTB_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003825 The base name of the kernel device tree binary (DTB). This variable
3826 is set in the ``meta/classes/kernel-artifact-names.bbclass`` file as
3827 follows:
3828 ::
3829
3830 KERNEL_DTB_NAME ?= "${KERNEL_ARTIFACT_NAME}"
3831
3832 The value of the :term:`KERNEL_ARTIFACT_NAME`
3833 variable, which is set in the same file, has the following value:
3834 ::
3835
3836 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
3837
Andrew Geisslerf0343792020-11-18 10:42:21 -06003838 :term:`KERNEL_EXTRA_ARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003839 Specifies additional ``make`` command-line arguments the OpenEmbedded
3840 build system passes on when compiling the kernel.
3841
Andrew Geisslerf0343792020-11-18 10:42:21 -06003842 :term:`KERNEL_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003843 Includes additional kernel metadata. In the OpenEmbedded build
3844 system, the default Board Support Packages (BSPs)
3845 :term:`Metadata` is provided through the
3846 :term:`KMACHINE` and :term:`KBRANCH`
3847 variables. You can use the ``KERNEL_FEATURES`` variable from within
3848 the kernel recipe or kernel append file to further add metadata for
3849 all BSPs or specific BSPs.
3850
3851 The metadata you add through this variable includes config fragments
3852 and features descriptions, which usually includes patches as well as
3853 config fragments. You typically override the ``KERNEL_FEATURES``
3854 variable for a specific machine. In this way, you can provide
3855 validated, but optional, sets of kernel configurations and features.
3856
3857 For example, the following example from the ``linux-yocto-rt_4.12``
3858 kernel recipe adds "netfilter" and "taskstats" features to all BSPs
3859 as well as "virtio" configurations to all QEMU machines. The last two
3860 statements add specific configurations to targeted machine types:
3861 ::
3862
3863 KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
3864 KERNEL_FEATURES_append = "${KERNEL_EXTRA_FEATURES}"
3865 KERNEL_FEATURES_append_qemuall = "cfg/virtio.scc"
3866 KERNEL_FEATURES_append_qemux86 = " cfg/sound.scc cfg/paravirt_kvm.scc"
3867 KERNEL_FEATURES_append_qemux86-64 = "cfg/sound.scc"
3868
Andrew Geisslerf0343792020-11-18 10:42:21 -06003869 :term:`KERNEL_FIT_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003870 The link name of the kernel flattened image tree (FIT) image. This
3871 variable is set in the ``meta/classes/kernel-artifact-names.bbclass``
3872 file as follows:
3873 ::
3874
3875 KERNEL_FIT_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
3876
3877 The value of the
3878 ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same
3879 file, has the following value:
3880 ::
3881
3882 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
3883
3884 See the :term:`MACHINE` variable for additional
3885 information.
3886
Andrew Geisslerf0343792020-11-18 10:42:21 -06003887 :term:`KERNEL_FIT_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003888 The base name of the kernel flattened image tree (FIT) image. This
3889 variable is set in the ``meta/classes/kernel-artifact-names.bbclass``
3890 file as follows:
3891 ::
3892
3893 KERNEL_FIT_NAME ?= "${KERNEL_ARTIFACT_NAME}"
3894
3895 The value of the :term:`KERNEL_ARTIFACT_NAME`
3896 variable, which is set in the same file, has the following value:
3897 ::
3898
3899 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
3900
Andrew Geisslerf0343792020-11-18 10:42:21 -06003901 :term:`KERNEL_IMAGE_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003902 The link name for the kernel image. This variable is set in the
3903 ``meta/classes/kernel-artifact-names.bbclass`` file as follows:
3904 ::
3905
3906 KERNEL_IMAGE_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
3907
3908 The value of
3909 the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same
3910 file, has the following value:
3911 ::
3912
3913 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
3914
3915 See the :term:`MACHINE` variable for additional
3916 information.
3917
Andrew Geisslerf0343792020-11-18 10:42:21 -06003918 :term:`KERNEL_IMAGE_MAXSIZE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003919 Specifies the maximum size of the kernel image file in kilobytes. If
3920 ``KERNEL_IMAGE_MAXSIZE`` is set, the size of the kernel image file is
3921 checked against the set value during the
3922 :ref:`ref-tasks-sizecheck` task. The task fails if
3923 the kernel image file is larger than the setting.
3924
3925 ``KERNEL_IMAGE_MAXSIZE`` is useful for target devices that have a
3926 limited amount of space in which the kernel image must be stored.
3927
3928 By default, this variable is not set, which means the size of the
3929 kernel image is not checked.
3930
Andrew Geisslerf0343792020-11-18 10:42:21 -06003931 :term:`KERNEL_IMAGE_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003932 The base name of the kernel image. This variable is set in the
3933 ``meta/classes/kernel-artifact-names.bbclass`` file as follows:
3934 ::
3935
3936 KERNEL_IMAGE_NAME ?= "${KERNEL_ARTIFACT_NAME}"
3937
3938 The value of the
3939 :term:`KERNEL_ARTIFACT_NAME` variable,
3940 which is set in the same file, has the following value:
3941 ::
3942
3943 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
3944
Andrew Geisslerf0343792020-11-18 10:42:21 -06003945 :term:`KERNEL_IMAGETYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003946 The type of kernel to build for a device, usually set by the machine
3947 configuration files and defaults to "zImage". This variable is used
3948 when building the kernel and is passed to ``make`` as the target to
3949 build.
3950
3951 If you want to build an alternate kernel image type, use the
3952 :term:`KERNEL_ALT_IMAGETYPE` variable.
3953
Andrew Geisslerf0343792020-11-18 10:42:21 -06003954 :term:`KERNEL_MODULE_AUTOLOAD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003955 Lists kernel modules that need to be auto-loaded during boot.
3956
3957 .. note::
3958
Andrew Geissler4c19ea12020-10-27 13:52:24 -05003959 This variable replaces the deprecated :term:`module_autoload`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003960 variable.
3961
3962 You can use the ``KERNEL_MODULE_AUTOLOAD`` variable anywhere that it
3963 can be recognized by the kernel recipe or by an out-of-tree kernel
3964 module recipe (e.g. a machine configuration file, a distribution
3965 configuration file, an append file for the recipe, or the recipe
3966 itself).
3967
3968 Specify it as follows:
3969 ::
3970
3971 KERNEL_MODULE_AUTOLOAD += "module_name1 module_name2 module_name3"
3972
3973 Including ``KERNEL_MODULE_AUTOLOAD`` causes the OpenEmbedded build
3974 system to populate the ``/etc/modules-load.d/modname.conf`` file with
3975 the list of modules to be auto-loaded on boot. The modules appear
3976 one-per-line in the file. Here is an example of the most common use
3977 case:
3978 ::
3979
3980 KERNEL_MODULE_AUTOLOAD += "module_name"
3981
3982 For information on how to populate the ``modname.conf`` file with
3983 ``modprobe.d`` syntax lines, see the :term:`KERNEL_MODULE_PROBECONF` variable.
3984
Andrew Geisslerf0343792020-11-18 10:42:21 -06003985 :term:`KERNEL_MODULE_PROBECONF`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003986 Provides a list of modules for which the OpenEmbedded build system
3987 expects to find ``module_conf_``\ modname values that specify
3988 configuration for each of the modules. For information on how to
3989 provide those module configurations, see the
3990 :term:`module_conf_* <module_conf>` variable.
3991
Andrew Geisslerf0343792020-11-18 10:42:21 -06003992 :term:`KERNEL_PATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05003993 The location of the kernel sources. This variable is set to the value
3994 of the :term:`STAGING_KERNEL_DIR` within
3995 the :ref:`module <ref-classes-module>` class. For information on
3996 how this variable is used, see the
3997 ":ref:`kernel-dev/kernel-dev-common:incorporating out-of-tree modules`"
3998 section in the Yocto Project Linux Kernel Development Manual.
3999
4000 To help maximize compatibility with out-of-tree drivers used to build
4001 modules, the OpenEmbedded build system also recognizes and uses the
4002 :term:`KERNEL_SRC` variable, which is identical to
4003 the ``KERNEL_PATH`` variable. Both variables are common variables
4004 used by external Makefiles to point to the kernel source directory.
4005
Andrew Geisslerf0343792020-11-18 10:42:21 -06004006 :term:`KERNEL_SRC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004007 The location of the kernel sources. This variable is set to the value
4008 of the :term:`STAGING_KERNEL_DIR` within
4009 the :ref:`module <ref-classes-module>` class. For information on
4010 how this variable is used, see the
4011 ":ref:`kernel-dev/kernel-dev-common:incorporating out-of-tree modules`"
4012 section in the Yocto Project Linux Kernel Development Manual.
4013
4014 To help maximize compatibility with out-of-tree drivers used to build
4015 modules, the OpenEmbedded build system also recognizes and uses the
4016 :term:`KERNEL_PATH` variable, which is identical
4017 to the ``KERNEL_SRC`` variable. Both variables are common variables
4018 used by external Makefiles to point to the kernel source directory.
4019
Andrew Geisslerf0343792020-11-18 10:42:21 -06004020 :term:`KERNEL_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004021 Specifies the version of the kernel as extracted from ``version.h``
4022 or ``utsrelease.h`` within the kernel sources. Effects of setting
4023 this variable do not take affect until the kernel has been
4024 configured. Consequently, attempting to refer to this variable in
4025 contexts prior to configuration will not work.
4026
Andrew Geisslerf0343792020-11-18 10:42:21 -06004027 :term:`KERNELDEPMODDEPEND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004028 Specifies whether the data referenced through
4029 :term:`PKGDATA_DIR` is needed or not. The
4030 ``KERNELDEPMODDEPEND`` does not control whether or not that data
4031 exists, but simply whether or not it is used. If you do not need to
4032 use the data, set the ``KERNELDEPMODDEPEND`` variable in your
4033 ``initramfs`` recipe. Setting the variable there when the data is not
4034 needed avoids a potential dependency loop.
4035
Andrew Geisslerf0343792020-11-18 10:42:21 -06004036 :term:`KFEATURE_DESCRIPTION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004037 Provides a short description of a configuration fragment. You use
4038 this variable in the ``.scc`` file that describes a configuration
4039 fragment file. Here is the variable used in a file named ``smp.scc``
4040 to describe SMP being enabled:
4041 ::
4042
4043 define KFEATURE_DESCRIPTION "Enable SMP"
4044
Andrew Geisslerf0343792020-11-18 10:42:21 -06004045 :term:`KMACHINE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004046 The machine as known by the kernel. Sometimes the machine name used
4047 by the kernel does not match the machine name used by the
4048 OpenEmbedded build system. For example, the machine name that the
4049 OpenEmbedded build system understands as ``core2-32-intel-common``
4050 goes by a different name in the Linux Yocto kernel. The kernel
4051 understands that machine as ``intel-core2-32``. For cases like these,
4052 the ``KMACHINE`` variable maps the kernel machine name to the
4053 OpenEmbedded build system machine name.
4054
4055 These mappings between different names occur in the Yocto Linux
4056 Kernel's ``meta`` branch. As an example take a look in the
4057 ``common/recipes-kernel/linux/linux-yocto_3.19.bbappend`` file:
4058 ::
4059
4060 LINUX_VERSION_core2-32-intel-common = "3.19.0"
4061 COMPATIBLE_MACHINE_core2-32-intel-common = "${MACHINE}"
4062 SRCREV_meta_core2-32-intel-common = "8897ef68b30e7426bc1d39895e71fb155d694974"
4063 SRCREV_machine_core2-32-intel-common = "43b9eced9ba8a57add36af07736344dcc383f711"
4064 KMACHINE_core2-32-intel-common = "intel-core2-32"
4065 KBRANCH_core2-32-intel-common = "standard/base"
4066 KERNEL_FEATURES_append_core2-32-intel-common = "${KERNEL_FEATURES_INTEL_COMMON}"
4067
4068 The ``KMACHINE`` statement says
4069 that the kernel understands the machine name as "intel-core2-32".
4070 However, the OpenEmbedded build system understands the machine as
4071 "core2-32-intel-common".
4072
Andrew Geisslerf0343792020-11-18 10:42:21 -06004073 :term:`KTYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004074 Defines the kernel type to be used in assembling the configuration.
4075 The linux-yocto recipes define "standard", "tiny", and "preempt-rt"
4076 kernel types. See the ":ref:`kernel-dev/kernel-dev-advanced:kernel types`"
4077 section in the
4078 Yocto Project Linux Kernel Development Manual for more information on
4079 kernel types.
4080
4081 You define the ``KTYPE`` variable in the
4082 :ref:`kernel-dev/kernel-dev-advanced:bsp descriptions`. The
4083 value you use must match the value used for the
4084 :term:`LINUX_KERNEL_TYPE` value used by the
4085 kernel recipe.
4086
Andrew Geisslerf0343792020-11-18 10:42:21 -06004087 :term:`LABELS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004088 Provides a list of targets for automatic configuration.
4089
4090 See the :ref:`grub-efi <ref-classes-grub-efi>` class for more
4091 information on how this variable is used.
4092
Andrew Geisslerf0343792020-11-18 10:42:21 -06004093 :term:`LAYERDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004094 Lists the layers, separated by spaces, on which this recipe depends.
4095 Optionally, you can specify a specific layer version for a dependency
4096 by adding it to the end of the layer name. Here is an example:
4097 ::
4098
4099 LAYERDEPENDS_mylayer = "anotherlayer (=3)"
4100
4101 In this previous example,
4102 version 3 of "anotherlayer" is compared against
4103 :term:`LAYERVERSION`\ ``_anotherlayer``.
4104
4105 An error is produced if any dependency is missing or the version
4106 numbers (if specified) do not match exactly. This variable is used in
4107 the ``conf/layer.conf`` file and must be suffixed with the name of
4108 the specific layer (e.g. ``LAYERDEPENDS_mylayer``).
4109
Andrew Geisslerf0343792020-11-18 10:42:21 -06004110 :term:`LAYERDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004111 When used inside the ``layer.conf`` configuration file, this variable
4112 provides the path of the current layer. This variable is not
4113 available outside of ``layer.conf`` and references are expanded
4114 immediately when parsing of the file completes.
4115
Andrew Geisslerf0343792020-11-18 10:42:21 -06004116 :term:`LAYERRECOMMENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004117 Lists the layers, separated by spaces, recommended for use with this
4118 layer.
4119
4120 Optionally, you can specify a specific layer version for a
4121 recommendation by adding the version to the end of the layer name.
4122 Here is an example:
4123 ::
4124
4125 LAYERRECOMMENDS_mylayer = "anotherlayer (=3)"
4126
4127 In this previous example, version 3 of "anotherlayer" is compared
4128 against ``LAYERVERSION_anotherlayer``.
4129
4130 This variable is used in the ``conf/layer.conf`` file and must be
4131 suffixed with the name of the specific layer (e.g.
4132 ``LAYERRECOMMENDS_mylayer``).
4133
Andrew Geisslerf0343792020-11-18 10:42:21 -06004134 :term:`LAYERSERIES_COMPAT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004135 Lists the versions of the :term:`OpenEmbedded-Core (OE-Core)` for which
4136 a layer is compatible. Using the ``LAYERSERIES_COMPAT`` variable
4137 allows the layer maintainer to indicate which combinations of the
4138 layer and OE-Core can be expected to work. The variable gives the
4139 system a way to detect when a layer has not been tested with new
4140 releases of OE-Core (e.g. the layer is not maintained).
4141
4142 To specify the OE-Core versions for which a layer is compatible, use
4143 this variable in your layer's ``conf/layer.conf`` configuration file.
4144 For the list, use the Yocto Project
4145 :yocto_wiki:`Release Name </wiki/Releases>` (e.g.
4146 DISTRO_NAME_NO_CAP). To specify multiple OE-Core versions for the
4147 layer, use a space-separated list:
4148 ::
4149
4150 LAYERSERIES_COMPAT_layer_root_name = "DISTRO_NAME_NO_CAP DISTRO_NAME_NO_CAP_MINUS_ONE"
4151
4152 .. note::
4153
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004154 Setting ``LAYERSERIES_COMPAT`` is required by the Yocto Project
4155 Compatible version 2 standard.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004156 The OpenEmbedded build system produces a warning if the variable
4157 is not set for any given layer.
4158
4159 See the ":ref:`dev-manual/dev-manual-common-tasks:creating your own layer`"
4160 section in the Yocto Project Development Tasks Manual.
4161
Andrew Geisslerf0343792020-11-18 10:42:21 -06004162 :term:`LAYERVERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004163 Optionally specifies the version of a layer as a single number. You
4164 can use this within :term:`LAYERDEPENDS` for
4165 another layer in order to depend on a specific version of the layer.
4166 This variable is used in the ``conf/layer.conf`` file and must be
4167 suffixed with the name of the specific layer (e.g.
4168 ``LAYERVERSION_mylayer``).
4169
Andrew Geisslerf0343792020-11-18 10:42:21 -06004170 :term:`LD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004171 The minimal command and arguments used to run the linker.
4172
Andrew Geisslerf0343792020-11-18 10:42:21 -06004173 :term:`LDFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004174 Specifies the flags to pass to the linker. This variable is exported
4175 to an environment variable and thus made visible to the software
4176 being built during the compilation step.
4177
4178 Default initialization for ``LDFLAGS`` varies depending on what is
4179 being built:
4180
4181 - :term:`TARGET_LDFLAGS` when building for the
4182 target
4183
4184 - :term:`BUILD_LDFLAGS` when building for the
4185 build host (i.e. ``-native``)
4186
4187 - :term:`BUILDSDK_LDFLAGS` when building for
4188 an SDK (i.e. ``nativesdk-``)
4189
Andrew Geisslerf0343792020-11-18 10:42:21 -06004190 :term:`LEAD_SONAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004191 Specifies the lead (or primary) compiled library file (i.e. ``.so``)
4192 that the :ref:`debian <ref-classes-debian>` class applies its
4193 naming policy to given a recipe that packages multiple libraries.
4194
4195 This variable works in conjunction with the ``debian`` class.
4196
Andrew Geisslerf0343792020-11-18 10:42:21 -06004197 :term:`LIC_FILES_CHKSUM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004198 Checksums of the license text in the recipe source code.
4199
4200 This variable tracks changes in license text of the source code
4201 files. If the license text is changed, it will trigger a build
4202 failure, which gives the developer an opportunity to review any
4203 license change.
4204
4205 This variable must be defined for all recipes (unless
4206 :term:`LICENSE` is set to "CLOSED").
4207
4208 For more information, see the ":ref:`usingpoky-configuring-lic_files_chksum`"
4209 section in the Yocto Project Development Tasks Manual.
4210
Andrew Geisslerf0343792020-11-18 10:42:21 -06004211 :term:`LICENSE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004212 The list of source licenses for the recipe. Follow these rules:
4213
4214 - Do not use spaces within individual license names.
4215
4216 - Separate license names using \| (pipe) when there is a choice
4217 between licenses.
4218
4219 - Separate license names using & (ampersand) when multiple licenses
4220 exist that cover different parts of the source.
4221
4222 - You can use spaces between license names.
4223
4224 - For standard licenses, use the names of the files in
4225 ``meta/files/common-licenses/`` or the
4226 :term:`SPDXLICENSEMAP` flag names defined in
4227 ``meta/conf/licenses.conf``.
4228
4229 Here are some examples:
4230 ::
4231
4232 LICENSE = "LGPLv2.1 | GPLv3"
4233 LICENSE = "MPL-1 & LGPLv2.1"
4234 LICENSE = "GPLv2+"
4235
4236 The first example is from the
4237 recipes for Qt, which the user may choose to distribute under either
4238 the LGPL version 2.1 or GPL version 3. The second example is from
4239 Cairo where two licenses cover different parts of the source code.
4240 The final example is from ``sysstat``, which presents a single
4241 license.
4242
4243 You can also specify licenses on a per-package basis to handle
4244 situations where components of the output have different licenses.
4245 For example, a piece of software whose code is licensed under GPLv2
4246 but has accompanying documentation licensed under the GNU Free
4247 Documentation License 1.2 could be specified as follows:
4248 ::
4249
4250 LICENSE = "GFDL-1.2 & GPLv2"
4251 LICENSE_${PN} = "GPLv2"
4252 LICENSE_${PN}-doc = "GFDL-1.2"
4253
Andrew Geisslerf0343792020-11-18 10:42:21 -06004254 :term:`LICENSE_CREATE_PACKAGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004255 Setting ``LICENSE_CREATE_PACKAGE`` to "1" causes the OpenEmbedded
4256 build system to create an extra package (i.e.
4257 ``${``\ :term:`PN`\ ``}-lic``) for each recipe and to add
4258 those packages to the
4259 :term:`RRECOMMENDS`\ ``_${PN}``.
4260
4261 The ``${PN}-lic`` package installs a directory in
4262 ``/usr/share/licenses`` named ``${PN}``, which is the recipe's base
4263 name, and installs files in that directory that contain license and
4264 copyright information (i.e. copies of the appropriate license files
4265 from ``meta/common-licenses`` that match the licenses specified in
4266 the :term:`LICENSE` variable of the recipe metadata
4267 and copies of files marked in
4268 :term:`LIC_FILES_CHKSUM` as containing
4269 license text).
4270
4271 For related information on providing license text, see the
4272 :term:`COPY_LIC_DIRS` variable, the
4273 :term:`COPY_LIC_MANIFEST` variable, and the
4274 ":ref:`dev-manual/dev-manual-common-tasks:providing license text`"
4275 section in the Yocto Project Development Tasks Manual.
4276
Andrew Geisslerf0343792020-11-18 10:42:21 -06004277 :term:`LICENSE_FLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004278 Specifies additional flags for a recipe you must whitelist through
4279 :term:`LICENSE_FLAGS_WHITELIST` in
4280 order to allow the recipe to be built. When providing multiple flags,
4281 separate them with spaces.
4282
4283 This value is independent of :term:`LICENSE` and is
4284 typically used to mark recipes that might require additional licenses
4285 in order to be used in a commercial product. For more information,
4286 see the
4287 ":ref:`dev-manual/dev-manual-common-tasks:enabling commercially licensed recipes`"
4288 section in the Yocto Project Development Tasks Manual.
4289
Andrew Geisslerf0343792020-11-18 10:42:21 -06004290 :term:`LICENSE_FLAGS_WHITELIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004291 Lists license flags that when specified in
4292 :term:`LICENSE_FLAGS` within a recipe should not
4293 prevent that recipe from being built. This practice is otherwise
4294 known as "whitelisting" license flags. For more information, see the
4295 ":ref:`dev-manual/dev-manual-common-tasks:enabling commercially licensed recipes`"
4296 section in the Yocto Project Development Tasks Manual.
4297
Andrew Geisslerf0343792020-11-18 10:42:21 -06004298 :term:`LICENSE_PATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004299 Path to additional licenses used during the build. By default, the
4300 OpenEmbedded build system uses ``COMMON_LICENSE_DIR`` to define the
4301 directory that holds common license text used during the build. The
4302 ``LICENSE_PATH`` variable allows you to extend that location to other
4303 areas that have additional licenses:
4304 ::
4305
4306 LICENSE_PATH += "path-to-additional-common-licenses"
4307
Andrew Geisslerf0343792020-11-18 10:42:21 -06004308 :term:`LINUX_KERNEL_TYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004309 Defines the kernel type to be used in assembling the configuration.
4310 The linux-yocto recipes define "standard", "tiny", and "preempt-rt"
4311 kernel types. See the ":ref:`kernel-dev/kernel-dev-advanced:kernel types`"
4312 section in the
4313 Yocto Project Linux Kernel Development Manual for more information on
4314 kernel types.
4315
4316 If you do not specify a ``LINUX_KERNEL_TYPE``, it defaults to
4317 "standard". Together with :term:`KMACHINE`, the
4318 ``LINUX_KERNEL_TYPE`` variable defines the search arguments used by
4319 the kernel tools to find the appropriate description within the
4320 kernel :term:`Metadata` with which to build out the sources
4321 and configuration.
4322
Andrew Geisslerf0343792020-11-18 10:42:21 -06004323 :term:`LINUX_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004324 The Linux version from ``kernel.org`` on which the Linux kernel image
4325 being built using the OpenEmbedded build system is based. You define
4326 this variable in the kernel recipe. For example, the
4327 ``linux-yocto-3.4.bb`` kernel recipe found in
4328 ``meta/recipes-kernel/linux`` defines the variables as follows:
4329 ::
4330
4331 LINUX_VERSION ?= "3.4.24"
4332
4333 The ``LINUX_VERSION`` variable is used to define :term:`PV`
4334 for the recipe:
4335 ::
4336
4337 PV = "${LINUX_VERSION}+git${SRCPV}"
4338
Andrew Geisslerf0343792020-11-18 10:42:21 -06004339 :term:`LINUX_VERSION_EXTENSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004340 A string extension compiled into the version string of the Linux
4341 kernel built with the OpenEmbedded build system. You define this
4342 variable in the kernel recipe. For example, the linux-yocto kernel
4343 recipes all define the variable as follows:
4344 ::
4345
4346 LINUX_VERSION_EXTENSION ?= "-yocto-${LINUX_KERNEL_TYPE}"
4347
4348 Defining this variable essentially sets the Linux kernel
4349 configuration item ``CONFIG_LOCALVERSION``, which is visible through
4350 the ``uname`` command. Here is an example that shows the extension
4351 assuming it was set as previously shown:
4352 ::
4353
4354 $ uname -r
4355 3.7.0-rc8-custom
4356
Andrew Geisslerf0343792020-11-18 10:42:21 -06004357 :term:`LOG_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004358 Specifies the directory to which the OpenEmbedded build system writes
4359 overall log files. The default directory is ``${TMPDIR}/log``.
4360
4361 For the directory containing logs specific to each task, see the
4362 :term:`T` variable.
4363
Andrew Geisslerf0343792020-11-18 10:42:21 -06004364 :term:`MACHINE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004365 Specifies the target device for which the image is built. You define
4366 ``MACHINE`` in the ``local.conf`` file found in the
4367 :term:`Build Directory`. By default, ``MACHINE`` is set to
4368 "qemux86", which is an x86-based architecture machine to be emulated
4369 using QEMU:
4370 ::
4371
4372 MACHINE ?= "qemux86"
4373
4374 The variable corresponds to a machine configuration file of the same
4375 name, through which machine-specific configurations are set. Thus,
4376 when ``MACHINE`` is set to "qemux86" there exists the corresponding
4377 ``qemux86.conf`` machine configuration file, which can be found in
4378 the :term:`Source Directory` in
4379 ``meta/conf/machine``.
4380
4381 The list of machines supported by the Yocto Project as shipped
4382 include the following:
4383 ::
4384
4385 MACHINE ?= "qemuarm"
4386 MACHINE ?= "qemuarm64"
4387 MACHINE ?= "qemumips"
4388 MACHINE ?= "qemumips64"
4389 MACHINE ?= "qemuppc"
4390 MACHINE ?= "qemux86"
4391 MACHINE ?= "qemux86-64"
4392 MACHINE ?= "genericx86"
4393 MACHINE ?= "genericx86-64"
4394 MACHINE ?= "beaglebone"
4395 MACHINE ?= "edgerouter"
4396
4397 The last five are Yocto Project reference hardware
4398 boards, which are provided in the ``meta-yocto-bsp`` layer.
4399
4400 .. note::
4401
4402 Adding additional Board Support Package (BSP) layers to your
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004403 configuration adds new possible settings for ``MACHINE``.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004404
Andrew Geisslerf0343792020-11-18 10:42:21 -06004405 :term:`MACHINE_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004406 Specifies the name of the machine-specific architecture. This
4407 variable is set automatically from :term:`MACHINE` or
4408 :term:`TUNE_PKGARCH`. You should not hand-edit
4409 the ``MACHINE_ARCH`` variable.
4410
Andrew Geisslerf0343792020-11-18 10:42:21 -06004411 :term:`MACHINE_ESSENTIAL_EXTRA_RDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004412 A list of required machine-specific packages to install as part of
4413 the image being built. The build process depends on these packages
4414 being present. Furthermore, because this is a "machine-essential"
4415 variable, the list of packages are essential for the machine to boot.
4416 The impact of this variable affects images based on
4417 ``packagegroup-core-boot``, including the ``core-image-minimal``
4418 image.
4419
4420 This variable is similar to the
4421 ``MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS`` variable with the exception
4422 that the image being built has a build dependency on the variable's
4423 list of packages. In other words, the image will not build if a file
4424 in this list is not found.
4425
4426 As an example, suppose the machine for which you are building
4427 requires ``example-init`` to be run during boot to initialize the
4428 hardware. In this case, you would use the following in the machine's
4429 ``.conf`` configuration file:
4430 ::
4431
4432 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "example-init"
4433
Andrew Geisslerf0343792020-11-18 10:42:21 -06004434 :term:`MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004435 A list of recommended machine-specific packages to install as part of
4436 the image being built. The build process does not depend on these
4437 packages being present. However, because this is a
4438 "machine-essential" variable, the list of packages are essential for
4439 the machine to boot. The impact of this variable affects images based
4440 on ``packagegroup-core-boot``, including the ``core-image-minimal``
4441 image.
4442
4443 This variable is similar to the ``MACHINE_ESSENTIAL_EXTRA_RDEPENDS``
4444 variable with the exception that the image being built does not have
4445 a build dependency on the variable's list of packages. In other
4446 words, the image will still build if a package in this list is not
4447 found. Typically, this variable is used to handle essential kernel
4448 modules, whose functionality may be selected to be built into the
4449 kernel rather than as a module, in which case a package will not be
4450 produced.
4451
4452 Consider an example where you have a custom kernel where a specific
4453 touchscreen driver is required for the machine to be usable. However,
4454 the driver can be built as a module or into the kernel depending on
4455 the kernel configuration. If the driver is built as a module, you
4456 want it to be installed. But, when the driver is built into the
4457 kernel, you still want the build to succeed. This variable sets up a
4458 "recommends" relationship so that in the latter case, the build will
4459 not fail due to the missing package. To accomplish this, assuming the
4460 package for the module was called ``kernel-module-ab123``, you would
4461 use the following in the machine's ``.conf`` configuration file:
4462 ::
4463
4464 MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "kernel-module-ab123"
4465
4466 .. note::
4467
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004468 In this example, the ``kernel-module-ab123`` recipe needs to
4469 explicitly set its :term:`PACKAGES` variable to ensure that BitBake
4470 does not use the kernel recipe's :term:`PACKAGES_DYNAMIC` variable to
4471 satisfy the dependency.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004472
4473 Some examples of these machine essentials are flash, screen,
4474 keyboard, mouse, or touchscreen drivers (depending on the machine).
4475
Andrew Geisslerf0343792020-11-18 10:42:21 -06004476 :term:`MACHINE_EXTRA_RDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004477 A list of machine-specific packages to install as part of the image
4478 being built that are not essential for the machine to boot. However,
4479 the build process for more fully-featured images depends on the
4480 packages being present.
4481
4482 This variable affects all images based on ``packagegroup-base``,
4483 which does not include the ``core-image-minimal`` or
4484 ``core-image-full-cmdline`` images.
4485
4486 The variable is similar to the ``MACHINE_EXTRA_RRECOMMENDS`` variable
4487 with the exception that the image being built has a build dependency
4488 on the variable's list of packages. In other words, the image will
4489 not build if a file in this list is not found.
4490
4491 An example is a machine that has WiFi capability but is not essential
4492 for the machine to boot the image. However, if you are building a
4493 more fully-featured image, you want to enable the WiFi. The package
4494 containing the firmware for the WiFi hardware is always expected to
4495 exist, so it is acceptable for the build process to depend upon
4496 finding the package. In this case, assuming the package for the
4497 firmware was called ``wifidriver-firmware``, you would use the
4498 following in the ``.conf`` file for the machine:
4499 ::
4500
4501 MACHINE_EXTRA_RDEPENDS += "wifidriver-firmware"
4502
Andrew Geisslerf0343792020-11-18 10:42:21 -06004503 :term:`MACHINE_EXTRA_RRECOMMENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004504 A list of machine-specific packages to install as part of the image
4505 being built that are not essential for booting the machine. The image
4506 being built has no build dependency on this list of packages.
4507
4508 This variable affects only images based on ``packagegroup-base``,
4509 which does not include the ``core-image-minimal`` or
4510 ``core-image-full-cmdline`` images.
4511
4512 This variable is similar to the ``MACHINE_EXTRA_RDEPENDS`` variable
4513 with the exception that the image being built does not have a build
4514 dependency on the variable's list of packages. In other words, the
4515 image will build if a file in this list is not found.
4516
4517 An example is a machine that has WiFi capability but is not essential
4518 For the machine to boot the image. However, if you are building a
4519 more fully-featured image, you want to enable WiFi. In this case, the
4520 package containing the WiFi kernel module will not be produced if the
4521 WiFi driver is built into the kernel, in which case you still want
4522 the build to succeed instead of failing as a result of the package
4523 not being found. To accomplish this, assuming the package for the
4524 module was called ``kernel-module-examplewifi``, you would use the
4525 following in the ``.conf`` file for the machine:
4526 ::
4527
4528 MACHINE_EXTRA_RRECOMMENDS += "kernel-module-examplewifi"
4529
Andrew Geisslerf0343792020-11-18 10:42:21 -06004530 :term:`MACHINE_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004531 Specifies the list of hardware features the
4532 :term:`MACHINE` is capable of supporting. For related
4533 information on enabling features, see the
4534 :term:`DISTRO_FEATURES`,
4535 :term:`COMBINED_FEATURES`, and
4536 :term:`IMAGE_FEATURES` variables.
4537
4538 For a list of hardware features supported by the Yocto Project as
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004539 shipped, see the ":ref:`ref-features-machine`" section.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004540
Andrew Geisslerf0343792020-11-18 10:42:21 -06004541 :term:`MACHINE_FEATURES_BACKFILL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004542 Features to be added to ``MACHINE_FEATURES`` if not also present in
4543 ``MACHINE_FEATURES_BACKFILL_CONSIDERED``.
4544
4545 This variable is set in the ``meta/conf/bitbake.conf`` file. It is
4546 not intended to be user-configurable. It is best to just reference
4547 the variable to see which machine features are being backfilled for
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004548 all machine configurations. See the ":ref:`ref-features-backfill`"
4549 section for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004550
Andrew Geisslerf0343792020-11-18 10:42:21 -06004551 :term:`MACHINE_FEATURES_BACKFILL_CONSIDERED`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004552 Features from ``MACHINE_FEATURES_BACKFILL`` that should not be
4553 backfilled (i.e. added to ``MACHINE_FEATURES``) during the build. See
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004554 the ":ref:`ref-features-backfill`" section for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004555
Andrew Geisslerf0343792020-11-18 10:42:21 -06004556 :term:`MACHINEOVERRIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004557 A colon-separated list of overrides that apply to the current
4558 machine. By default, this list includes the value of
4559 :term:`MACHINE`.
4560
4561 You can extend ``MACHINEOVERRIDES`` to add extra overrides that
4562 should apply to a machine. For example, all machines emulated in QEMU
4563 (e.g. ``qemuarm``, ``qemux86``, and so forth) include a file named
4564 ``meta/conf/machine/include/qemu.inc`` that prepends the following
4565 override to ``MACHINEOVERRIDES``:
4566 ::
4567
4568 MACHINEOVERRIDES =. "qemuall:"
4569
4570 This
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004571 override allows variables to be overridden for all machines emulated
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004572 in QEMU, like in the following example from the ``connman-conf``
4573 recipe:
4574 ::
4575
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004576 SRC_URI_append_qemuall = " file://wired.config \
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004577 file://wired-setup \
4578 "
4579
4580 The underlying mechanism behind
4581 ``MACHINEOVERRIDES`` is simply that it is included in the default
4582 value of :term:`OVERRIDES`.
4583
Andrew Geisslerf0343792020-11-18 10:42:21 -06004584 :term:`MAINTAINER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004585 The email address of the distribution maintainer.
4586
Andrew Geisslerf0343792020-11-18 10:42:21 -06004587 :term:`MIRRORS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004588 Specifies additional paths from which the OpenEmbedded build system
4589 gets source code. When the build system searches for source code, it
4590 first tries the local download directory. If that location fails, the
4591 build system tries locations defined by
4592 :term:`PREMIRRORS`, the upstream source, and then
4593 locations specified by ``MIRRORS`` in that order.
4594
4595 Assuming your distribution (:term:`DISTRO`) is "poky",
4596 the default value for ``MIRRORS`` is defined in the
4597 ``conf/distro/poky.conf`` file in the ``meta-poky`` Git repository.
4598
Andrew Geisslerf0343792020-11-18 10:42:21 -06004599 :term:`MLPREFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004600 Specifies a prefix has been added to :term:`PN` to create a
4601 special version of a recipe or package (i.e. a Multilib version). The
4602 variable is used in places where the prefix needs to be added to or
4603 removed from a the name (e.g. the :term:`BPN` variable).
4604 ``MLPREFIX`` gets set when a prefix has been added to ``PN``.
4605
4606 .. note::
4607
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004608 The "ML" in ``MLPREFIX`` stands for "MultiLib". This representation is
4609 historical and comes from a time when ``nativesdk`` was a suffix
4610 rather than a prefix on the recipe name. When ``nativesdk`` was turned
4611 into a prefix, it made sense to set ``MLPREFIX`` for it as well.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004612
4613 To help understand when ``MLPREFIX`` might be needed, consider when
4614 :term:`BBCLASSEXTEND` is used to provide a
4615 ``nativesdk`` version of a recipe in addition to the target version.
4616 If that recipe declares build-time dependencies on tasks in other
4617 recipes by using :term:`DEPENDS`, then a dependency on
4618 "foo" will automatically get rewritten to a dependency on
4619 "nativesdk-foo". However, dependencies like the following will not
4620 get rewritten automatically:
4621 ::
4622
4623 do_foo[depends] += "recipe:do_foo"
4624
4625 If you want such a dependency to also get transformed, you can do the
4626 following:
4627 ::
4628
4629 do_foo[depends] += "${MLPREFIX}recipe:do_foo"
4630
4631 module_autoload
4632 This variable has been replaced by the ``KERNEL_MODULE_AUTOLOAD``
4633 variable. You should replace all occurrences of ``module_autoload``
4634 with additions to ``KERNEL_MODULE_AUTOLOAD``, for example:
4635 ::
4636
4637 module_autoload_rfcomm = "rfcomm"
4638
4639 should now be replaced with:
4640 ::
4641
4642 KERNEL_MODULE_AUTOLOAD += "rfcomm"
4643
4644 See the :term:`KERNEL_MODULE_AUTOLOAD` variable for more information.
4645
4646 module_conf
4647 Specifies `modprobe.d <http://linux.die.net/man/5/modprobe.d>`_
4648 syntax lines for inclusion in the ``/etc/modprobe.d/modname.conf``
4649 file.
4650
4651 You can use this variable anywhere that it can be recognized by the
4652 kernel recipe or out-of-tree kernel module recipe (e.g. a machine
4653 configuration file, a distribution configuration file, an append file
4654 for the recipe, or the recipe itself). If you use this variable, you
4655 must also be sure to list the module name in the
4656 :term:`KERNEL_MODULE_AUTOLOAD`
4657 variable.
4658
4659 Here is the general syntax:
4660 ::
4661
4662 module_conf_module_name = "modprobe.d-syntax"
4663
4664 You must use the kernel module name override.
4665
4666 Run ``man modprobe.d`` in the shell to find out more information on
4667 the exact syntax you want to provide with ``module_conf``.
4668
4669 Including ``module_conf`` causes the OpenEmbedded build system to
4670 populate the ``/etc/modprobe.d/modname.conf`` file with
4671 ``modprobe.d`` syntax lines. Here is an example that adds the options
4672 ``arg1`` and ``arg2`` to a module named ``mymodule``:
4673 ::
4674
4675 module_conf_mymodule = "options mymodule arg1=val1 arg2=val2"
4676
4677 For information on how to specify kernel modules to auto-load on
4678 boot, see the :term:`KERNEL_MODULE_AUTOLOAD` variable.
4679
Andrew Geisslerf0343792020-11-18 10:42:21 -06004680 :term:`MODULE_TARBALL_DEPLOY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004681 Controls creation of the ``modules-*.tgz`` file. Set this variable to
4682 "0" to disable creation of this file, which contains all of the
4683 kernel modules resulting from a kernel build.
4684
Andrew Geisslerf0343792020-11-18 10:42:21 -06004685 :term:`MODULE_TARBALL_LINK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004686 The link name of the kernel module tarball. This variable is set in
4687 the ``meta/classes/kernel-artifact-names.bbclass`` file as follows:
4688 ::
4689
4690 MODULE_TARBALL_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}"
4691
4692 The value
4693 of the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the
4694 same file, has the following value:
4695 ::
4696
4697 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}"
4698
4699 See the :term:`MACHINE` variable for additional information.
4700
Andrew Geisslerf0343792020-11-18 10:42:21 -06004701 :term:`MODULE_TARBALL_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004702 The base name of the kernel module tarball. This variable is set in
4703 the ``meta/classes/kernel-artifact-names.bbclass`` file as follows:
4704 ::
4705
4706 MODULE_TARBALL_NAME ?= "${KERNEL_ARTIFACT_NAME}"
4707
4708 The value of the :term:`KERNEL_ARTIFACT_NAME` variable,
4709 which is set in the same file, has the following value:
4710 ::
4711
4712 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}${IMAGE_VERSION_SUFFIX}"
4713
Andrew Geisslerf0343792020-11-18 10:42:21 -06004714 :term:`MULTIMACH_TARGET_SYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004715 Uniquely identifies the type of the target system for which packages
4716 are being built. This variable allows output for different types of
4717 target systems to be put into different subdirectories of the same
4718 output directory.
4719
4720 The default value of this variable is:
4721 ::
4722
4723 ${PACKAGE_ARCH}${TARGET_VENDOR}-${TARGET_OS}
4724
4725 Some classes (e.g.
4726 :ref:`cross-canadian <ref-classes-cross-canadian>`) modify the
4727 ``MULTIMACH_TARGET_SYS`` value.
4728
4729 See the :term:`STAMP` variable for an example. See the
4730 :term:`STAGING_DIR_TARGET` variable for more information.
4731
Andrew Geisslerf0343792020-11-18 10:42:21 -06004732 :term:`NATIVELSBSTRING`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004733 A string identifying the host distribution. Strings consist of the
4734 host distributor ID followed by the release, as reported by the
4735 ``lsb_release`` tool or as read from ``/etc/lsb-release``. For
4736 example, when running a build on Ubuntu 12.10, the value is
4737 "Ubuntu-12.10". If this information is unable to be determined, the
4738 value resolves to "Unknown".
4739
4740 This variable is used by default to isolate native shared state
4741 packages for different distributions (e.g. to avoid problems with
4742 ``glibc`` version incompatibilities). Additionally, the variable is
4743 checked against
4744 :term:`SANITY_TESTED_DISTROS` if that
4745 variable is set.
4746
Andrew Geisslerf0343792020-11-18 10:42:21 -06004747 :term:`NM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004748 The minimal command and arguments to run ``nm``.
4749
Andrew Geisslerf0343792020-11-18 10:42:21 -06004750 :term:`NO_GENERIC_LICENSE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004751 Avoids QA errors when you use a non-common, non-CLOSED license in a
4752 recipe. Packages exist, such as the linux-firmware package, with many
4753 licenses that are not in any way common. Also, new licenses are added
4754 occasionally to avoid introducing a lot of common license files,
4755 which are only applicable to a specific package.
4756 ``NO_GENERIC_LICENSE`` is used to allow copying a license that does
4757 not exist in common licenses.
4758
4759 The following example shows how to add ``NO_GENERIC_LICENSE`` to a
4760 recipe:
4761 ::
4762
4763 NO_GENERIC_LICENSE[license_name] = "license_file_in_fetched_source"
4764
4765 The following is an example that
4766 uses the ``LICENSE.Abilis.txt`` file as the license from the fetched
4767 source:
4768 ::
4769
4770 NO_GENERIC_LICENSE[Firmware-Abilis] = "LICENSE.Abilis.txt"
4771
Andrew Geisslerf0343792020-11-18 10:42:21 -06004772 :term:`NO_RECOMMENDATIONS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004773 Prevents installation of all "recommended-only" packages.
4774 Recommended-only packages are packages installed only through the
4775 :term:`RRECOMMENDS` variable). Setting the
4776 ``NO_RECOMMENDATIONS`` variable to "1" turns this feature on: ::
4777
4778 NO_RECOMMENDATIONS = "1"
4779
4780 You can set this variable globally in your ``local.conf`` file or you
4781 can attach it to a specific image recipe by using the recipe name
4782 override: ::
4783
4784 NO_RECOMMENDATIONS_pn-target_image = "1"
4785
4786 It is important to realize that if you choose to not install packages
4787 using this variable and some other packages are dependent on them
4788 (i.e. listed in a recipe's :term:`RDEPENDS`
4789 variable), the OpenEmbedded build system ignores your request and
4790 will install the packages to avoid dependency errors.
4791
4792 .. note::
4793
4794 Some recommended packages might be required for certain system
4795 functionality, such as kernel modules. It is up to you to add
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004796 packages with the :term:`IMAGE_INSTALL` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004797
4798 Support for this variable exists only when using the IPK and RPM
4799 packaging backend. Support does not exist for DEB.
4800
4801 See the :term:`BAD_RECOMMENDATIONS` and
4802 the :term:`PACKAGE_EXCLUDE` variables for
4803 related information.
4804
Andrew Geisslerf0343792020-11-18 10:42:21 -06004805 :term:`NOAUTOPACKAGEDEBUG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004806 Disables auto package from splitting ``.debug`` files. If a recipe
4807 requires ``FILES_${PN}-dbg`` to be set manually, the
4808 ``NOAUTOPACKAGEDEBUG`` can be defined allowing you to define the
4809 content of the debug package. For example:
4810 ::
4811
4812 NOAUTOPACKAGEDEBUG = "1"
4813 FILES_${PN}-dev = "${includedir}/${QT_DIR_NAME}/Qt/*"
4814 FILES_${PN}-dbg = "/usr/src/debug/"
4815 FILES_${QT_BASE_NAME}-demos-doc = "${docdir}/${QT_DIR_NAME}/qch/qt.qch"
4816
Andrew Geisslerf0343792020-11-18 10:42:21 -06004817 :term:`OBJCOPY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004818 The minimal command and arguments to run ``objcopy``.
4819
Andrew Geisslerf0343792020-11-18 10:42:21 -06004820 :term:`OBJDUMP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004821 The minimal command and arguments to run ``objdump``.
4822
Andrew Geisslerf0343792020-11-18 10:42:21 -06004823 :term:`OE_BINCONFIG_EXTRA_MANGLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004824 When inheriting the :ref:`binconfig <ref-classes-binconfig>` class,
4825 this variable specifies additional arguments passed to the "sed"
4826 command. The sed command alters any paths in configuration scripts
4827 that have been set up during compilation. Inheriting this class
4828 results in all paths in these scripts being changed to point into the
4829 ``sysroots/`` directory so that all builds that use the script will
4830 use the correct directories for the cross compiling layout.
4831
4832 See the ``meta/classes/binconfig.bbclass`` in the
4833 :term:`Source Directory` for details on how this class
4834 applies these additional sed command arguments. For general
4835 information on the ``binconfig`` class, see the
4836 ":ref:`binconfig.bbclass <ref-classes-binconfig>`" section.
4837
Andrew Geisslerf0343792020-11-18 10:42:21 -06004838 :term:`OE_IMPORTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004839 An internal variable used to tell the OpenEmbedded build system what
4840 Python modules to import for every Python function run by the system.
4841
4842 .. note::
4843
4844 Do not set this variable. It is for internal use only.
4845
Andrew Geisslerf0343792020-11-18 10:42:21 -06004846 :term:`OE_INIT_ENV_SCRIPT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004847 The name of the build environment setup script for the purposes of
4848 setting up the environment within the extensible SDK. The default
4849 value is "oe-init-build-env".
4850
4851 If you use a custom script to set up your build environment, set the
4852 ``OE_INIT_ENV_SCRIPT`` variable to its name.
4853
Andrew Geisslerf0343792020-11-18 10:42:21 -06004854 :term:`OE_TERMINAL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004855 Controls how the OpenEmbedded build system spawns interactive
4856 terminals on the host development system (e.g. using the BitBake
4857 command with the ``-c devshell`` command-line option). For more
4858 information, see the ":ref:`platdev-appdev-devshell`" section in
4859 the Yocto Project Development Tasks Manual.
4860
4861 You can use the following values for the ``OE_TERMINAL`` variable:
4862
4863 - auto
4864 - gnome
4865 - xfce
4866 - rxvt
4867 - screen
4868 - konsole
4869 - none
4870
Andrew Geisslerf0343792020-11-18 10:42:21 -06004871 :term:`OEROOT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004872 The directory from which the top-level build environment setup script
4873 is sourced. The Yocto Project provides a top-level build environment
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004874 setup script: :ref:`structure-core-script`. When you run this
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004875 script, the ``OEROOT`` variable resolves to the directory that
4876 contains the script.
4877
4878 For additional information on how this variable is used, see the
4879 initialization script.
4880
Andrew Geisslerf0343792020-11-18 10:42:21 -06004881 :term:`OLDEST_KERNEL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004882 Declares the oldest version of the Linux kernel that the produced
4883 binaries must support. This variable is passed into the build of the
4884 Embedded GNU C Library (``glibc``).
4885
4886 The default for this variable comes from the
4887 ``meta/conf/bitbake.conf`` configuration file. You can override this
4888 default by setting the variable in a custom distribution
4889 configuration file.
4890
Andrew Geisslerf0343792020-11-18 10:42:21 -06004891 :term:`OVERRIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004892 A colon-separated list of overrides that currently apply. Overrides
4893 are a BitBake mechanism that allows variables to be selectively
4894 overridden at the end of parsing. The set of overrides in
4895 ``OVERRIDES`` represents the "state" during building, which includes
4896 the current recipe being built, the machine for which it is being
4897 built, and so forth.
4898
4899 As an example, if the string "an-override" appears as an element in
4900 the colon-separated list in ``OVERRIDES``, then the following
4901 assignment will override ``FOO`` with the value "overridden" at the
4902 end of parsing:
4903 ::
4904
4905 FOO_an-override = "overridden"
4906
4907 See the
4908 ":ref:`bitbake:bitbake-user-manual/bitbake-user-manual-metadata:conditional syntax (overrides)`"
4909 section in the BitBake User Manual for more information on the
4910 overrides mechanism.
4911
4912 The default value of ``OVERRIDES`` includes the values of the
4913 :term:`CLASSOVERRIDE`,
4914 :term:`MACHINEOVERRIDES`, and
4915 :term:`DISTROOVERRIDES` variables. Another
4916 important override included by default is ``pn-${PN}``. This override
4917 allows variables to be set for a single recipe within configuration
4918 (``.conf``) files. Here is an example:
4919 ::
4920
4921 FOO_pn-myrecipe = "myrecipe-specific value"
4922
4923 .. note::
4924
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004925 An easy way to see what overrides apply is to search for ``OVERRIDES``
4926 in the output of the ``bitbake -e`` command. See the
4927 ":ref:`dev-debugging-viewing-variable-values`" section in the Yocto
4928 Project Development Tasks Manual for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004929
Andrew Geisslerf0343792020-11-18 10:42:21 -06004930 :term:`P`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004931 The recipe name and version. ``P`` is comprised of the following:
4932 ::
4933
4934 ${PN}-${PV}
4935
Andrew Geisslerf0343792020-11-18 10:42:21 -06004936 :term:`PACKAGE_ADD_METADATA`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004937 This variable defines additional metdata to add to packages.
4938
4939 You may find you need to inject additional metadata into packages.
4940 This variable allows you to do that by setting the injected data as
4941 the value. Multiple fields can be added by splitting the content with
4942 the literal separator "\n".
4943
4944 The suffixes '_IPK', '_DEB', or '_RPM' can be applied to the variable
4945 to do package type specific settings. It can also be made package
4946 specific by using the package name as a suffix.
4947
4948 You can find out more about applying this variable in the
4949 ":ref:`dev-manual/dev-manual-common-tasks:adding custom metadata to packages`"
4950 section in the Yocto Project Development Tasks Manual.
4951
Andrew Geisslerf0343792020-11-18 10:42:21 -06004952 :term:`PACKAGE_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004953 The architecture of the resulting package or packages.
4954
4955 By default, the value of this variable is set to
4956 :term:`TUNE_PKGARCH` when building for the
4957 target, :term:`BUILD_ARCH` when building for the
4958 build host, and "${SDK_ARCH}-${SDKPKGSUFFIX}" when building for the
4959 SDK.
4960
4961 .. note::
4962
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004963 See :term:`SDK_ARCH` for more information.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004964
4965 However, if your recipe's output packages are built specific to the
4966 target machine rather than generally for the architecture of the
4967 machine, you should set ``PACKAGE_ARCH`` to the value of
4968 :term:`MACHINE_ARCH` in the recipe as follows:
4969 ::
4970
4971 PACKAGE_ARCH = "${MACHINE_ARCH}"
4972
Andrew Geisslerf0343792020-11-18 10:42:21 -06004973 :term:`PACKAGE_ARCHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004974 Specifies a list of architectures compatible with the target machine.
4975 This variable is set automatically and should not normally be
4976 hand-edited. Entries are separated using spaces and listed in order
4977 of priority. The default value for ``PACKAGE_ARCHS`` is "all any
4978 noarch ${PACKAGE_EXTRA_ARCHS} ${MACHINE_ARCH}".
4979
Andrew Geisslerf0343792020-11-18 10:42:21 -06004980 :term:`PACKAGE_BEFORE_PN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004981 Enables easily adding packages to ``PACKAGES`` before ``${PN}`` so
4982 that those added packages can pick up files that would normally be
4983 included in the default package.
4984
Andrew Geisslerf0343792020-11-18 10:42:21 -06004985 :term:`PACKAGE_CLASSES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004986 This variable, which is set in the ``local.conf`` configuration file
4987 found in the ``conf`` folder of the
4988 :term:`Build Directory`, specifies the package manager the
4989 OpenEmbedded build system uses when packaging data.
4990
4991 You can provide one or more of the following arguments for the
4992 variable: PACKAGE_CLASSES ?= "package_rpm package_deb package_ipk
4993 package_tar"
4994
4995 .. note::
4996
Andrew Geissler4c19ea12020-10-27 13:52:24 -05004997 While it is a legal option, the ``package_tar``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05004998 class has limited functionality due to no support for package
4999 dependencies by that backend. Therefore, it is recommended that
5000 you do not use it.
5001
5002 The build system uses only the first argument in the list as the
5003 package manager when creating your image or SDK. However, packages
5004 will be created using any additional packaging classes you specify.
5005 For example, if you use the following in your ``local.conf`` file:
5006 ::
5007
5008 PACKAGE_CLASSES ?= "package_ipk"
5009
5010 The OpenEmbedded build system uses
5011 the IPK package manager to create your image or SDK.
5012
5013 For information on packaging and build performance effects as a
5014 result of the package manager in use, see the
5015 ":ref:`package.bbclass <ref-classes-package>`" section.
5016
Andrew Geisslerf0343792020-11-18 10:42:21 -06005017 :term:`PACKAGE_DEBUG_SPLIT_STYLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005018 Determines how to split up the binary and debug information when
5019 creating ``*-dbg`` packages to be used with the GNU Project Debugger
5020 (GDB).
5021
5022 With the ``PACKAGE_DEBUG_SPLIT_STYLE`` variable, you can control
5023 where debug information, which can include or exclude source files,
5024 is stored:
5025
5026 - ".debug": Debug symbol files are placed next to the binary in a
5027 ``.debug`` directory on the target. For example, if a binary is
5028 installed into ``/bin``, the corresponding debug symbol files are
5029 installed in ``/bin/.debug``. Source files are placed in
5030 ``/usr/src/debug``.
5031
5032 - "debug-file-directory": Debug symbol files are placed under
5033 ``/usr/lib/debug`` on the target, and separated by the path from
5034 where the binary is installed. For example, if a binary is
5035 installed in ``/bin``, the corresponding debug symbols are
5036 installed in ``/usr/lib/debug/bin``. Source files are placed in
5037 ``/usr/src/debug``.
5038
5039 - "debug-without-src": The same behavior as ".debug" previously
5040 described with the exception that no source files are installed.
5041
5042 - "debug-with-srcpkg": The same behavior as ".debug" previously
5043 described with the exception that all source files are placed in a
5044 separate ``*-src`` pkg. This is the default behavior.
5045
5046 You can find out more about debugging using GDB by reading the
5047 ":ref:`platdev-gdb-remotedebug`" section
5048 in the Yocto Project Development Tasks Manual.
5049
Andrew Geisslerf0343792020-11-18 10:42:21 -06005050 :term:`PACKAGE_EXCLUDE_COMPLEMENTARY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005051 Prevents specific packages from being installed when you are
5052 installing complementary packages.
5053
5054 You might find that you want to prevent installing certain packages
5055 when you are installing complementary packages. For example, if you
5056 are using :term:`IMAGE_FEATURES` to install
5057 ``dev-pkgs``, you might not want to install all packages from a
5058 particular multilib. If you find yourself in this situation, you can
5059 use the ``PACKAGE_EXCLUDE_COMPLEMENTARY`` variable to specify regular
5060 expressions to match the packages you want to exclude.
5061
Andrew Geisslerf0343792020-11-18 10:42:21 -06005062 :term:`PACKAGE_EXCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005063 Lists packages that should not be installed into an image. For
5064 example:
5065 ::
5066
5067 PACKAGE_EXCLUDE = "package_name package_name package_name ..."
5068
5069 You can set this variable globally in your ``local.conf`` file or you
5070 can attach it to a specific image recipe by using the recipe name
5071 override:
5072 ::
5073
5074 PACKAGE_EXCLUDE_pn-target_image = "package_name"
5075
5076 If you choose to not install a package using this variable and some
5077 other package is dependent on it (i.e. listed in a recipe's
5078 :term:`RDEPENDS` variable), the OpenEmbedded build
5079 system generates a fatal installation error. Because the build system
5080 halts the process with a fatal error, you can use the variable with
5081 an iterative development process to remove specific components from a
5082 system.
5083
5084 Support for this variable exists only when using the IPK and RPM
5085 packaging backend. Support does not exist for DEB.
5086
5087 See the :term:`NO_RECOMMENDATIONS` and the
5088 :term:`BAD_RECOMMENDATIONS` variables for
5089 related information.
5090
Andrew Geisslerf0343792020-11-18 10:42:21 -06005091 :term:`PACKAGE_EXTRA_ARCHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005092 Specifies the list of architectures compatible with the device CPU.
5093 This variable is useful when you build for several different devices
5094 that use miscellaneous processors such as XScale and ARM926-EJS.
5095
Andrew Geisslerf0343792020-11-18 10:42:21 -06005096 :term:`PACKAGE_FEED_ARCHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005097 Optionally specifies the package architectures used as part of the
5098 package feed URIs during the build. When used, the
5099 ``PACKAGE_FEED_ARCHS`` variable is appended to the final package feed
5100 URI, which is constructed using the
5101 :term:`PACKAGE_FEED_URIS` and
5102 :term:`PACKAGE_FEED_BASE_PATHS`
5103 variables.
5104
5105 .. note::
5106
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005107 You can use the ``PACKAGE_FEEDS_ARCHS``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005108 variable to whitelist specific package architectures. If you do
5109 not need to whitelist specific architectures, which is a common
5110 case, you can omit this variable. Omitting the variable results in
5111 all available architectures for the current machine being included
5112 into remote package feeds.
5113
5114 Consider the following example where the ``PACKAGE_FEED_URIS``,
5115 ``PACKAGE_FEED_BASE_PATHS``, and ``PACKAGE_FEED_ARCHS`` variables are
5116 defined in your ``local.conf`` file:
5117 ::
5118
5119 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \
5120 https://example.com/packagerepos/updates"
5121 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev"
5122 PACKAGE_FEED_ARCHS = "all core2-64"
5123
5124 Given these settings, the resulting package feeds are as follows:
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005125
5126 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005127
5128 https://example.com/packagerepos/release/rpm/all
5129 https://example.com/packagerepos/release/rpm/core2-64
5130 https://example.com/packagerepos/release/rpm-dev/all
5131 https://example.com/packagerepos/release/rpm-dev/core2-64
5132 https://example.com/packagerepos/updates/rpm/all
5133 https://example.com/packagerepos/updates/rpm/core2-64
5134 https://example.com/packagerepos/updates/rpm-dev/all
5135 https://example.com/packagerepos/updates/rpm-dev/core2-64
5136
Andrew Geisslerf0343792020-11-18 10:42:21 -06005137 :term:`PACKAGE_FEED_BASE_PATHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005138 Specifies the base path used when constructing package feed URIs. The
5139 ``PACKAGE_FEED_BASE_PATHS`` variable makes up the middle portion of a
5140 package feed URI used by the OpenEmbedded build system. The base path
5141 lies between the :term:`PACKAGE_FEED_URIS`
5142 and :term:`PACKAGE_FEED_ARCHS` variables.
5143
5144 Consider the following example where the ``PACKAGE_FEED_URIS``,
5145 ``PACKAGE_FEED_BASE_PATHS``, and ``PACKAGE_FEED_ARCHS`` variables are
5146 defined in your ``local.conf`` file:
5147 ::
5148
5149 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \
5150 https://example.com/packagerepos/updates"
5151 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev"
5152 PACKAGE_FEED_ARCHS = "all core2-64"
5153
5154 Given these settings, the resulting package feeds are as follows:
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005155
5156 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005157
5158 https://example.com/packagerepos/release/rpm/all
5159 https://example.com/packagerepos/release/rpm/core2-64
5160 https://example.com/packagerepos/release/rpm-dev/all
5161 https://example.com/packagerepos/release/rpm-dev/core2-64
5162 https://example.com/packagerepos/updates/rpm/all
5163 https://example.com/packagerepos/updates/rpm/core2-64
5164 https://example.com/packagerepos/updates/rpm-dev/all
5165 https://example.com/packagerepos/updates/rpm-dev/core2-64
5166
Andrew Geisslerf0343792020-11-18 10:42:21 -06005167 :term:`PACKAGE_FEED_URIS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005168 Specifies the front portion of the package feed URI used by the
5169 OpenEmbedded build system. Each final package feed URI is comprised
5170 of ``PACKAGE_FEED_URIS``,
5171 :term:`PACKAGE_FEED_BASE_PATHS`, and
5172 :term:`PACKAGE_FEED_ARCHS` variables.
5173
5174 Consider the following example where the ``PACKAGE_FEED_URIS``,
5175 ``PACKAGE_FEED_BASE_PATHS``, and ``PACKAGE_FEED_ARCHS`` variables are
5176 defined in your ``local.conf`` file:
5177 ::
5178
5179 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \
5180 https://example.com/packagerepos/updates"
5181 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev"
5182 PACKAGE_FEED_ARCHS = "all core2-64"
5183
5184 Given these settings, the resulting package feeds are as follows:
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005185
5186 .. code-block:: none
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005187
5188 https://example.com/packagerepos/release/rpm/all
5189 https://example.com/packagerepos/release/rpm/core2-64
5190 https://example.com/packagerepos/release/rpm-dev/all
5191 https://example.com/packagerepos/release/rpm-dev/core2-64
5192 https://example.com/packagerepos/updates/rpm/all
5193 https://example.com/packagerepos/updates/rpm/core2-64
5194 https://example.com/packagerepos/updates/rpm-dev/all
5195 https://example.com/packagerepos/updates/rpm-dev/core2-64
5196
Andrew Geisslerf0343792020-11-18 10:42:21 -06005197 :term:`PACKAGE_INSTALL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005198 The final list of packages passed to the package manager for
5199 installation into the image.
5200
5201 Because the package manager controls actual installation of all
5202 packages, the list of packages passed using ``PACKAGE_INSTALL`` is
5203 not the final list of packages that are actually installed. This
5204 variable is internal to the image construction code. Consequently, in
5205 general, you should use the
5206 :term:`IMAGE_INSTALL` variable to specify
5207 packages for installation. The exception to this is when working with
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005208 the :ref:`core-image-minimal-initramfs <ref-manual/ref-images:images>`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005209 image. When working with an initial RAM filesystem (initramfs) image,
5210 use the ``PACKAGE_INSTALL`` variable. For information on creating an
5211 initramfs, see the ":ref:`building-an-initramfs-image`" section
5212 in the Yocto Project Development Tasks Manual.
5213
Andrew Geisslerf0343792020-11-18 10:42:21 -06005214 :term:`PACKAGE_INSTALL_ATTEMPTONLY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005215 Specifies a list of packages the OpenEmbedded build system attempts
5216 to install when creating an image. If a listed package fails to
5217 install, the build system does not generate an error. This variable
5218 is generally not user-defined.
5219
Andrew Geisslerf0343792020-11-18 10:42:21 -06005220 :term:`PACKAGE_PREPROCESS_FUNCS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005221 Specifies a list of functions run to pre-process the
5222 :term:`PKGD` directory prior to splitting the files out
5223 to individual packages.
5224
Andrew Geisslerf0343792020-11-18 10:42:21 -06005225 :term:`PACKAGE_WRITE_DEPS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005226 Specifies a list of dependencies for post-installation and
5227 pre-installation scripts on native/cross tools. If your
5228 post-installation or pre-installation script can execute at rootfs
5229 creation time rather than on the target but depends on a native tool
5230 in order to execute, you need to list the tools in
5231 ``PACKAGE_WRITE_DEPS``.
5232
5233 For information on running post-installation scripts, see the
5234 ":ref:`dev-manual/dev-manual-common-tasks:post-installation scripts`"
5235 section in the Yocto Project Development Tasks Manual.
5236
Andrew Geisslerf0343792020-11-18 10:42:21 -06005237 :term:`PACKAGECONFIG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005238 This variable provides a means of enabling or disabling features of a
5239 recipe on a per-recipe basis. ``PACKAGECONFIG`` blocks are defined in
5240 recipes when you specify features and then arguments that define
5241 feature behaviors. Here is the basic block structure (broken over
5242 multiple lines for readability):
5243 ::
5244
5245 PACKAGECONFIG ??= "f1 f2 f3 ..."
5246 PACKAGECONFIG[f1] = "\
5247 --with-f1, \
5248 --without-f1, \
5249 build-deps-for-f1, \
5250 runtime-deps-for-f1, \
5251 runtime-recommends-for-f1, \
5252 packageconfig-conflicts-for-f1"
5253 PACKAGECONFIG[f2] = "\
5254 ... and so on and so on ...
5255
5256 The ``PACKAGECONFIG`` variable itself specifies a space-separated
5257 list of the features to enable. Following the features, you can
5258 determine the behavior of each feature by providing up to six
5259 order-dependent arguments, which are separated by commas. You can
5260 omit any argument you like but must retain the separating commas. The
5261 order is important and specifies the following:
5262
5263 1. Extra arguments that should be added to the configure script
5264 argument list (:term:`EXTRA_OECONF` or
5265 :term:`PACKAGECONFIG_CONFARGS`) if
5266 the feature is enabled.
5267
5268 2. Extra arguments that should be added to ``EXTRA_OECONF`` or
5269 ``PACKAGECONFIG_CONFARGS`` if the feature is disabled.
5270
5271 3. Additional build dependencies (:term:`DEPENDS`)
5272 that should be added if the feature is enabled.
5273
5274 4. Additional runtime dependencies (:term:`RDEPENDS`)
5275 that should be added if the feature is enabled.
5276
5277 5. Additional runtime recommendations
5278 (:term:`RRECOMMENDS`) that should be added if
5279 the feature is enabled.
5280
5281 6. Any conflicting (that is, mutually exclusive) ``PACKAGECONFIG``
5282 settings for this feature.
5283
5284 Consider the following ``PACKAGECONFIG`` block taken from the
5285 ``librsvg`` recipe. In this example the feature is ``gtk``, which has
5286 three arguments that determine the feature's behavior.
5287 ::
5288
5289 PACKAGECONFIG[gtk] = "--with-gtk3,--without-gtk3,gtk+3"
5290
5291 The
5292 ``--with-gtk3`` and ``gtk+3`` arguments apply only if the feature is
5293 enabled. In this case, ``--with-gtk3`` is added to the configure
5294 script argument list and ``gtk+3`` is added to ``DEPENDS``. On the
5295 other hand, if the feature is disabled say through a ``.bbappend``
5296 file in another layer, then the second argument ``--without-gtk3`` is
5297 added to the configure script instead.
5298
5299 The basic ``PACKAGECONFIG`` structure previously described holds true
5300 regardless of whether you are creating a block or changing a block.
5301 When creating a block, use the structure inside your recipe.
5302
5303 If you want to change an existing ``PACKAGECONFIG`` block, you can do
5304 so one of two ways:
5305
5306 - *Append file:* Create an append file named
5307 recipename\ ``.bbappend`` in your layer and override the value of
5308 ``PACKAGECONFIG``. You can either completely override the
5309 variable:
5310 ::
5311
5312 PACKAGECONFIG = "f4 f5"
5313
5314 Or, you can just append the variable:
5315 ::
5316
5317 PACKAGECONFIG_append = " f4"
5318
5319 - *Configuration file:* This method is identical to changing the
5320 block through an append file except you edit your ``local.conf``
5321 or ``mydistro.conf`` file. As with append files previously
5322 described, you can either completely override the variable:
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005323 ::
5324
5325 PACKAGECONFIG_pn-recipename = "f4 f5"
5326
5327 Or, you can just amend the variable:
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005328 ::
5329
5330 PACKAGECONFIG_append_pn-recipename = " f4"
5331
Andrew Geisslerf0343792020-11-18 10:42:21 -06005332 :term:`PACKAGECONFIG_CONFARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005333 A space-separated list of configuration options generated from the
5334 :term:`PACKAGECONFIG` setting.
5335
5336 Classes such as :ref:`autotools <ref-classes-autotools>` and
5337 :ref:`cmake <ref-classes-cmake>` use ``PACKAGECONFIG_CONFARGS`` to
5338 pass ``PACKAGECONFIG`` options to ``configure`` and ``cmake``,
5339 respectively. If you are using ``PACKAGECONFIG`` but not a class that
5340 handles the ``do_configure`` task, then you need to use
5341 ``PACKAGECONFIG_CONFARGS`` appropriately.
5342
Andrew Geisslerf0343792020-11-18 10:42:21 -06005343 :term:`PACKAGEGROUP_DISABLE_COMPLEMENTARY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005344 For recipes inheriting the
5345 :ref:`packagegroup <ref-classes-packagegroup>` class, setting
5346 ``PACKAGEGROUP_DISABLE_COMPLEMENTARY`` to "1" specifies that the
5347 normal complementary packages (i.e. ``-dev``, ``-dbg``, and so forth)
5348 should not be automatically created by the ``packagegroup`` recipe,
5349 which is the default behavior.
5350
Andrew Geisslerf0343792020-11-18 10:42:21 -06005351 :term:`PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005352 The list of packages the recipe creates. The default value is the
5353 following:
5354 ::
5355
5356 ${PN}-dbg ${PN}-staticdev ${PN}-dev ${PN}-doc ${PN}-locale ${PACKAGE_BEFORE_PN} ${PN}
5357
5358 During packaging, the :ref:`ref-tasks-package` task
5359 goes through ``PACKAGES`` and uses the :term:`FILES`
5360 variable corresponding to each package to assign files to the
5361 package. If a file matches the ``FILES`` variable for more than one
5362 package in ``PACKAGES``, it will be assigned to the earliest
5363 (leftmost) package.
5364
5365 Packages in the variable's list that are empty (i.e. where none of
5366 the patterns in ``FILES_``\ pkg match any files installed by the
5367 :ref:`ref-tasks-install` task) are not generated,
5368 unless generation is forced through the
5369 :term:`ALLOW_EMPTY` variable.
5370
Andrew Geisslerf0343792020-11-18 10:42:21 -06005371 :term:`PACKAGES_DYNAMIC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005372 A promise that your recipe satisfies runtime dependencies for
5373 optional modules that are found in other recipes.
5374 ``PACKAGES_DYNAMIC`` does not actually satisfy the dependencies, it
5375 only states that they should be satisfied. For example, if a hard,
5376 runtime dependency (:term:`RDEPENDS`) of another
5377 package is satisfied at build time through the ``PACKAGES_DYNAMIC``
5378 variable, but a package with the module name is never actually
5379 produced, then the other package will be broken. Thus, if you attempt
5380 to include that package in an image, you will get a dependency
5381 failure from the packaging system during the
5382 :ref:`ref-tasks-rootfs` task.
5383
5384 Typically, if there is a chance that such a situation can occur and
5385 the package that is not created is valid without the dependency being
5386 satisfied, then you should use :term:`RRECOMMENDS`
5387 (a soft runtime dependency) instead of ``RDEPENDS``.
5388
5389 For an example of how to use the ``PACKAGES_DYNAMIC`` variable when
5390 you are splitting packages, see the
5391 ":ref:`dev-manual/dev-manual-common-tasks:handling optional module packaging`"
5392 section in the Yocto Project Development Tasks Manual.
5393
Andrew Geisslerf0343792020-11-18 10:42:21 -06005394 :term:`PACKAGESPLITFUNCS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005395 Specifies a list of functions run to perform additional splitting of
5396 files into individual packages. Recipes can either prepend to this
5397 variable or prepend to the ``populate_packages`` function in order to
5398 perform additional package splitting. In either case, the function
5399 should set :term:`PACKAGES`,
5400 :term:`FILES`, :term:`RDEPENDS` and
5401 other packaging variables appropriately in order to perform the
5402 desired splitting.
5403
Andrew Geisslerf0343792020-11-18 10:42:21 -06005404 :term:`PARALLEL_MAKE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005405 Extra options passed to the ``make`` command during the
5406 :ref:`ref-tasks-compile` task in order to specify
5407 parallel compilation on the local build host. This variable is
5408 usually in the form "-j x", where x represents the maximum number of
5409 parallel threads ``make`` can run.
5410
5411 .. note::
5412
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005413 In order for ``PARALLEL_MAKE`` to be effective, ``make`` must be
5414 called with ``${``\ :term:`EXTRA_OEMAKE`\ ``}``. An easy way to ensure
5415 this is to use the ``oe_runmake`` function.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005416
5417 By default, the OpenEmbedded build system automatically sets this
5418 variable to be equal to the number of cores the build system uses.
5419
5420 .. note::
5421
5422 If the software being built experiences dependency issues during
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005423 the ``do_compile`` task that result in race conditions, you can clear
5424 the ``PARALLEL_MAKE`` variable within the recipe as a workaround. For
5425 information on addressing race conditions, see the
5426 ":ref:`dev-manual/dev-manual-common-tasks:debugging parallel make races`"
5427 section in the Yocto Project Development Tasks Manual.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005428
5429 For single socket systems (i.e. one CPU), you should not have to
5430 override this variable to gain optimal parallelism during builds.
5431 However, if you have very large systems that employ multiple physical
5432 CPUs, you might want to make sure the ``PARALLEL_MAKE`` variable is
5433 not set higher than "-j 20".
5434
5435 For more information on speeding up builds, see the
5436 ":ref:`dev-manual/dev-manual-common-tasks:speeding up a build`"
5437 section in the Yocto Project Development Tasks Manual.
5438
Andrew Geisslerf0343792020-11-18 10:42:21 -06005439 :term:`PARALLEL_MAKEINST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005440 Extra options passed to the ``make install`` command during the
5441 :ref:`ref-tasks-install` task in order to specify
5442 parallel installation. This variable defaults to the value of
5443 :term:`PARALLEL_MAKE`.
5444
5445 .. note::
5446
5447 In order for ``PARALLEL_MAKEINST`` to be effective, ``make`` must
5448 be called with
5449 ``${``\ :term:`EXTRA_OEMAKE`\ ``}``. An easy
5450 way to ensure this is to use the ``oe_runmake`` function.
5451
5452 If the software being built experiences dependency issues during
5453 the ``do_install`` task that result in race conditions, you can
5454 clear the ``PARALLEL_MAKEINST`` variable within the recipe as a
5455 workaround. For information on addressing race conditions, see the
5456 ":ref:`dev-manual/dev-manual-common-tasks:debugging parallel make races`"
5457 section in the Yocto Project Development Tasks Manual.
5458
Andrew Geisslerf0343792020-11-18 10:42:21 -06005459 :term:`PATCHRESOLVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005460 Determines the action to take when a patch fails. You can set this
5461 variable to one of two values: "noop" and "user".
5462
5463 The default value of "noop" causes the build to simply fail when the
5464 OpenEmbedded build system cannot successfully apply a patch. Setting
5465 the value to "user" causes the build system to launch a shell and
5466 places you in the right location so that you can manually resolve the
5467 conflicts.
5468
5469 Set this variable in your ``local.conf`` file.
5470
Andrew Geisslerf0343792020-11-18 10:42:21 -06005471 :term:`PATCHTOOL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005472 Specifies the utility used to apply patches for a recipe during the
5473 :ref:`ref-tasks-patch` task. You can specify one of
5474 three utilities: "patch", "quilt", or "git". The default utility used
5475 is "quilt" except for the quilt-native recipe itself. Because the
5476 quilt tool is not available at the time quilt-native is being
5477 patched, it uses "patch".
5478
5479 If you wish to use an alternative patching tool, set the variable in
5480 the recipe using one of the following:
5481 ::
5482
5483 PATCHTOOL = "patch"
5484 PATCHTOOL = "quilt"
5485 PATCHTOOL = "git"
5486
Andrew Geisslerf0343792020-11-18 10:42:21 -06005487 :term:`PE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005488 The epoch of the recipe. By default, this variable is unset. The
5489 variable is used to make upgrades possible when the versioning scheme
5490 changes in some backwards incompatible way.
5491
5492 ``PE`` is the default value of the :term:`PKGE` variable.
5493
Andrew Geisslerf0343792020-11-18 10:42:21 -06005494 :term:`PF`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005495 Specifies the recipe or package name and includes all version and
5496 revision numbers (i.e. ``glibc-2.13-r20+svnr15508/`` and
5497 ``bash-4.2-r1/``). This variable is comprised of the following:
5498 ${:term:`PN`}-${:term:`EXTENDPE`}${:term:`PV`}-${:term:`PR`}
5499
Andrew Geisslerf0343792020-11-18 10:42:21 -06005500 :term:`PIXBUF_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005501 When inheriting the :ref:`pixbufcache <ref-classes-pixbufcache>`
5502 class, this variable identifies packages that contain the pixbuf
5503 loaders used with ``gdk-pixbuf``. By default, the ``pixbufcache``
5504 class assumes that the loaders are in the recipe's main package (i.e.
5505 ``${``\ :term:`PN`\ ``}``). Use this variable if the
5506 loaders you need are in a package other than that main package.
5507
Andrew Geisslerf0343792020-11-18 10:42:21 -06005508 :term:`PKG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005509 The name of the resulting package created by the OpenEmbedded build
5510 system.
5511
5512 .. note::
5513
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005514 When using the ``PKG`` variable, you must use a package name override.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005515
5516 For example, when the :ref:`debian <ref-classes-debian>` class
5517 renames the output package, it does so by setting
5518 ``PKG_packagename``.
5519
Andrew Geisslerf0343792020-11-18 10:42:21 -06005520 :term:`PKG_CONFIG_PATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005521 The path to ``pkg-config`` files for the current build context.
5522 ``pkg-config`` reads this variable from the environment.
5523
Andrew Geisslerf0343792020-11-18 10:42:21 -06005524 :term:`PKGD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005525 Points to the destination directory for files to be packaged before
5526 they are split into individual packages. This directory defaults to
5527 the following:
5528 ::
5529
5530 ${WORKDIR}/package
5531
5532 Do not change this default.
5533
Andrew Geisslerf0343792020-11-18 10:42:21 -06005534 :term:`PKGDATA_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005535 Points to a shared, global-state directory that holds data generated
5536 during the packaging process. During the packaging process, the
5537 :ref:`ref-tasks-packagedata` task packages data
5538 for each recipe and installs it into this temporary, shared area.
5539 This directory defaults to the following, which you should not
5540 change:
5541 ::
5542
5543 ${STAGING_DIR_HOST}/pkgdata
5544
5545 For examples of how this data is used, see the
5546 ":ref:`overview-manual/overview-manual-concepts:automatically added runtime dependencies`"
5547 section in the Yocto Project Overview and Concepts Manual and the
5548 ":ref:`dev-manual/dev-manual-common-tasks:viewing package information with \`\`oe-pkgdata-util\`\``"
5549 section in the Yocto Project Development Tasks Manual. For more
5550 information on the shared, global-state directory, see
5551 :term:`STAGING_DIR_HOST`.
5552
Andrew Geisslerf0343792020-11-18 10:42:21 -06005553 :term:`PKGDEST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005554 Points to the parent directory for files to be packaged after they
5555 have been split into individual packages. This directory defaults to
5556 the following:
5557 ::
5558
5559 ${WORKDIR}/packages-split
5560
5561 Under this directory, the build system creates directories for each
5562 package specified in :term:`PACKAGES`. Do not change
5563 this default.
5564
Andrew Geisslerf0343792020-11-18 10:42:21 -06005565 :term:`PKGDESTWORK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005566 Points to a temporary work area where the
5567 :ref:`ref-tasks-package` task saves package metadata.
5568 The ``PKGDESTWORK`` location defaults to the following:
5569 ::
5570
5571 ${WORKDIR}/pkgdata
5572
5573 Do not change this default.
5574
5575 The :ref:`ref-tasks-packagedata` task copies the
5576 package metadata from ``PKGDESTWORK`` to
5577 :term:`PKGDATA_DIR` to make it available globally.
5578
Andrew Geisslerf0343792020-11-18 10:42:21 -06005579 :term:`PKGE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005580 The epoch of the package(s) built by the recipe. By default, ``PKGE``
5581 is set to :term:`PE`.
5582
Andrew Geisslerf0343792020-11-18 10:42:21 -06005583 :term:`PKGR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005584 The revision of the package(s) built by the recipe. By default,
5585 ``PKGR`` is set to :term:`PR`.
5586
Andrew Geisslerf0343792020-11-18 10:42:21 -06005587 :term:`PKGV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005588 The version of the package(s) built by the recipe. By default,
5589 ``PKGV`` is set to :term:`PV`.
5590
Andrew Geisslerf0343792020-11-18 10:42:21 -06005591 :term:`PN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005592 This variable can have two separate functions depending on the
5593 context: a recipe name or a resulting package name.
5594
5595 ``PN`` refers to a recipe name in the context of a file used by the
5596 OpenEmbedded build system as input to create a package. The name is
5597 normally extracted from the recipe file name. For example, if the
5598 recipe is named ``expat_2.0.1.bb``, then the default value of ``PN``
5599 will be "expat".
5600
5601 The variable refers to a package name in the context of a file
5602 created or produced by the OpenEmbedded build system.
5603
5604 If applicable, the ``PN`` variable also contains any special suffix
5605 or prefix. For example, using ``bash`` to build packages for the
5606 native machine, ``PN`` is ``bash-native``. Using ``bash`` to build
5607 packages for the target and for Multilib, ``PN`` would be ``bash``
5608 and ``lib64-bash``, respectively.
5609
Andrew Geisslerf0343792020-11-18 10:42:21 -06005610 :term:`PNBLACKLIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005611 Lists recipes you do not want the OpenEmbedded build system to build.
5612 This variable works in conjunction with the
5613 :ref:`blacklist <ref-classes-blacklist>` class, which is inherited
5614 globally.
5615
5616 To prevent a recipe from being built, use the ``PNBLACKLIST``
5617 variable in your ``local.conf`` file. Here is an example that
5618 prevents ``myrecipe`` from being built:
5619 ::
5620
5621 PNBLACKLIST[myrecipe] = "Not supported by our organization."
5622
Andrew Geisslerf0343792020-11-18 10:42:21 -06005623 :term:`POPULATE_SDK_POST_HOST_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005624 Specifies a list of functions to call once the OpenEmbedded build
5625 system has created the host part of the SDK. You can specify
5626 functions separated by semicolons:
5627 ::
5628
5629 POPULATE_SDK_POST_HOST_COMMAND += "function; ... "
5630
5631 If you need to pass the SDK path to a command within a function, you
5632 can use ``${SDK_DIR}``, which points to the parent directory used by
5633 the OpenEmbedded build system when creating SDK output. See the
5634 :term:`SDK_DIR` variable for more information.
5635
Andrew Geisslerf0343792020-11-18 10:42:21 -06005636 :term:`POPULATE_SDK_POST_TARGET_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005637 Specifies a list of functions to call once the OpenEmbedded build
5638 system has created the target part of the SDK. You can specify
5639 functions separated by semicolons:
5640 ::
5641
5642 POPULATE_SDK_POST_TARGET_COMMAND += "function; ... "
5643
5644 If you need to pass the SDK path to a command within a function, you
5645 can use ``${SDK_DIR}``, which points to the parent directory used by
5646 the OpenEmbedded build system when creating SDK output. See the
5647 :term:`SDK_DIR` variable for more information.
5648
Andrew Geisslerf0343792020-11-18 10:42:21 -06005649 :term:`PR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005650 The revision of the recipe. The default value for this variable is
5651 "r0". Subsequent revisions of the recipe conventionally have the
5652 values "r1", "r2", and so forth. When :term:`PV` increases,
5653 ``PR`` is conventionally reset to "r0".
5654
5655 .. note::
5656
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005657 The OpenEmbedded build system does not need the aid of ``PR``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005658 to know when to rebuild a recipe. The build system uses the task
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005659 :ref:`input checksums <overview-checksums>` along with the
5660 :ref:`stamp <structure-build-tmp-stamps>` and
5661 :ref:`overview-manual/overview-manual-concepts:shared state cache`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005662 mechanisms.
5663
5664 The ``PR`` variable primarily becomes significant when a package
5665 manager dynamically installs packages on an already built image. In
5666 this case, ``PR``, which is the default value of
5667 :term:`PKGR`, helps the package manager distinguish which
5668 package is the most recent one in cases where many packages have the
5669 same ``PV`` (i.e. ``PKGV``). A component having many packages with
5670 the same ``PV`` usually means that the packages all install the same
5671 upstream version, but with later (``PR``) version packages including
5672 packaging fixes.
5673
5674 .. note::
5675
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005676 ``PR`` does not need to be increased for changes that do not change the
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005677 package contents or metadata.
5678
5679 Because manually managing ``PR`` can be cumbersome and error-prone,
5680 an automated solution exists. See the
5681 ":ref:`dev-manual/dev-manual-common-tasks:working with a pr service`" section
5682 in the Yocto Project Development Tasks Manual for more information.
5683
Andrew Geisslerf0343792020-11-18 10:42:21 -06005684 :term:`PREFERRED_PROVIDER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005685 If multiple recipes provide the same item, this variable determines
5686 which recipe is preferred and thus provides the item (i.e. the
5687 preferred provider). You should always suffix this variable with the
5688 name of the provided item. And, you should define the variable using
5689 the preferred recipe's name (:term:`PN`). Here is a common
5690 example:
5691 ::
5692
5693 PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto"
5694
5695 In the previous example, multiple recipes are providing "virtual/kernel".
5696 The ``PREFERRED_PROVIDER`` variable is set with the name (``PN``) of
5697 the recipe you prefer to provide "virtual/kernel".
5698
5699 Following are more examples:
5700 ::
5701
5702 PREFERRED_PROVIDER_virtual/xserver = "xserver-xf86"
5703 PREFERRED_PROVIDER_virtual/libgl ?= "mesa"
5704
5705 For more
5706 information, see the ":ref:`metadata-virtual-providers`"
5707 section in the Yocto Project Development Tasks Manual.
5708
5709 .. note::
5710
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005711 If you use a ``virtual/\*`` item with ``PREFERRED_PROVIDER``, then any
5712 recipe that :term:`PROVIDES` that item but is not selected (defined)
5713 by ``PREFERRED_PROVIDER`` is prevented from building, which is usually
5714 desirable since this mechanism is designed to select between mutually
5715 exclusive alternative providers.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005716
Andrew Geisslerf0343792020-11-18 10:42:21 -06005717 :term:`PREFERRED_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005718 If multiple versions of recipes exist, this variable determines which
5719 version is given preference. You must always suffix the variable with
5720 the :term:`PN` you want to select, and you should set the
5721 :term:`PV` accordingly for precedence.
5722
5723 The ``PREFERRED_VERSION`` variable supports limited wildcard use
5724 through the "``%``" character. You can use the character to match any
5725 number of characters, which can be useful when specifying versions
5726 that contain long revision numbers that potentially change. Here are
5727 two examples:
5728 ::
5729
5730 PREFERRED_VERSION_python = "3.4.0"
5731 PREFERRED_VERSION_linux-yocto = "5.0%"
5732
5733 .. note::
5734
5735 The use of the "%" character is limited in that it only works at the end of the
5736 string. You cannot use the wildcard character in any other
5737 location of the string.
5738
5739 The specified version is matched against :term:`PV`, which
5740 does not necessarily match the version part of the recipe's filename.
5741 For example, consider two recipes ``foo_1.2.bb`` and ``foo_git.bb``
5742 where ``foo_git.bb`` contains the following assignment:
5743 ::
5744
5745 PV = "1.1+git${SRCPV}"
5746
5747 In this case, the correct way to select
5748 ``foo_git.bb`` is by using an assignment such as the following:
5749 ::
5750
5751 PREFERRED_VERSION_foo = "1.1+git%"
5752
5753 Compare that previous example
5754 against the following incorrect example, which does not work:
5755 ::
5756
5757 PREFERRED_VERSION_foo = "git"
5758
5759 Sometimes the ``PREFERRED_VERSION`` variable can be set by
5760 configuration files in a way that is hard to change. You can use
5761 :term:`OVERRIDES` to set a machine-specific
5762 override. Here is an example:
5763 ::
5764
5765 PREFERRED_VERSION_linux-yocto_qemux86 = "5.0%"
5766
5767 Although not recommended, worst case, you can also use the
5768 "forcevariable" override, which is the strongest override possible.
5769 Here is an example:
5770 ::
5771
5772 PREFERRED_VERSION_linux-yocto_forcevariable = "5.0%"
5773
5774 .. note::
5775
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005776 The ``\_forcevariable`` override is not handled specially. This override
5777 only works because the default value of ``OVERRIDES`` includes "forcevariable".
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005778
Andrew Geisslerf0343792020-11-18 10:42:21 -06005779 :term:`PREMIRRORS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005780 Specifies additional paths from which the OpenEmbedded build system
5781 gets source code. When the build system searches for source code, it
5782 first tries the local download directory. If that location fails, the
5783 build system tries locations defined by ``PREMIRRORS``, the upstream
5784 source, and then locations specified by
5785 :term:`MIRRORS` in that order.
5786
5787 Assuming your distribution (:term:`DISTRO`) is "poky",
5788 the default value for ``PREMIRRORS`` is defined in the
5789 ``conf/distro/poky.conf`` file in the ``meta-poky`` Git repository.
5790
5791 Typically, you could add a specific server for the build system to
5792 attempt before any others by adding something like the following to
5793 the ``local.conf`` configuration file in the
5794 :term:`Build Directory`:
5795 ::
5796
5797 PREMIRRORS_prepend = "\
5798 git://.*/.* http://www.yoctoproject.org/sources/ \n \
5799 ftp://.*/.* http://www.yoctoproject.org/sources/ \n \
5800 http://.*/.* http://www.yoctoproject.org/sources/ \n \
5801 https://.*/.* http://www.yoctoproject.org/sources/ \n"
5802
5803 These changes cause the
5804 build system to intercept Git, FTP, HTTP, and HTTPS requests and
5805 direct them to the ``http://`` sources mirror. You can use
5806 ``file://`` URLs to point to local directories or network shares as
5807 well.
5808
Andrew Geisslerf0343792020-11-18 10:42:21 -06005809 :term:`PRIORITY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005810 Indicates the importance of a package.
5811
5812 ``PRIORITY`` is considered to be part of the distribution policy
5813 because the importance of any given recipe depends on the purpose for
5814 which the distribution is being produced. Thus, ``PRIORITY`` is not
5815 normally set within recipes.
5816
5817 You can set ``PRIORITY`` to "required", "standard", "extra", and
5818 "optional", which is the default.
5819
Andrew Geisslerf0343792020-11-18 10:42:21 -06005820 :term:`PRIVATE_LIBS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005821 Specifies libraries installed within a recipe that should be ignored
5822 by the OpenEmbedded build system's shared library resolver. This
5823 variable is typically used when software being built by a recipe has
5824 its own private versions of a library normally provided by another
5825 recipe. In this case, you would not want the package containing the
5826 private libraries to be set as a dependency on other unrelated
5827 packages that should instead depend on the package providing the
5828 standard version of the library.
5829
5830 Libraries specified in this variable should be specified by their
5831 file name. For example, from the Firefox recipe in meta-browser:
5832 ::
5833
5834 PRIVATE_LIBS = "libmozjs.so \
5835 libxpcom.so \
5836 libnspr4.so \
5837 libxul.so \
5838 libmozalloc.so \
5839 libplc4.so \
5840 libplds4.so"
5841
5842 For more information, see the
5843 ":ref:`overview-manual/overview-manual-concepts:automatically added runtime dependencies`"
5844 section in the Yocto Project Overview and Concepts Manual.
5845
Andrew Geisslerf0343792020-11-18 10:42:21 -06005846 :term:`PROVIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005847 A list of aliases by which a particular recipe can be known. By
5848 default, a recipe's own ``PN`` is implicitly already in its
5849 ``PROVIDES`` list and therefore does not need to mention that it
5850 provides itself. If a recipe uses ``PROVIDES``, the additional
5851 aliases are synonyms for the recipe and can be useful for satisfying
5852 dependencies of other recipes during the build as specified by
5853 ``DEPENDS``.
5854
5855 Consider the following example ``PROVIDES`` statement from the recipe
5856 file ``eudev_3.2.9.bb``:
5857 ::
5858
5859 PROVIDES = "udev"
5860
5861 The ``PROVIDES`` statement
5862 results in the "eudev" recipe also being available as simply "udev".
5863
5864 .. note::
5865
5866 Given that a recipe's own recipe name is already implicitly in its
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005867 own PROVIDES list, it is unnecessary to add aliases with the "+=" operator;
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005868 using a simple assignment will be sufficient. In other words,
5869 while you could write:
5870 ::
5871
5872 PROVIDES += "udev"
5873
5874
5875 in the above, the "+=" is overkill and unnecessary.
5876
5877 In addition to providing recipes under alternate names, the
5878 ``PROVIDES`` mechanism is also used to implement virtual targets. A
5879 virtual target is a name that corresponds to some particular
5880 functionality (e.g. a Linux kernel). Recipes that provide the
5881 functionality in question list the virtual target in ``PROVIDES``.
5882 Recipes that depend on the functionality in question can include the
5883 virtual target in ``DEPENDS`` to leave the choice of provider open.
5884
5885 Conventionally, virtual targets have names on the form
5886 "virtual/function" (e.g. "virtual/kernel"). The slash is simply part
5887 of the name and has no syntactical significance.
5888
5889 The :term:`PREFERRED_PROVIDER` variable is
5890 used to select which particular recipe provides a virtual target.
5891
5892 .. note::
5893
5894 A corresponding mechanism for virtual runtime dependencies
5895 (packages) exists. However, the mechanism does not depend on any
5896 special functionality beyond ordinary variable assignments. For
5897 example, ``VIRTUAL-RUNTIME_dev_manager`` refers to the package of
5898 the component that manages the ``/dev`` directory.
5899
5900 Setting the "preferred provider" for runtime dependencies is as
5901 simple as using the following assignment in a configuration file:
5902 ::
5903
5904 VIRTUAL-RUNTIME_dev_manager = "udev"
5905
5906
Andrew Geisslerf0343792020-11-18 10:42:21 -06005907 :term:`PRSERV_HOST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005908 The network based :term:`PR` service host and port.
5909
5910 The ``conf/local.conf.sample.extended`` configuration file in the
5911 :term:`Source Directory` shows how the
5912 ``PRSERV_HOST`` variable is set:
5913 ::
5914
5915 PRSERV_HOST = "localhost:0"
5916
5917 You must
5918 set the variable if you want to automatically start a local :ref:`PR
5919 service <dev-manual/dev-manual-common-tasks:working with a pr service>`. You can
5920 set ``PRSERV_HOST`` to other values to use a remote PR service.
5921
Andrew Geisslerf0343792020-11-18 10:42:21 -06005922 :term:`PTEST_ENABLED`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005923 Specifies whether or not :ref:`Package
5924 Test <dev-manual/dev-manual-common-tasks:testing packages with ptest>` (ptest)
5925 functionality is enabled when building a recipe. You should not set
5926 this variable directly. Enabling and disabling building Package Tests
5927 at build time should be done by adding "ptest" to (or removing it
5928 from) :term:`DISTRO_FEATURES`.
5929
Andrew Geisslerf0343792020-11-18 10:42:21 -06005930 :term:`PV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005931 The version of the recipe. The version is normally extracted from the
5932 recipe filename. For example, if the recipe is named
5933 ``expat_2.0.1.bb``, then the default value of ``PV`` will be "2.0.1".
5934 ``PV`` is generally not overridden within a recipe unless it is
5935 building an unstable (i.e. development) version from a source code
5936 repository (e.g. Git or Subversion).
5937
5938 ``PV`` is the default value of the :term:`PKGV` variable.
5939
Andrew Geisslerf0343792020-11-18 10:42:21 -06005940 :term:`PYTHON_ABI`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005941 When used by recipes that inherit the
5942 :ref:`distutils3 <ref-classes-distutils3>`,
5943 :ref:`setuptools3 <ref-classes-setuptools3>`,
5944 :ref:`distutils <ref-classes-distutils>`, or
5945 :ref:`setuptools <ref-classes-setuptools>` classes, denotes the
5946 Application Binary Interface (ABI) currently in use for Python. By
5947 default, the ABI is "m". You do not have to set this variable as the
5948 OpenEmbedded build system sets it for you.
5949
5950 The OpenEmbedded build system uses the ABI to construct directory
5951 names used when installing the Python headers and libraries in
5952 sysroot (e.g. ``.../python3.3m/...``).
5953
5954 Recipes that inherit the ``distutils`` class during cross-builds also
5955 use this variable to locate the headers and libraries of the
5956 appropriate Python that the extension is targeting.
5957
Andrew Geisslerf0343792020-11-18 10:42:21 -06005958 :term:`PYTHON_PN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005959 When used by recipes that inherit the
5960 `distutils3 <ref-classes-distutils3>`,
5961 :ref:`setuptools3 <ref-classes-setuptools3>`,
5962 :ref:`distutils <ref-classes-distutils>`, or
5963 :ref:`setuptools <ref-classes-setuptools>` classes, specifies the
5964 major Python version being built. For Python 3.x, ``PYTHON_PN`` would
5965 be "python3". You do not have to set this variable as the
5966 OpenEmbedded build system automatically sets it for you.
5967
5968 The variable allows recipes to use common infrastructure such as the
5969 following:
5970 ::
5971
5972 DEPENDS += "${PYTHON_PN}-native"
5973
5974 In the previous example,
5975 the version of the dependency is ``PYTHON_PN``.
5976
Andrew Geisslerf0343792020-11-18 10:42:21 -06005977 :term:`RANLIB`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005978 The minimal command and arguments to run ``ranlib``.
5979
Andrew Geisslerf0343792020-11-18 10:42:21 -06005980 :term:`RCONFLICTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05005981 The list of packages that conflict with packages. Note that packages
5982 will not be installed if conflicting packages are not first removed.
5983
5984 Like all package-controlling variables, you must always use them in
5985 conjunction with a package name override. Here is an example:
5986 ::
5987
5988 RCONFLICTS_${PN} = "another_conflicting_package_name"
5989
5990 BitBake, which the OpenEmbedded build system uses, supports
5991 specifying versioned dependencies. Although the syntax varies
5992 depending on the packaging format, BitBake hides these differences
5993 from you. Here is the general syntax to specify versions with the
5994 ``RCONFLICTS`` variable:
5995 ::
5996
5997 RCONFLICTS_${PN} = "package (operator version)"
5998
Andrew Geissler4c19ea12020-10-27 13:52:24 -05005999 For ``operator``, you can specify the following:
6000
6001 - =
6002 - <
6003 - >
6004 - <=
6005 - >=
6006
6007 For example, the following sets up a dependency on version 1.2 or
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006008 greater of the package ``foo``:
6009 ::
6010
6011 RCONFLICTS_${PN} = "foo (>= 1.2)"
6012
Andrew Geisslerf0343792020-11-18 10:42:21 -06006013 :term:`RDEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006014 Lists runtime dependencies of a package. These dependencies are other
6015 packages that must be installed in order for the package to function
6016 correctly. As an example, the following assignment declares that the
6017 package ``foo`` needs the packages ``bar`` and ``baz`` to be
6018 installed:
6019 ::
6020
6021 RDEPENDS_foo = "bar baz"
6022
6023 The most common types of package
6024 runtime dependencies are automatically detected and added. Therefore,
6025 most recipes do not need to set ``RDEPENDS``. For more information,
6026 see the
6027 ":ref:`overview-manual/overview-manual-concepts:automatically added runtime dependencies`"
6028 section in the Yocto Project Overview and Concepts Manual.
6029
6030 The practical effect of the above ``RDEPENDS`` assignment is that
6031 ``bar`` and ``baz`` will be declared as dependencies inside the
6032 package ``foo`` when it is written out by one of the
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006033 :ref:`do_package_write_\* <ref-tasks-package_write_deb>` tasks.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006034 Exactly how this is done depends on which package format is used,
6035 which is determined by
6036 :term:`PACKAGE_CLASSES`. When the
6037 corresponding package manager installs the package, it will know to
6038 also install the packages on which it depends.
6039
6040 To ensure that the packages ``bar`` and ``baz`` get built, the
6041 previous ``RDEPENDS`` assignment also causes a task dependency to be
6042 added. This dependency is from the recipe's
6043 :ref:`ref-tasks-build` (not to be confused with
6044 :ref:`ref-tasks-compile`) task to the
6045 ``do_package_write_*`` task of the recipes that build ``bar`` and
6046 ``baz``.
6047
6048 The names of the packages you list within ``RDEPENDS`` must be the
6049 names of other packages - they cannot be recipe names. Although
6050 package names and recipe names usually match, the important point
6051 here is that you are providing package names within the ``RDEPENDS``
6052 variable. For an example of the default list of packages created from
6053 a recipe, see the :term:`PACKAGES` variable.
6054
6055 Because the ``RDEPENDS`` variable applies to packages being built,
6056 you should always use the variable in a form with an attached package
6057 name (remember that a single recipe can build multiple packages). For
6058 example, suppose you are building a development package that depends
6059 on the ``perl`` package. In this case, you would use the following
6060 ``RDEPENDS`` statement:
6061 ::
6062
6063 RDEPENDS_${PN}-dev += "perl"
6064
6065 In the example,
6066 the development package depends on the ``perl`` package. Thus, the
6067 ``RDEPENDS`` variable has the ``${PN}-dev`` package name as part of
6068 the variable.
6069
6070 .. note::
6071
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006072 ``RDEPENDS_${PN}-dev`` includes ``${``\ :term:`PN`\ ``}``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006073 by default. This default is set in the BitBake configuration file
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006074 (``meta/conf/bitbake.conf``). Be careful not to accidentally remove
6075 ``${PN}`` when modifying ``RDEPENDS_${PN}-dev``. Use the "+=" operator
6076 rather than the "=" operator.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006077
6078 The package names you use with ``RDEPENDS`` must appear as they would
6079 in the ``PACKAGES`` variable. The :term:`PKG` variable
6080 allows a different name to be used for the final package (e.g. the
6081 :ref:`debian <ref-classes-debian>` class uses this to rename
6082 packages), but this final package name cannot be used with
6083 ``RDEPENDS``, which makes sense as ``RDEPENDS`` is meant to be
6084 independent of the package format used.
6085
6086 BitBake, which the OpenEmbedded build system uses, supports
6087 specifying versioned dependencies. Although the syntax varies
6088 depending on the packaging format, BitBake hides these differences
6089 from you. Here is the general syntax to specify versions with the
6090 ``RDEPENDS`` variable:
6091 ::
6092
6093 RDEPENDS_${PN} = "package (operator version)"
6094
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006095 For ``operator``, you can specify the following:
6096
6097 - =
6098 - <
6099 - >
6100 - <=
6101 - >=
6102
6103 For version, provide the version number.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006104
6105 .. note::
6106
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006107 You can use ``EXTENDPKGV`` to provide a full package version
6108 specification.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006109
6110 For example, the following sets up a dependency on version 1.2 or
6111 greater of the package ``foo``:
6112 ::
6113
6114 RDEPENDS_${PN} = "foo (>= 1.2)"
6115
6116 For information on build-time dependencies, see the
6117 :term:`DEPENDS` variable. You can also see the
6118 ":ref:`Tasks <bitbake:bitbake-user-manual/bitbake-user-manual-metadata:tasks>`" and
6119 ":ref:`Dependencies <bitbake:bitbake-user-manual/bitbake-user-manual-execution:dependencies>`" sections in the
6120 BitBake User Manual for additional information on tasks and
6121 dependencies.
6122
Andrew Geisslerf0343792020-11-18 10:42:21 -06006123 :term:`REQUIRED_DISTRO_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006124 When inheriting the
6125 :ref:`distro_features_check <ref-classes-distro_features_check>`
6126 class, this variable identifies distribution features that must exist
6127 in the current configuration in order for the OpenEmbedded build
6128 system to build the recipe. In other words, if the
6129 ``REQUIRED_DISTRO_FEATURES`` variable lists a feature that does not
6130 appear in ``DISTRO_FEATURES`` within the current configuration, an
6131 error occurs and the build stops.
6132
Andrew Geisslerf0343792020-11-18 10:42:21 -06006133 :term:`RM_WORK_EXCLUDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006134 With ``rm_work`` enabled, this variable specifies a list of recipes
6135 whose work directories should not be removed. See the
6136 ":ref:`rm_work.bbclass <ref-classes-rm-work>`" section for more
6137 details.
6138
Andrew Geisslerf0343792020-11-18 10:42:21 -06006139 :term:`ROOT_HOME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006140 Defines the root home directory. By default, this directory is set as
6141 follows in the BitBake configuration file:
6142 ::
6143
6144 ROOT_HOME ??= "/home/root"
6145
6146 .. note::
6147
6148 This default value is likely used because some embedded solutions
6149 prefer to have a read-only root filesystem and prefer to keep
6150 writeable data in one place.
6151
6152 You can override the default by setting the variable in any layer or
6153 in the ``local.conf`` file. Because the default is set using a "weak"
6154 assignment (i.e. "??="), you can use either of the following forms to
6155 define your override:
6156 ::
6157
6158 ROOT_HOME = "/root"
6159 ROOT_HOME ?= "/root"
6160
6161 These
6162 override examples use ``/root``, which is probably the most commonly
6163 used override.
6164
Andrew Geisslerf0343792020-11-18 10:42:21 -06006165 :term:`ROOTFS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006166 Indicates a filesystem image to include as the root filesystem.
6167
6168 The ``ROOTFS`` variable is an optional variable used with the
6169 :ref:`image-live <ref-classes-image-live>` class.
6170
Andrew Geisslerf0343792020-11-18 10:42:21 -06006171 :term:`ROOTFS_POSTINSTALL_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006172 Specifies a list of functions to call after the OpenEmbedded build
6173 system has installed packages. You can specify functions separated by
6174 semicolons:
6175 ::
6176
6177 ROOTFS_POSTINSTALL_COMMAND += "function; ... "
6178
6179 If you need to pass the root filesystem path to a command within a
6180 function, you can use ``${IMAGE_ROOTFS}``, which points to the
6181 directory that becomes the root filesystem image. See the
6182 :term:`IMAGE_ROOTFS` variable for more
6183 information.
6184
Andrew Geisslerf0343792020-11-18 10:42:21 -06006185 :term:`ROOTFS_POSTPROCESS_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006186 Specifies a list of functions to call once the OpenEmbedded build
6187 system has created the root filesystem. You can specify functions
6188 separated by semicolons:
6189 ::
6190
6191 ROOTFS_POSTPROCESS_COMMAND += "function; ... "
6192
6193 If you need to pass the root filesystem path to a command within a
6194 function, you can use ``${IMAGE_ROOTFS}``, which points to the
6195 directory that becomes the root filesystem image. See the
6196 :term:`IMAGE_ROOTFS` variable for more
6197 information.
6198
Andrew Geisslerf0343792020-11-18 10:42:21 -06006199 :term:`ROOTFS_POSTUNINSTALL_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006200 Specifies a list of functions to call after the OpenEmbedded build
6201 system has removed unnecessary packages. When runtime package
6202 management is disabled in the image, several packages are removed
6203 including ``base-passwd``, ``shadow``, and ``update-alternatives``.
6204 You can specify functions separated by semicolons:
6205 ::
6206
6207 ROOTFS_POSTUNINSTALL_COMMAND += "function; ... "
6208
6209 If you need to pass the root filesystem path to a command within a
6210 function, you can use ``${IMAGE_ROOTFS}``, which points to the
6211 directory that becomes the root filesystem image. See the
6212 :term:`IMAGE_ROOTFS` variable for more
6213 information.
6214
Andrew Geisslerf0343792020-11-18 10:42:21 -06006215 :term:`ROOTFS_PREPROCESS_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006216 Specifies a list of functions to call before the OpenEmbedded build
6217 system has created the root filesystem. You can specify functions
6218 separated by semicolons:
6219 ::
6220
6221 ROOTFS_PREPROCESS_COMMAND += "function; ... "
6222
6223 If you need to pass the root filesystem path to a command within a
6224 function, you can use ``${IMAGE_ROOTFS}``, which points to the
6225 directory that becomes the root filesystem image. See the
6226 :term:`IMAGE_ROOTFS` variable for more
6227 information.
6228
Andrew Geisslerf0343792020-11-18 10:42:21 -06006229 :term:`RPROVIDES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006230 A list of package name aliases that a package also provides. These
6231 aliases are useful for satisfying runtime dependencies of other
6232 packages both during the build and on the target (as specified by
6233 ``RDEPENDS``).
6234
6235 .. note::
6236
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006237 A package's own name is implicitly already in its ``RPROVIDES`` list.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006238
6239 As with all package-controlling variables, you must always use the
6240 variable in conjunction with a package name override. Here is an
6241 example:
6242 ::
6243
6244 RPROVIDES_${PN} = "widget-abi-2"
6245
Andrew Geisslerf0343792020-11-18 10:42:21 -06006246 :term:`RRECOMMENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006247 A list of packages that extends the usability of a package being
6248 built. The package being built does not depend on this list of
6249 packages in order to successfully build, but rather uses them for
6250 extended usability. To specify runtime dependencies for packages, see
6251 the ``RDEPENDS`` variable.
6252
6253 The package manager will automatically install the ``RRECOMMENDS``
6254 list of packages when installing the built package. However, you can
6255 prevent listed packages from being installed by using the
6256 :term:`BAD_RECOMMENDATIONS`,
6257 :term:`NO_RECOMMENDATIONS`, and
6258 :term:`PACKAGE_EXCLUDE` variables.
6259
6260 Packages specified in ``RRECOMMENDS`` need not actually be produced.
6261 However, a recipe must exist that provides each package, either
6262 through the :term:`PACKAGES` or
6263 :term:`PACKAGES_DYNAMIC` variables or the
6264 :term:`RPROVIDES` variable, or an error will occur
6265 during the build. If such a recipe does exist and the package is not
6266 produced, the build continues without error.
6267
6268 Because the ``RRECOMMENDS`` variable applies to packages being built,
6269 you should always attach an override to the variable to specify the
6270 particular package whose usability is being extended. For example,
6271 suppose you are building a development package that is extended to
6272 support wireless functionality. In this case, you would use the
6273 following:
6274 ::
6275
6276 RRECOMMENDS_${PN}-dev += "wireless_package_name"
6277
6278 In the
6279 example, the package name (``${PN}-dev``) must appear as it would in
6280 the ``PACKAGES`` namespace before any renaming of the output package
6281 by classes such as ``debian.bbclass``.
6282
6283 BitBake, which the OpenEmbedded build system uses, supports
6284 specifying versioned recommends. Although the syntax varies depending
6285 on the packaging format, BitBake hides these differences from you.
6286 Here is the general syntax to specify versions with the
6287 ``RRECOMMENDS`` variable:
6288 ::
6289
6290 RRECOMMENDS_${PN} = "package (operator version)"
6291
6292 For ``operator``, you can specify the following:
6293
6294 - =
6295 - <
6296 - >
6297 - <=
6298 - >=
6299
6300 For example, the following sets up a recommend on version 1.2 or
6301 greater of the package ``foo``:
6302 ::
6303
6304 RRECOMMENDS_${PN} = "foo (>= 1.2)"
6305
Andrew Geisslerf0343792020-11-18 10:42:21 -06006306 :term:`RREPLACES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006307 A list of packages replaced by a package. The package manager uses
6308 this variable to determine which package should be installed to
6309 replace other package(s) during an upgrade. In order to also have the
6310 other package(s) removed at the same time, you must add the name of
6311 the other package to the ``RCONFLICTS`` variable.
6312
6313 As with all package-controlling variables, you must use this variable
6314 in conjunction with a package name override. Here is an example:
6315 ::
6316
6317 RREPLACES_${PN} = "other_package_being_replaced"
6318
6319 BitBake, which the OpenEmbedded build system uses, supports
6320 specifying versioned replacements. Although the syntax varies
6321 depending on the packaging format, BitBake hides these differences
6322 from you. Here is the general syntax to specify versions with the
6323 ``RREPLACES`` variable:
6324 ::
6325
6326 RREPLACES_${PN} = "package (operator version)"
6327
6328 For ``operator``, you can specify the following:
6329
6330 - =
6331 - <
6332 - >
6333 - <=
6334 - >=
6335
6336 For example, the following sets up a replacement using version 1.2
6337 or greater of the package ``foo``:
6338 ::
6339
6340 RREPLACES_${PN} = "foo (>= 1.2)"
6341
Andrew Geisslerf0343792020-11-18 10:42:21 -06006342 :term:`RSUGGESTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006343 A list of additional packages that you can suggest for installation
6344 by the package manager at the time a package is installed. Not all
6345 package managers support this functionality.
6346
6347 As with all package-controlling variables, you must always use this
6348 variable in conjunction with a package name override. Here is an
6349 example:
6350 ::
6351
6352 RSUGGESTS_${PN} = "useful_package another_package"
6353
Andrew Geisslerf0343792020-11-18 10:42:21 -06006354 :term:`S`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006355 The location in the :term:`Build Directory` where
6356 unpacked recipe source code resides. By default, this directory is
6357 ``${``\ :term:`WORKDIR`\ ``}/${``\ :term:`BPN`\ ``}-${``\ :term:`PV`\ ``}``,
6358 where ``${BPN}`` is the base recipe name and ``${PV}`` is the recipe
6359 version. If the source tarball extracts the code to a directory named
6360 anything other than ``${BPN}-${PV}``, or if the source code is
6361 fetched from an SCM such as Git or Subversion, then you must set
6362 ``S`` in the recipe so that the OpenEmbedded build system knows where
6363 to find the unpacked source.
6364
6365 As an example, assume a :term:`Source Directory`
6366 top-level folder named ``poky`` and a default Build Directory at
6367 ``poky/build``. In this case, the work directory the build system
6368 uses to keep the unpacked recipe for ``db`` is the following:
6369 ::
6370
6371 poky/build/tmp/work/qemux86-poky-linux/db/5.1.19-r3/db-5.1.19
6372
6373 The unpacked source code resides in the ``db-5.1.19`` folder.
6374
6375 This next example assumes a Git repository. By default, Git
6376 repositories are cloned to ``${WORKDIR}/git`` during
6377 :ref:`ref-tasks-fetch`. Since this path is different
6378 from the default value of ``S``, you must set it specifically so the
6379 source can be located:
6380 ::
6381
6382 SRC_URI = "git://path/to/repo.git"
6383 S = "${WORKDIR}/git"
6384
Andrew Geisslerf0343792020-11-18 10:42:21 -06006385 :term:`SANITY_REQUIRED_UTILITIES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006386 Specifies a list of command-line utilities that should be checked for
6387 during the initial sanity checking process when running BitBake. If
6388 any of the utilities are not installed on the build host, then
6389 BitBake immediately exits with an error.
6390
Andrew Geisslerf0343792020-11-18 10:42:21 -06006391 :term:`SANITY_TESTED_DISTROS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006392 A list of the host distribution identifiers that the build system has
6393 been tested against. Identifiers consist of the host distributor ID
6394 followed by the release, as reported by the ``lsb_release`` tool or
6395 as read from ``/etc/lsb-release``. Separate the list items with
6396 explicit newline characters (``\n``). If ``SANITY_TESTED_DISTROS`` is
6397 not empty and the current value of
6398 :term:`NATIVELSBSTRING` does not appear in the
6399 list, then the build system reports a warning that indicates the
6400 current host distribution has not been tested as a build host.
6401
Andrew Geisslerf0343792020-11-18 10:42:21 -06006402 :term:`SDK_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006403 The target architecture for the SDK. Typically, you do not directly
6404 set this variable. Instead, use :term:`SDKMACHINE`.
6405
Andrew Geisslerf0343792020-11-18 10:42:21 -06006406 :term:`SDK_DEPLOY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006407 The directory set up and used by the
6408 :ref:`populate_sdk_base <ref-classes-populate-sdk>` class to which
6409 the SDK is deployed. The ``populate_sdk_base`` class defines
6410 ``SDK_DEPLOY`` as follows:
6411 ::
6412
6413 SDK_DEPLOY = "${TMPDIR}/deploy/sdk"
6414
Andrew Geisslerf0343792020-11-18 10:42:21 -06006415 :term:`SDK_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006416 The parent directory used by the OpenEmbedded build system when
6417 creating SDK output. The
6418 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class defines
6419 the variable as follows:
6420 ::
6421
6422 SDK_DIR = "${WORKDIR}/sdk"
6423
6424 .. note::
6425
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006426 The ``SDK_DIR`` directory is a temporary directory as it is part of
6427 ``WORKDIR``. The final output directory is :term:`SDK_DEPLOY`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006428
Andrew Geisslerf0343792020-11-18 10:42:21 -06006429 :term:`SDK_EXT_TYPE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006430 Controls whether or not shared state artifacts are copied into the
6431 extensible SDK. The default value of "full" copies all of the
6432 required shared state artifacts into the extensible SDK. The value
6433 "minimal" leaves these artifacts out of the SDK.
6434
6435 .. note::
6436
6437 If you set the variable to "minimal", you need to ensure
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006438 :term:`SSTATE_MIRRORS` is set in the SDK's configuration to enable the
6439 artifacts to be fetched as needed.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006440
Andrew Geisslerf0343792020-11-18 10:42:21 -06006441 :term:`SDK_HOST_MANIFEST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006442 The manifest file for the host part of the SDK. This file lists all
6443 the installed packages that make up the host part of the SDK. The
6444 file contains package information on a line-per-package basis as
6445 follows:
6446 ::
6447
6448 packagename packagearch version
6449
6450 The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class
6451 defines the manifest file as follows:
6452 ::
6453
6454 SDK_HOST_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.host.manifest"
6455
6456 The location is derived using the :term:`SDK_DEPLOY` and
6457 :term:`TOOLCHAIN_OUTPUTNAME` variables.
6458
Andrew Geisslerf0343792020-11-18 10:42:21 -06006459 :term:`SDK_INCLUDE_PKGDATA`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006460 When set to "1", specifies to include the packagedata for all recipes
6461 in the "world" target in the extensible SDK. Including this data
6462 allows the ``devtool search`` command to find these recipes in search
6463 results, as well as allows the ``devtool add`` command to map
6464 dependencies more effectively.
6465
6466 .. note::
6467
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006468 Enabling the ``SDK_INCLUDE_PKGDATA``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006469 variable significantly increases build time because all of world
6470 needs to be built. Enabling the variable also slightly increases
6471 the size of the extensible SDK.
6472
Andrew Geisslerf0343792020-11-18 10:42:21 -06006473 :term:`SDK_INCLUDE_TOOLCHAIN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006474 When set to "1", specifies to include the toolchain in the extensible
6475 SDK. Including the toolchain is useful particularly when
6476 :term:`SDK_EXT_TYPE` is set to "minimal" to keep
6477 the SDK reasonably small but you still want to provide a usable
6478 toolchain. For example, suppose you want to use the toolchain from an
6479 IDE or from other tools and you do not want to perform additional
6480 steps to install the toolchain.
6481
6482 The ``SDK_INCLUDE_TOOLCHAIN`` variable defaults to "0" if
6483 ``SDK_EXT_TYPE`` is set to "minimal", and defaults to "1" if
6484 ``SDK_EXT_TYPE`` is set to "full".
6485
Andrew Geisslerf0343792020-11-18 10:42:21 -06006486 :term:`SDK_INHERIT_BLACKLIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006487 A list of classes to remove from the :term:`INHERIT`
6488 value globally within the extensible SDK configuration. The
6489 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class sets the
6490 default value:
6491 ::
6492
6493 SDK_INHERIT_BLACKLIST ?= "buildhistory icecc"
6494
6495 Some classes are not generally applicable within the extensible SDK
6496 context. You can use this variable to disable those classes.
6497
6498 For additional information on how to customize the extensible SDK's
6499 configuration, see the
6500 ":ref:`sdk-manual/sdk-appendix-customizing:configuring the extensible sdk`"
6501 section in the Yocto Project Application Development and the
6502 Extensible Software Development Kit (eSDK) manual.
6503
Andrew Geisslerf0343792020-11-18 10:42:21 -06006504 :term:`SDK_LOCAL_CONF_BLACKLIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006505 A list of variables not allowed through from the OpenEmbedded build
6506 system configuration into the extensible SDK configuration. Usually,
6507 these are variables that are specific to the machine on which the
6508 build system is running and thus would be potentially problematic
6509 within the extensible SDK.
6510
6511 By default, ``SDK_LOCAL_CONF_BLACKLIST`` is set in the
6512 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class and
6513 excludes the following variables:
6514
6515 - :term:`CONF_VERSION`
6516 - :term:`BB_NUMBER_THREADS`
6517 - :term:`bitbake:BB_NUMBER_PARSE_THREADS`
6518 - :term:`PARALLEL_MAKE`
6519 - :term:`PRSERV_HOST`
6520 - :term:`SSTATE_MIRRORS` :term:`DL_DIR`
6521 - :term:`SSTATE_DIR` :term:`TMPDIR`
6522 - :term:`BB_SERVER_TIMEOUT`
6523
6524 For additional information on how to customize the extensible SDK's
6525 configuration, see the
6526 ":ref:`sdk-manual/sdk-appendix-customizing:configuring the extensible sdk`"
6527 section in the Yocto Project Application Development and the
6528 Extensible Software Development Kit (eSDK) manual.
6529
Andrew Geisslerf0343792020-11-18 10:42:21 -06006530 :term:`SDK_LOCAL_CONF_WHITELIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006531 A list of variables allowed through from the OpenEmbedded build
6532 system configuration into the extensible SDK configuration. By
6533 default, the list of variables is empty and is set in the
6534 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class.
6535
6536 This list overrides the variables specified using the
6537 :term:`SDK_LOCAL_CONF_BLACKLIST`
6538 variable as well as any variables identified by automatic
6539 blacklisting due to the "/" character being found at the start of the
6540 value, which is usually indicative of being a path and thus might not
6541 be valid on the system where the SDK is installed.
6542
6543 For additional information on how to customize the extensible SDK's
6544 configuration, see the
6545 ":ref:`sdk-manual/sdk-appendix-customizing:configuring the extensible sdk`"
6546 section in the Yocto Project Application Development and the
6547 Extensible Software Development Kit (eSDK) manual.
6548
Andrew Geisslerf0343792020-11-18 10:42:21 -06006549 :term:`SDK_NAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006550 The base name for SDK output files. The name is derived from the
6551 :term:`DISTRO`, :term:`TCLIBC`,
6552 :term:`SDK_ARCH`,
6553 :term:`IMAGE_BASENAME`, and
6554 :term:`TUNE_PKGARCH` variables:
6555 ::
6556
6557 SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}"
6558
Andrew Geisslerf0343792020-11-18 10:42:21 -06006559 :term:`SDK_OS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006560 Specifies the operating system for which the SDK will be built. The
6561 default value is the value of :term:`BUILD_OS`.
6562
Andrew Geisslerf0343792020-11-18 10:42:21 -06006563 :term:`SDK_OUTPUT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006564 The location used by the OpenEmbedded build system when creating SDK
6565 output. The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>`
6566 class defines the variable as follows:
6567 ::
6568
6569 SDK_DIR = "${WORKDIR}/sdk"
6570 SDK_OUTPUT = "${SDK_DIR}/image"
6571 SDK_DEPLOY = "${DEPLOY_DIR}/sdk"
6572
6573 .. note::
6574
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006575 The ``SDK_OUTPUT`` directory is a temporary directory as it is part of
6576 :term:`WORKDIR` by way of :term:`SDK_DIR`. The final output directory is
6577 :term:`SDK_DEPLOY`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006578
Andrew Geisslerf0343792020-11-18 10:42:21 -06006579 :term:`SDK_PACKAGE_ARCHS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006580 Specifies a list of architectures compatible with the SDK machine.
6581 This variable is set automatically and should not normally be
6582 hand-edited. Entries are separated using spaces and listed in order
6583 of priority. The default value for ``SDK_PACKAGE_ARCHS`` is "all any
6584 noarch ${SDK_ARCH}-${SDKPKGSUFFIX}".
6585
Andrew Geisslerf0343792020-11-18 10:42:21 -06006586 :term:`SDK_POSTPROCESS_COMMAND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006587 Specifies a list of functions to call once the OpenEmbedded build
6588 system creates the SDK. You can specify functions separated by
6589 semicolons: SDK_POSTPROCESS_COMMAND += "function; ... "
6590
6591 If you need to pass an SDK path to a command within a function, you
6592 can use ``${SDK_DIR}``, which points to the parent directory used by
6593 the OpenEmbedded build system when creating SDK output. See the
6594 :term:`SDK_DIR` variable for more information.
6595
Andrew Geisslerf0343792020-11-18 10:42:21 -06006596 :term:`SDK_PREFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006597 The toolchain binary prefix used for ``nativesdk`` recipes. The
6598 OpenEmbedded build system uses the ``SDK_PREFIX`` value to set the
6599 :term:`TARGET_PREFIX` when building
6600 ``nativesdk`` recipes. The default value is "${SDK_SYS}-".
6601
Andrew Geisslerf0343792020-11-18 10:42:21 -06006602 :term:`SDK_RECRDEP_TASKS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006603 A list of shared state tasks added to the extensible SDK. By default,
6604 the following tasks are added:
6605
6606 - do_populate_lic
6607 - do_package_qa
6608 - do_populate_sysroot
6609 - do_deploy
6610
6611 Despite the default value of "" for the
6612 ``SDK_RECRDEP_TASKS`` variable, the above four tasks are always added
6613 to the SDK. To specify tasks beyond these four, you need to use the
6614 ``SDK_RECRDEP_TASKS`` variable (e.g. you are defining additional
6615 tasks that are needed in order to build
6616 :term:`SDK_TARGETS`).
6617
Andrew Geisslerf0343792020-11-18 10:42:21 -06006618 :term:`SDK_SYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006619 Specifies the system, including the architecture and the operating
6620 system, for which the SDK will be built.
6621
6622 The OpenEmbedded build system automatically sets this variable based
6623 on :term:`SDK_ARCH`,
6624 :term:`SDK_VENDOR`, and
6625 :term:`SDK_OS`. You do not need to set the ``SDK_SYS``
6626 variable yourself.
6627
Andrew Geisslerf0343792020-11-18 10:42:21 -06006628 :term:`SDK_TARGET_MANIFEST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006629 The manifest file for the target part of the SDK. This file lists all
6630 the installed packages that make up the target part of the SDK. The
6631 file contains package information on a line-per-package basis as
6632 follows:
6633 ::
6634
6635 packagename packagearch version
6636
6637 The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class
6638 defines the manifest file as follows:
6639 ::
6640
6641 SDK_TARGET_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.target.manifest"
6642
6643 The location is derived using the :term:`SDK_DEPLOY` and
6644 :term:`TOOLCHAIN_OUTPUTNAME` variables.
6645
Andrew Geisslerf0343792020-11-18 10:42:21 -06006646 :term:`SDK_TARGETS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006647 A list of targets to install from shared state as part of the
6648 standard or extensible SDK installation. The default value is "${PN}"
6649 (i.e. the image from which the SDK is built).
6650
6651 The ``SDK_TARGETS`` variable is an internal variable and typically
6652 would not be changed.
6653
Andrew Geisslerf0343792020-11-18 10:42:21 -06006654 :term:`SDK_TITLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006655 The title to be printed when running the SDK installer. By default,
6656 this title is based on the :term:`DISTRO_NAME` or
6657 :term:`DISTRO` variable and is set in the
6658 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class as
6659 follows:
6660 ::
6661
6662 SDK_TITLE ??= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK"
6663
6664 For the default distribution "poky",
6665 ``SDK_TITLE`` is set to "Poky (Yocto Project Reference Distro)".
6666
6667 For information on how to change this default title, see the
6668 ":ref:`sdk-manual/sdk-appendix-customizing:changing the extensible sdk installer title`"
6669 section in the Yocto Project Application Development and the
6670 Extensible Software Development Kit (eSDK) manual.
6671
Andrew Geisslerf0343792020-11-18 10:42:21 -06006672 :term:`SDK_UPDATE_URL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006673 An optional URL for an update server for the extensible SDK. If set,
6674 the value is used as the default update server when running
6675 ``devtool sdk-update`` within the extensible SDK.
6676
Andrew Geisslerf0343792020-11-18 10:42:21 -06006677 :term:`SDK_VENDOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006678 Specifies the name of the SDK vendor.
6679
Andrew Geisslerf0343792020-11-18 10:42:21 -06006680 :term:`SDK_VERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006681 Specifies the version of the SDK. The distribution configuration file
6682 (e.g. ``/meta-poky/conf/distro/poky.conf``) defines the
6683 ``SDK_VERSION`` as follows:
6684 ::
6685
6686 SDK_VERSION = "${@d.getVar('DISTRO_VERSION').replace('snapshot-${DATE}','snapshot')}"
6687
6688 For additional information, see the
6689 :term:`DISTRO_VERSION` and
6690 :term:`DATE` variables.
6691
Andrew Geisslerf0343792020-11-18 10:42:21 -06006692 :term:`SDKEXTPATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006693 The default installation directory for the Extensible SDK. By
6694 default, this directory is based on the :term:`DISTRO`
6695 variable and is set in the
6696 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class as
6697 follows:
6698 ::
6699
6700 SDKEXTPATH ??= "~/${@d.getVar('DISTRO')}_sdk"
6701
6702 For the
6703 default distribution "poky", the ``SDKEXTPATH`` is set to "poky_sdk".
6704
6705 For information on how to change this default directory, see the
6706 ":ref:`sdk-manual/sdk-appendix-customizing:changing the default sdk installation directory`"
6707 section in the Yocto Project Application Development and the
6708 Extensible Software Development Kit (eSDK) manual.
6709
Andrew Geisslerf0343792020-11-18 10:42:21 -06006710 :term:`SDKIMAGE_FEATURES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006711 Equivalent to ``IMAGE_FEATURES``. However, this variable applies to
6712 the SDK generated from an image using the following command:
6713 ::
6714
6715 $ bitbake -c populate_sdk imagename
6716
Andrew Geisslerf0343792020-11-18 10:42:21 -06006717 :term:`SDKMACHINE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006718 The machine for which the SDK is built. In other words, the SDK is
6719 built such that it runs on the target you specify with the
6720 ``SDKMACHINE`` value. The value points to a corresponding ``.conf``
6721 file under ``conf/machine-sdk/``.
6722
6723 You can use "i686" and "x86_64" as possible values for this variable.
6724 The variable defaults to "i686" and is set in the local.conf file in
6725 the Build Directory.
6726 ::
6727
6728 SDKMACHINE ?= "i686"
6729
6730 .. note::
6731
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006732 You cannot set the ``SDKMACHINE``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006733 variable in your distribution configuration file. If you do, the
6734 configuration will not take affect.
6735
Andrew Geisslerf0343792020-11-18 10:42:21 -06006736 :term:`SDKPATH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006737 Defines the path offered to the user for installation of the SDK that
6738 is generated by the OpenEmbedded build system. The path appears as
6739 the default location for installing the SDK when you run the SDK's
6740 installation script. You can override the offered path when you run
6741 the script.
6742
Andrew Geisslerf0343792020-11-18 10:42:21 -06006743 :term:`SDKTARGETSYSROOT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006744 The full path to the sysroot used for cross-compilation within an SDK
6745 as it will be when installed into the default
6746 :term:`SDKPATH`.
6747
Andrew Geisslerf0343792020-11-18 10:42:21 -06006748 :term:`SECTION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006749 The section in which packages should be categorized. Package
6750 management utilities can make use of this variable.
6751
Andrew Geisslerf0343792020-11-18 10:42:21 -06006752 :term:`SELECTED_OPTIMIZATION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006753 Specifies the optimization flags passed to the C compiler when
6754 building for the target. The flags are passed through the default
6755 value of the :term:`TARGET_CFLAGS` variable.
6756
6757 The ``SELECTED_OPTIMIZATION`` variable takes the value of
6758 ``FULL_OPTIMIZATION`` unless ``DEBUG_BUILD`` = "1". If that is the
6759 case, the value of ``DEBUG_OPTIMIZATION`` is used.
6760
Andrew Geisslerf0343792020-11-18 10:42:21 -06006761 :term:`SERIAL_CONSOLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006762 Defines a serial console (TTY) to enable using
6763 `getty <https://en.wikipedia.org/wiki/Getty_(Unix)>`__. Provide a
6764 value that specifies the baud rate followed by the TTY device name
6765 separated by a space. You cannot specify more than one TTY device:
6766 ::
6767
6768 SERIAL_CONSOLE = "115200 ttyS0"
6769
6770 .. note::
6771
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006772 The ``SERIAL_CONSOLE`` variable is deprecated. Please use the
6773 :term:`SERIAL_CONSOLES` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006774
Andrew Geisslerf0343792020-11-18 10:42:21 -06006775 :term:`SERIAL_CONSOLES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006776 Defines a serial console (TTY) to enable using
6777 `getty <https://en.wikipedia.org/wiki/Getty_(Unix)>`__. Provide a
6778 value that specifies the baud rate followed by the TTY device name
6779 separated by a semicolon. Use spaces to separate multiple devices:
6780 ::
6781
6782 SERIAL_CONSOLES = "115200;ttyS0 115200;ttyS1"
6783
Andrew Geisslerf0343792020-11-18 10:42:21 -06006784 :term:`SERIAL_CONSOLES_CHECK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006785 Specifies serial consoles, which must be listed in
6786 :term:`SERIAL_CONSOLES`, to check against
6787 ``/proc/console`` before enabling them using getty. This variable
6788 allows aliasing in the format: <device>:<alias>. If a device was
6789 listed as "sclp_line0" in ``/dev/`` and "ttyS0" was listed in
6790 ``/proc/console``, you would do the following: ::
6791
6792 SERIAL_CONSOLES_CHECK = "slcp_line0:ttyS0"
6793
6794 This variable is currently only supported with SysVinit (i.e. not
6795 with systemd).
6796
Andrew Geisslerf0343792020-11-18 10:42:21 -06006797 :term:`SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006798 A list of recipe dependencies that should not be used to determine
6799 signatures of tasks from one recipe when they depend on tasks from
6800 another recipe. For example: ::
6801
6802 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += "intone->mplayer2"
6803
6804 In the previous example, ``intone`` depends on ``mplayer2``.
6805
6806 You can use the special token ``"*"`` on the left-hand side of the
6807 dependency to match all recipes except the one on the right-hand
6808 side. Here is an example: ::
6809
6810 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += "*->quilt-native"
6811
6812 In the previous example, all recipes except ``quilt-native`` ignore
6813 task signatures from the ``quilt-native`` recipe when determining
6814 their task signatures.
6815
6816 Use of this variable is one mechanism to remove dependencies that
6817 affect task signatures and thus force rebuilds when a recipe changes.
6818
6819 .. note::
6820
6821 If you add an inappropriate dependency for a recipe relationship,
6822 the software might break during runtime if the interface of the
6823 second recipe was changed after the first recipe had been built.
6824
Andrew Geisslerf0343792020-11-18 10:42:21 -06006825 :term:`SIGGEN_EXCLUDERECIPES_ABISAFE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006826 A list of recipes that are completely stable and will never change.
6827 The ABI for the recipes in the list are presented by output from the
6828 tasks run to build the recipe. Use of this variable is one way to
6829 remove dependencies from one recipe on another that affect task
6830 signatures and thus force rebuilds when the recipe changes.
6831
6832 .. note::
6833
6834 If you add an inappropriate variable to this list, the software
6835 might break at runtime if the interface of the recipe was changed
6836 after the other had been built.
6837
Andrew Geisslerf0343792020-11-18 10:42:21 -06006838 :term:`SITEINFO_BITS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006839 Specifies the number of bits for the target system CPU. The value
6840 should be either "32" or "64".
6841
Andrew Geisslerf0343792020-11-18 10:42:21 -06006842 :term:`SITEINFO_ENDIANNESS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006843 Specifies the endian byte order of the target system. The value
6844 should be either "le" for little-endian or "be" for big-endian.
6845
Andrew Geisslerf0343792020-11-18 10:42:21 -06006846 :term:`SKIP_FILEDEPS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006847 Enables removal of all files from the "Provides" section of an RPM
6848 package. Removal of these files is required for packages containing
6849 prebuilt binaries and libraries such as ``libstdc++`` and ``glibc``.
6850
6851 To enable file removal, set the variable to "1" in your
6852 ``conf/local.conf`` configuration file in your:
6853 :term:`Build Directory`.
6854 ::
6855
6856 SKIP_FILEDEPS = "1"
6857
Andrew Geisslerf0343792020-11-18 10:42:21 -06006858 :term:`SOC_FAMILY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006859 Groups together machines based upon the same family of SOC (System On
6860 Chip). You typically set this variable in a common ``.inc`` file that
6861 you include in the configuration files of all the machines.
6862
6863 .. note::
6864
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006865 You must include ``conf/machine/include/soc-family.inc`` for this
6866 variable to appear in :term:`MACHINEOVERRIDES`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006867
Andrew Geisslerf0343792020-11-18 10:42:21 -06006868 :term:`SOLIBS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006869 Defines the suffix for shared libraries used on the target platform.
6870 By default, this suffix is ".so.*" for all Linux-based systems and is
6871 defined in the ``meta/conf/bitbake.conf`` configuration file.
6872
6873 You will see this variable referenced in the default values of
6874 ``FILES_${PN}``.
6875
Andrew Geisslerf0343792020-11-18 10:42:21 -06006876 :term:`SOLIBSDEV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006877 Defines the suffix for the development symbolic link (symlink) for
6878 shared libraries on the target platform. By default, this suffix is
6879 ".so" for Linux-based systems and is defined in the
6880 ``meta/conf/bitbake.conf`` configuration file.
6881
6882 You will see this variable referenced in the default values of
6883 ``FILES_${PN}-dev``.
6884
Andrew Geisslerf0343792020-11-18 10:42:21 -06006885 :term:`SOURCE_MIRROR_FETCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006886 When you are fetching files to create a mirror of sources (i.e.
6887 creating a source mirror), setting ``SOURCE_MIRROR_FETCH`` to "1" in
6888 your ``local.conf`` configuration file ensures the source for all
6889 recipes are fetched regardless of whether or not a recipe is
6890 compatible with the configuration. A recipe is considered
6891 incompatible with the currently configured machine when either or
6892 both the :term:`COMPATIBLE_MACHINE`
6893 variable and :term:`COMPATIBLE_HOST` variables
6894 specify compatibility with a machine other than that of the current
6895 machine or host.
6896
6897 .. note::
6898
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006899 Do not set the ``SOURCE_MIRROR_FETCH``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006900 variable unless you are creating a source mirror. In other words,
6901 do not set the variable during a normal build.
6902
Andrew Geisslerf0343792020-11-18 10:42:21 -06006903 :term:`SOURCE_MIRROR_URL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006904 Defines your own :term:`PREMIRRORS` from which to
6905 first fetch source before attempting to fetch from the upstream
6906 specified in :term:`SRC_URI`.
6907
6908 To use this variable, you must globally inherit the
6909 :ref:`own-mirrors <ref-classes-own-mirrors>` class and then provide
6910 the URL to your mirrors. Here is the general syntax:
6911 ::
6912
6913 INHERIT += "own-mirrors"
6914 SOURCE_MIRROR_URL = "http://example.com/my_source_mirror"
6915
6916 .. note::
6917
Andrew Geissler4c19ea12020-10-27 13:52:24 -05006918 You can specify only a single URL in ``SOURCE_MIRROR_URL``.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006919
Andrew Geisslerf0343792020-11-18 10:42:21 -06006920 :term:`SPDXLICENSEMAP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006921 Maps commonly used license names to their SPDX counterparts found in
6922 ``meta/files/common-licenses/``. For the default ``SPDXLICENSEMAP``
6923 mappings, see the ``meta/conf/licenses.conf`` file.
6924
6925 For additional information, see the :term:`LICENSE`
6926 variable.
6927
Andrew Geisslerf0343792020-11-18 10:42:21 -06006928 :term:`SPECIAL_PKGSUFFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006929 A list of prefixes for :term:`PN` used by the OpenEmbedded
6930 build system to create variants of recipes or packages. The list
6931 specifies the prefixes to strip off during certain circumstances such
6932 as the generation of the :term:`BPN` variable.
6933
Andrew Geisslerf0343792020-11-18 10:42:21 -06006934 :term:`SPL_BINARY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006935 The file type for the Secondary Program Loader (SPL). Some devices
6936 use an SPL from which to boot (e.g. the BeagleBone development
6937 board). For such cases, you can declare the file type of the SPL
6938 binary in the ``u-boot.inc`` include file, which is used in the
6939 U-Boot recipe.
6940
6941 The SPL file type is set to "null" by default in the ``u-boot.inc``
6942 file as follows:
6943 ::
6944
6945 # Some versions of u-boot build an SPL (Second Program Loader) image that
6946 # should be packaged along with the u-boot binary as well as placed in the
6947 # deploy directory. For those versions they can set the following variables
6948 # to allow packaging the SPL.
6949 SPL_BINARY ?= ""
6950 SPL_BINARYNAME ?= "${@os.path.basename(d.getVar("SPL_BINARY"))}"
6951 SPL_IMAGE ?= "${SPL_BINARYNAME}-${MACHINE}-${PV}-${PR}"
6952 SPL_SYMLINK ?= "${SPL_BINARYNAME}-${MACHINE}"
6953
6954 The ``SPL_BINARY`` variable helps form
6955 various ``SPL_*`` variables used by the OpenEmbedded build system.
6956
6957 See the BeagleBone machine configuration example in the
6958 ":ref:`dev-manual/dev-manual-common-tasks:adding a layer using the \`\`bitbake-layers\`\` script`"
6959 section in the Yocto Project Board Support Package Developer's Guide
6960 for additional information.
6961
Andrew Geisslerf0343792020-11-18 10:42:21 -06006962 :term:`SRC_URI`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05006963 The list of source files - local or remote. This variable tells the
6964 OpenEmbedded build system which bits to pull in for the build and how
6965 to pull them in. For example, if the recipe or append file only needs
6966 to fetch a tarball from the Internet, the recipe or append file uses
6967 a single ``SRC_URI`` entry. On the other hand, if the recipe or
6968 append file needs to fetch a tarball, apply two patches, and include
6969 a custom file, the recipe or append file would include four instances
6970 of the variable.
6971
6972 The following list explains the available URI protocols. URI
6973 protocols are highly dependent on particular BitBake Fetcher
6974 submodules. Depending on the fetcher BitBake uses, various URL
6975 parameters are employed. For specifics on the supported Fetchers, see
6976 the ":ref:`Fetchers <bitbake:bb-fetchers>`" section in the
6977 BitBake User Manual.
6978
6979 - ``file://`` - Fetches files, which are usually files shipped
6980 with the :term:`Metadata`, from the local machine (e.g.
6981 :ref:`patch <patching-dev-environment>` files).
6982 The path is relative to the :term:`FILESPATH`
6983 variable. Thus, the build system searches, in order, from the
6984 following directories, which are assumed to be a subdirectories of
6985 the directory in which the recipe file (``.bb``) or append file
6986 (``.bbappend``) resides:
6987
6988 - ``${BPN}`` - The base recipe name without any special suffix
6989 or version numbers.
6990
6991 - ``${BP}`` - ``${BPN}-${PV}``. The base recipe name and
6992 version but without any special package name suffix.
6993
6994 - *files -* Files within a directory, which is named ``files``
6995 and is also alongside the recipe or append file.
6996
6997 .. note::
6998
6999 If you want the build system to pick up files specified through
7000 a
7001 SRC_URI
7002 statement from your append file, you need to be sure to extend
7003 the
7004 FILESPATH
7005 variable by also using the
7006 FILESEXTRAPATHS
7007 variable from within your append file.
7008
7009 - ``bzr://`` - Fetches files from a Bazaar revision control
7010 repository.
7011
7012 - ``git://`` - Fetches files from a Git revision control
7013 repository.
7014
7015 - ``osc://`` - Fetches files from an OSC (OpenSUSE Build service)
7016 revision control repository.
7017
7018 - ``repo://`` - Fetches files from a repo (Git) repository.
7019
7020 - ``ccrc://`` - Fetches files from a ClearCase repository.
7021
7022 - ``http://`` - Fetches files from the Internet using ``http``.
7023
7024 - ``https://`` - Fetches files from the Internet using ``https``.
7025
7026 - ``ftp://`` - Fetches files from the Internet using ``ftp``.
7027
7028 - ``cvs://`` - Fetches files from a CVS revision control
7029 repository.
7030
7031 - ``hg://`` - Fetches files from a Mercurial (``hg``) revision
7032 control repository.
7033
7034 - ``p4://`` - Fetches files from a Perforce (``p4``) revision
7035 control repository.
7036
7037 - ``ssh://`` - Fetches files from a secure shell.
7038
7039 - ``svn://`` - Fetches files from a Subversion (``svn``) revision
7040 control repository.
7041
7042 - ``npm://`` - Fetches JavaScript modules from a registry.
7043
7044 Standard and recipe-specific options for ``SRC_URI`` exist. Here are
7045 standard options:
7046
7047 - ``apply`` - Whether to apply the patch or not. The default
7048 action is to apply the patch.
7049
7050 - ``striplevel`` - Which striplevel to use when applying the
7051 patch. The default level is 1.
7052
7053 - ``patchdir`` - Specifies the directory in which the patch should
7054 be applied. The default is ``${``\ :term:`S`\ ``}``.
7055
7056 Here are options specific to recipes building code from a revision
7057 control system:
7058
7059 - ``mindate`` - Apply the patch only if
7060 :term:`SRCDATE` is equal to or greater than
7061 ``mindate``.
7062
7063 - ``maxdate`` - Apply the patch only if ``SRCDATE`` is not later
7064 than ``maxdate``.
7065
7066 - ``minrev`` - Apply the patch only if ``SRCREV`` is equal to or
7067 greater than ``minrev``.
7068
7069 - ``maxrev`` - Apply the patch only if ``SRCREV`` is not later
7070 than ``maxrev``.
7071
7072 - ``rev`` - Apply the patch only if ``SRCREV`` is equal to
7073 ``rev``.
7074
7075 - ``notrev`` - Apply the patch only if ``SRCREV`` is not equal to
7076 ``rev``.
7077
7078 Here are some additional options worth mentioning:
7079
7080 - ``unpack`` - Controls whether or not to unpack the file if it is
7081 an archive. The default action is to unpack the file.
7082
7083 - ``destsuffix`` - Places the file (or extracts its contents) into
7084 the specified subdirectory of :term:`WORKDIR` when
7085 the Git fetcher is used.
7086
7087 - ``subdir`` - Places the file (or extracts its contents) into the
7088 specified subdirectory of ``WORKDIR`` when the local (``file://``)
7089 fetcher is used.
7090
7091 - ``localdir`` - Places the file (or extracts its contents) into
7092 the specified subdirectory of ``WORKDIR`` when the CVS fetcher is
7093 used.
7094
7095 - ``subpath`` - Limits the checkout to a specific subpath of the
7096 tree when using the Git fetcher is used.
7097
7098 - ``name`` - Specifies a name to be used for association with
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007099 ``SRC_URI`` checksums or :term:`SRCREV` when you have more than one
7100 file or git repository specified in ``SRC_URI``. For example:
7101 ::
7102
7103 SRC_URI = "git://example.com/foo.git;name=first \
7104 git://example.com/bar.git;name=second \
7105 http://example.com/file.tar.gz;name=third"
7106
7107 SRCREV_first = "f1d2d2f924e986ac86fdf7b36c94bcdf32beec15"
7108 SRCREV_second = "e242ed3bffccdf271b7fbaf34ed72d089537b42f"
7109 SRC_URI[third.sha256sum] = "13550350a8681c84c861aac2e5b440161c2b33a3e4f302ac680ca5b686de48de"
7110
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007111
7112 - ``downloadfilename`` - Specifies the filename used when storing
7113 the downloaded file.
7114
Andrew Geisslerf0343792020-11-18 10:42:21 -06007115 :term:`SRC_URI_OVERRIDES_PACKAGE_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007116 By default, the OpenEmbedded build system automatically detects
7117 whether ``SRC_URI`` contains files that are machine-specific. If so,
7118 the build system automatically changes ``PACKAGE_ARCH``. Setting this
7119 variable to "0" disables this behavior.
7120
Andrew Geisslerf0343792020-11-18 10:42:21 -06007121 :term:`SRCDATE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007122 The date of the source code used to build the package. This variable
7123 applies only if the source was fetched from a Source Code Manager
7124 (SCM).
7125
Andrew Geisslerf0343792020-11-18 10:42:21 -06007126 :term:`SRCPV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007127 Returns the version string of the current package. This string is
7128 used to help define the value of :term:`PV`.
7129
7130 The ``SRCPV`` variable is defined in the ``meta/conf/bitbake.conf``
7131 configuration file in the :term:`Source Directory` as
7132 follows:
7133 ::
7134
7135 SRCPV = "${@bb.fetch2.get_srcrev(d)}"
7136
7137 Recipes that need to define ``PV`` do so with the help of the
7138 ``SRCPV``. For example, the ``ofono`` recipe (``ofono_git.bb``)
7139 located in ``meta/recipes-connectivity`` in the Source Directory
7140 defines ``PV`` as follows:
7141 ::
7142
7143 PV = "0.12-git${SRCPV}"
7144
Andrew Geisslerf0343792020-11-18 10:42:21 -06007145 :term:`SRCREV`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007146 The revision of the source code used to build the package. This
7147 variable applies to Subversion, Git, Mercurial, and Bazaar only. Note
7148 that if you want to build a fixed revision and you want to avoid
7149 performing a query on the remote repository every time BitBake parses
7150 your recipe, you should specify a ``SRCREV`` that is a full revision
7151 identifier and not just a tag.
7152
7153 .. note::
7154
7155 For information on limitations when inheriting the latest revision
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007156 of software using ``SRCREV``, see the :term:`AUTOREV` variable
7157 description and the
7158 ":ref:`automatically-incrementing-a-binary-package-revision-number`"
7159 section, which is in the Yocto Project Development Tasks Manual.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007160
Andrew Geisslerf0343792020-11-18 10:42:21 -06007161 :term:`SSTATE_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007162 The directory for the shared state cache.
7163
Andrew Geisslerf0343792020-11-18 10:42:21 -06007164 :term:`SSTATE_MIRROR_ALLOW_NETWORK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007165 If set to "1", allows fetches from mirrors that are specified in
7166 :term:`SSTATE_MIRRORS` to work even when
7167 fetching from the network is disabled by setting ``BB_NO_NETWORK`` to
7168 "1". Using the ``SSTATE_MIRROR_ALLOW_NETWORK`` variable is useful if
7169 you have set ``SSTATE_MIRRORS`` to point to an internal server for
7170 your shared state cache, but you want to disable any other fetching
7171 from the network.
7172
Andrew Geisslerf0343792020-11-18 10:42:21 -06007173 :term:`SSTATE_MIRRORS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007174 Configures the OpenEmbedded build system to search other mirror
7175 locations for prebuilt cache data objects before building out the
7176 data. This variable works like fetcher :term:`MIRRORS`
7177 and :term:`PREMIRRORS` and points to the cache
7178 locations to check for the shared state (sstate) objects.
7179
7180 You can specify a filesystem directory or a remote URL such as HTTP
7181 or FTP. The locations you specify need to contain the shared state
7182 cache (sstate-cache) results from previous builds. The sstate-cache
7183 you point to can also be from builds on other machines.
7184
7185 When pointing to sstate build artifacts on another machine that uses
7186 a different GCC version for native builds, you must configure
7187 ``SSTATE_MIRRORS`` with a regular expression that maps local search
7188 paths to server paths. The paths need to take into account
7189 :term:`NATIVELSBSTRING` set by the
7190 :ref:`uninative <ref-classes-uninative>` class. For example, the
7191 following maps the local search path ``universal-4.9`` to the
7192 server-provided path server_url_sstate_path:
7193 ::
7194
7195 SSTATE_MIRRORS ?= "file://universal-4.9/(.*) http://server_url_sstate_path/universal-4.8/\1 \n"
7196
7197 If a mirror uses the same structure as
7198 :term:`SSTATE_DIR`, you need to add "PATH" at the
7199 end as shown in the examples below. The build system substitutes the
7200 correct path within the directory structure.
7201 ::
7202
7203 SSTATE_MIRRORS ?= "\
7204 file://.* http://someserver.tld/share/sstate/PATH;downloadfilename=PATH \n \
7205 file://.* file:///some-local-dir/sstate/PATH"
7206
Andrew Geisslerf0343792020-11-18 10:42:21 -06007207 :term:`SSTATE_SCAN_FILES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007208 Controls the list of files the OpenEmbedded build system scans for
7209 hardcoded installation paths. The variable uses a space-separated
7210 list of filenames (not paths) with standard wildcard characters
7211 allowed.
7212
7213 During a build, the OpenEmbedded build system creates a shared state
7214 (sstate) object during the first stage of preparing the sysroots.
7215 That object is scanned for hardcoded paths for original installation
7216 locations. The list of files that are scanned for paths is controlled
7217 by the ``SSTATE_SCAN_FILES`` variable. Typically, recipes add files
7218 they want to be scanned to the value of ``SSTATE_SCAN_FILES`` rather
7219 than the variable being comprehensively set. The
7220 :ref:`sstate <ref-classes-sstate>` class specifies the default list
7221 of files.
7222
7223 For details on the process, see the
7224 :ref:`staging <ref-classes-staging>` class.
7225
Andrew Geisslerf0343792020-11-18 10:42:21 -06007226 :term:`STAGING_BASE_LIBDIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007227 Specifies the path to the ``/lib`` subdirectory of the sysroot
7228 directory for the build host.
7229
Andrew Geisslerf0343792020-11-18 10:42:21 -06007230 :term:`STAGING_BASELIBDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007231 Specifies the path to the ``/lib`` subdirectory of the sysroot
7232 directory for the target for which the current recipe is being built
7233 (:term:`STAGING_DIR_HOST`).
7234
Andrew Geisslerf0343792020-11-18 10:42:21 -06007235 :term:`STAGING_BINDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007236 Specifies the path to the ``/usr/bin`` subdirectory of the sysroot
7237 directory for the target for which the current recipe is being built
7238 (:term:`STAGING_DIR_HOST`).
7239
Andrew Geisslerf0343792020-11-18 10:42:21 -06007240 :term:`STAGING_BINDIR_CROSS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007241 Specifies the path to the directory containing binary configuration
7242 scripts. These scripts provide configuration information for other
7243 software that wants to make use of libraries or include files
7244 provided by the software associated with the script.
7245
7246 .. note::
7247
7248 This style of build configuration has been largely replaced by
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007249 ``pkg-config``. Consequently, if ``pkg-config`` is supported by the
7250 library to which you are linking, it is recommended you use
7251 ``pkg-config`` instead of a provided configuration script.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007252
Andrew Geisslerf0343792020-11-18 10:42:21 -06007253 :term:`STAGING_BINDIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007254 Specifies the path to the ``/usr/bin`` subdirectory of the sysroot
7255 directory for the build host.
7256
Andrew Geisslerf0343792020-11-18 10:42:21 -06007257 :term:`STAGING_DATADIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007258 Specifies the path to the ``/usr/share`` subdirectory of the sysroot
7259 directory for the target for which the current recipe is being built
7260 (:term:`STAGING_DIR_HOST`).
7261
Andrew Geisslerf0343792020-11-18 10:42:21 -06007262 :term:`STAGING_DATADIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007263 Specifies the path to the ``/usr/share`` subdirectory of the sysroot
7264 directory for the build host.
7265
Andrew Geisslerf0343792020-11-18 10:42:21 -06007266 :term:`STAGING_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007267 Helps construct the ``recipe-sysroots`` directory, which is used
7268 during packaging.
7269
7270 For information on how staging for recipe-specific sysroots occurs,
7271 see the :ref:`ref-tasks-populate_sysroot`
7272 task, the ":ref:`sdk-manual/sdk-extensible:sharing files between recipes`"
7273 section in the Yocto Project Development Tasks Manual, the
7274 ":ref:`configuration-compilation-and-staging-dev-environment`"
7275 section in the Yocto Project Overview and Concepts Manual, and the
7276 :term:`SYSROOT_DIRS` variable.
7277
7278 .. note::
7279
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007280 Recipes should never write files directly under the ``STAGING_DIR``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007281 directory because the OpenEmbedded build system manages the
7282 directory automatically. Instead, files should be installed to
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007283 ``${``\ :term:`D`\ ``}`` within your recipe's :ref:`ref-tasks-install`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007284 task and then the OpenEmbedded build system will stage a subset of
7285 those files into the sysroot.
7286
Andrew Geisslerf0343792020-11-18 10:42:21 -06007287 :term:`STAGING_DIR_HOST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007288 Specifies the path to the sysroot directory for the system on which
7289 the component is built to run (the system that hosts the component).
7290 For most recipes, this sysroot is the one in which that recipe's
7291 :ref:`ref-tasks-populate_sysroot` task copies
7292 files. Exceptions include ``-native`` recipes, where the
7293 ``do_populate_sysroot`` task instead uses
7294 :term:`STAGING_DIR_NATIVE`. Depending on
7295 the type of recipe and the build target, ``STAGING_DIR_HOST`` can
7296 have the following values:
7297
7298 - For recipes building for the target machine, the value is
7299 "${:term:`STAGING_DIR`}/${:term:`MACHINE`}".
7300
7301 - For native recipes building for the build host, the value is empty
7302 given the assumption that when building for the build host, the
7303 build host's own directories should be used.
7304
7305 .. note::
7306
7307 ``-native`` recipes are not installed into host paths like such
7308 as ``/usr``. Rather, these recipes are installed into
7309 ``STAGING_DIR_NATIVE``. When compiling ``-native`` recipes,
7310 standard build environment variables such as
7311 :term:`CPPFLAGS` and
7312 :term:`CFLAGS` are set up so that both host paths
7313 and ``STAGING_DIR_NATIVE`` are searched for libraries and
7314 headers using, for example, GCC's ``-isystem`` option.
7315
7316 Thus, the emphasis is that the ``STAGING_DIR*`` variables
7317 should be viewed as input variables by tasks such as
7318 :ref:`ref-tasks-configure`,
7319 :ref:`ref-tasks-compile`, and
7320 :ref:`ref-tasks-install`. Having the real system
7321 root correspond to ``STAGING_DIR_HOST`` makes conceptual sense
7322 for ``-native`` recipes, as they make use of host headers and
7323 libraries.
7324
Andrew Geisslerf0343792020-11-18 10:42:21 -06007325 :term:`STAGING_DIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007326 Specifies the path to the sysroot directory used when building
7327 components that run on the build host itself.
7328
Andrew Geisslerf0343792020-11-18 10:42:21 -06007329 :term:`STAGING_DIR_TARGET`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007330 Specifies the path to the sysroot used for the system for which the
7331 component generates code. For components that do not generate code,
7332 which is the majority, ``STAGING_DIR_TARGET`` is set to match
7333 :term:`STAGING_DIR_HOST`.
7334
7335 Some recipes build binaries that can run on the target system but
7336 those binaries in turn generate code for another different system
7337 (e.g. cross-canadian recipes). Using terminology from GNU, the
7338 primary system is referred to as the "HOST" and the secondary, or
7339 different, system is referred to as the "TARGET". Thus, the binaries
7340 run on the "HOST" system and generate binaries for the "TARGET"
7341 system. The ``STAGING_DIR_HOST`` variable points to the sysroot used
7342 for the "HOST" system, while ``STAGING_DIR_TARGET`` points to the
7343 sysroot used for the "TARGET" system.
7344
Andrew Geisslerf0343792020-11-18 10:42:21 -06007345 :term:`STAGING_ETCDIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007346 Specifies the path to the ``/etc`` subdirectory of the sysroot
7347 directory for the build host.
7348
Andrew Geisslerf0343792020-11-18 10:42:21 -06007349 :term:`STAGING_EXECPREFIXDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007350 Specifies the path to the ``/usr`` subdirectory of the sysroot
7351 directory for the target for which the current recipe is being built
7352 (:term:`STAGING_DIR_HOST`).
7353
Andrew Geisslerf0343792020-11-18 10:42:21 -06007354 :term:`STAGING_INCDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007355 Specifies the path to the ``/usr/include`` subdirectory of the
7356 sysroot directory for the target for which the current recipe being
7357 built (:term:`STAGING_DIR_HOST`).
7358
Andrew Geisslerf0343792020-11-18 10:42:21 -06007359 :term:`STAGING_INCDIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007360 Specifies the path to the ``/usr/include`` subdirectory of the
7361 sysroot directory for the build host.
7362
Andrew Geisslerf0343792020-11-18 10:42:21 -06007363 :term:`STAGING_KERNEL_BUILDDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007364 Points to the directory containing the kernel build artifacts.
7365 Recipes building software that needs to access kernel build artifacts
7366 (e.g. ``systemtap-uprobes``) can look in the directory specified with
7367 the ``STAGING_KERNEL_BUILDDIR`` variable to find these artifacts
7368 after the kernel has been built.
7369
Andrew Geisslerf0343792020-11-18 10:42:21 -06007370 :term:`STAGING_KERNEL_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007371 The directory with kernel headers that are required to build
7372 out-of-tree modules.
7373
Andrew Geisslerf0343792020-11-18 10:42:21 -06007374 :term:`STAGING_LIBDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007375 Specifies the path to the ``/usr/lib`` subdirectory of the sysroot
7376 directory for the target for which the current recipe is being built
7377 (:term:`STAGING_DIR_HOST`).
7378
Andrew Geisslerf0343792020-11-18 10:42:21 -06007379 :term:`STAGING_LIBDIR_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007380 Specifies the path to the ``/usr/lib`` subdirectory of the sysroot
7381 directory for the build host.
7382
Andrew Geisslerf0343792020-11-18 10:42:21 -06007383 :term:`STAMP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007384 Specifies the base path used to create recipe stamp files. The path
7385 to an actual stamp file is constructed by evaluating this string and
7386 then appending additional information. Currently, the default
7387 assignment for ``STAMP`` as set in the ``meta/conf/bitbake.conf``
7388 file is:
7389 ::
7390
7391 STAMP = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"
7392
7393 For information on how BitBake uses stamp files to determine if a
7394 task should be rerun, see the
7395 ":ref:`overview-manual/overview-manual-concepts:stamp files and the rerunning of tasks`"
7396 section in the Yocto Project Overview and Concepts Manual.
7397
7398 See :term:`STAMPS_DIR`,
7399 :term:`MULTIMACH_TARGET_SYS`,
7400 :term:`PN`, :term:`EXTENDPE`,
7401 :term:`PV`, and :term:`PR` for related variable
7402 information.
7403
Andrew Geisslerf0343792020-11-18 10:42:21 -06007404 :term:`STAMPS_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007405 Specifies the base directory in which the OpenEmbedded build system
7406 places stamps. The default directory is ``${TMPDIR}/stamps``.
7407
Andrew Geisslerf0343792020-11-18 10:42:21 -06007408 :term:`STRIP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007409 The minimal command and arguments to run ``strip``, which is used to
7410 strip symbols.
7411
Andrew Geisslerf0343792020-11-18 10:42:21 -06007412 :term:`SUMMARY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007413 The short (72 characters or less) summary of the binary package for
7414 packaging systems such as ``opkg``, ``rpm``, or ``dpkg``. By default,
7415 ``SUMMARY`` is used to define the
7416 :term:`DESCRIPTION` variable if ``DESCRIPTION`` is
7417 not set in the recipe.
7418
Andrew Geisslerf0343792020-11-18 10:42:21 -06007419 :term:`SVNDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007420 The directory in which files checked out of a Subversion system are
7421 stored.
7422
Andrew Geisslerf0343792020-11-18 10:42:21 -06007423 :term:`SYSLINUX_DEFAULT_CONSOLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007424 Specifies the kernel boot default console. If you want to use a
7425 console other than the default, set this variable in your recipe as
7426 follows where "X" is the console number you want to use:
7427 ::
7428
7429 SYSLINUX_DEFAULT_CONSOLE = "console=ttyX"
7430
7431 The :ref:`syslinux <ref-classes-syslinux>` class initially sets
7432 this variable to null but then checks for a value later.
7433
Andrew Geisslerf0343792020-11-18 10:42:21 -06007434 :term:`SYSLINUX_OPTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007435 Lists additional options to add to the syslinux file. You need to set
7436 this variable in your recipe. If you want to list multiple options,
7437 separate the options with a semicolon character (``;``).
7438
7439 The :ref:`syslinux <ref-classes-syslinux>` class uses this variable
7440 to create a set of options.
7441
Andrew Geisslerf0343792020-11-18 10:42:21 -06007442 :term:`SYSLINUX_SERIAL`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007443 Specifies the alternate serial port or turns it off. To turn off
7444 serial, set this variable to an empty string in your recipe. The
7445 variable's default value is set in the
7446 :ref:`syslinux <ref-classes-syslinux>` class as follows:
7447 ::
7448
7449 SYSLINUX_SERIAL ?= "0 115200"
7450
7451 The class checks for and uses the variable as needed.
7452
Andrew Geisslerf0343792020-11-18 10:42:21 -06007453 :term:`SYSLINUX_SERIAL_TTY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007454 Specifies the alternate console=tty... kernel boot argument. The
7455 variable's default value is set in the
7456 :ref:`syslinux <ref-classes-syslinux>` class as follows:
7457 ::
7458
7459 SYSLINUX_SERIAL_TTY ?= "console=ttyS0,115200"
7460
7461 The class checks for and uses the variable as needed.
7462
Andrew Geisslerf0343792020-11-18 10:42:21 -06007463 :term:`SYSLINUX_SPLASH`
7464 An ``.LSS`` file used as the background for the VGA boot menu when
7465 you use the boot menu. You need to set this variable in your recipe.
7466
7467 The :ref:`syslinux <ref-classes-syslinux>` class checks for this
7468 variable and if found, the OpenEmbedded build system installs the
7469 splash screen.
7470
7471 :term:`SYSROOT_DESTDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007472 Points to the temporary directory under the work directory (default
7473 "``${``\ :term:`WORKDIR`\ ``}/sysroot-destdir``")
7474 where the files populated into the sysroot are assembled during the
7475 :ref:`ref-tasks-populate_sysroot` task.
7476
Andrew Geisslerf0343792020-11-18 10:42:21 -06007477 :term:`SYSROOT_DIRS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007478 Directories that are staged into the sysroot by the
7479 :ref:`ref-tasks-populate_sysroot` task. By
7480 default, the following directories are staged:
7481 ::
7482
7483 SYSROOT_DIRS = " \
7484 ${includedir} \
7485 ${libdir} \
7486 ${base_libdir} \
7487 ${nonarch_base_libdir} \
7488 ${datadir} \
7489 "
7490
Andrew Geisslerf0343792020-11-18 10:42:21 -06007491 :term:`SYSROOT_DIRS_BLACKLIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007492 Directories that are not staged into the sysroot by the
7493 :ref:`ref-tasks-populate_sysroot` task. You
7494 can use this variable to exclude certain subdirectories of
7495 directories listed in :term:`SYSROOT_DIRS` from
7496 staging. By default, the following directories are not staged:
7497 ::
7498
7499 SYSROOT_DIRS_BLACKLIST = " \
7500 ${mandir} \
7501 ${docdir} \
7502 ${infodir} \
7503 ${datadir}/locale \
7504 ${datadir}/applications \
7505 ${datadir}/fonts \
7506 ${datadir}/pixmaps \
7507 "
7508
Andrew Geisslerf0343792020-11-18 10:42:21 -06007509 :term:`SYSROOT_DIRS_NATIVE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007510 Extra directories staged into the sysroot by the
7511 :ref:`ref-tasks-populate_sysroot` task for
7512 ``-native`` recipes, in addition to those specified in
7513 :term:`SYSROOT_DIRS`. By default, the following
7514 extra directories are staged:
7515 ::
7516
7517 SYSROOT_DIRS_NATIVE = " \
7518 ${bindir} \
7519 ${sbindir} \
7520 ${base_bindir} \
7521 ${base_sbindir} \
7522 ${libexecdir} \
7523 ${sysconfdir} \
7524 ${localstatedir} \
7525 "
7526
7527 .. note::
7528
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007529 Programs built by ``-native`` recipes run directly from the sysroot
7530 (:term:`STAGING_DIR_NATIVE`), which is why additional directories
7531 containing program executables and supporting files need to be staged.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007532
Andrew Geisslerf0343792020-11-18 10:42:21 -06007533 :term:`SYSROOT_PREPROCESS_FUNCS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007534 A list of functions to execute after files are staged into the
7535 sysroot. These functions are usually used to apply additional
7536 processing on the staged files, or to stage additional files.
7537
Andrew Geisslerf0343792020-11-18 10:42:21 -06007538 :term:`SYSTEMD_AUTO_ENABLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007539 When inheriting the :ref:`systemd <ref-classes-systemd>` class,
7540 this variable specifies whether the specified service in
7541 :term:`SYSTEMD_SERVICE` should start
7542 automatically or not. By default, the service is enabled to
7543 automatically start at boot time. The default setting is in the
7544 :ref:`systemd <ref-classes-systemd>` class as follows:
7545 ::
7546
7547 SYSTEMD_AUTO_ENABLE ??= "enable"
7548
7549 You can disable the service by setting the variable to "disable".
7550
Andrew Geisslerf0343792020-11-18 10:42:21 -06007551 :term:`SYSTEMD_BOOT_CFG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007552 When :term:`EFI_PROVIDER` is set to
7553 "systemd-boot", the ``SYSTEMD_BOOT_CFG`` variable specifies the
7554 configuration file that should be used. By default, the
7555 :ref:`systemd-boot <ref-classes-systemd-boot>` class sets the
7556 ``SYSTEMD_BOOT_CFG`` as follows:
7557 ::
7558
7559 SYSTEMD_BOOT_CFG ?= "${:term:`S`}/loader.conf"
7560
7561 For information on Systemd-boot, see the `Systemd-boot
7562 documentation <http://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__.
7563
Andrew Geisslerf0343792020-11-18 10:42:21 -06007564 :term:`SYSTEMD_BOOT_ENTRIES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007565 When :term:`EFI_PROVIDER` is set to
7566 "systemd-boot", the ``SYSTEMD_BOOT_ENTRIES`` variable specifies a
7567 list of entry files (``*.conf``) to install that contain one boot
7568 entry per file. By default, the
7569 :ref:`systemd-boot <ref-classes-systemd-boot>` class sets the
7570 ``SYSTEMD_BOOT_ENTRIES`` as follows:
7571 ::
7572
7573 SYSTEMD_BOOT_ENTRIES ?= ""
7574
7575 For information on Systemd-boot, see the `Systemd-boot
7576 documentation <http://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__.
7577
Andrew Geisslerf0343792020-11-18 10:42:21 -06007578 :term:`SYSTEMD_BOOT_TIMEOUT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007579 When :term:`EFI_PROVIDER` is set to
7580 "systemd-boot", the ``SYSTEMD_BOOT_TIMEOUT`` variable specifies the
7581 boot menu timeout in seconds. By default, the
7582 :ref:`systemd-boot <ref-classes-systemd-boot>` class sets the
7583 ``SYSTEMD_BOOT_TIMEOUT`` as follows:
7584 ::
7585
7586 SYSTEMD_BOOT_TIMEOUT ?= "10"
7587
7588 For information on Systemd-boot, see the `Systemd-boot
7589 documentation <http://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__.
7590
Andrew Geisslerf0343792020-11-18 10:42:21 -06007591 :term:`SYSTEMD_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007592 When inheriting the :ref:`systemd <ref-classes-systemd>` class,
7593 this variable locates the systemd unit files when they are not found
7594 in the main recipe's package. By default, the ``SYSTEMD_PACKAGES``
7595 variable is set such that the systemd unit files are assumed to
7596 reside in the recipes main package:
7597 ::
7598
7599 SYSTEMD_PACKAGES ?= "${PN}"
7600
7601 If these unit files are not in this recipe's main package, you need
7602 to use ``SYSTEMD_PACKAGES`` to list the package or packages in which
7603 the build system can find the systemd unit files.
7604
Andrew Geisslerf0343792020-11-18 10:42:21 -06007605 :term:`SYSTEMD_SERVICE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007606 When inheriting the :ref:`systemd <ref-classes-systemd>` class,
7607 this variable specifies the systemd service name for a package.
7608
7609 When you specify this file in your recipe, use a package name
7610 override to indicate the package to which the value applies. Here is
7611 an example from the connman recipe:
7612 ::
7613
7614 SYSTEMD_SERVICE_${PN} = "connman.service"
7615
Andrew Geisslerf0343792020-11-18 10:42:21 -06007616 :term:`SYSVINIT_ENABLED_GETTYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007617 When using
7618 :ref:`SysVinit <dev-manual/dev-manual-common-tasks:enabling system services>`,
7619 specifies a space-separated list of the virtual terminals that should
7620 run a `getty <http://en.wikipedia.org/wiki/Getty_%28Unix%29>`__
7621 (allowing login), assuming :term:`USE_VT` is not set to
7622 "0".
7623
7624 The default value for ``SYSVINIT_ENABLED_GETTYS`` is "1" (i.e. only
7625 run a getty on the first virtual terminal).
7626
Andrew Geisslerf0343792020-11-18 10:42:21 -06007627 :term:`T`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007628 This variable points to a directory were BitBake places temporary
7629 files, which consist mostly of task logs and scripts, when building a
7630 particular recipe. The variable is typically set as follows:
7631 ::
7632
7633 T = "${WORKDIR}/temp"
7634
7635 The :term:`WORKDIR` is the directory into which
7636 BitBake unpacks and builds the recipe. The default ``bitbake.conf``
7637 file sets this variable.
7638
7639 The ``T`` variable is not to be confused with the
7640 :term:`TMPDIR` variable, which points to the root of
7641 the directory tree where BitBake places the output of an entire
7642 build.
7643
Andrew Geisslerf0343792020-11-18 10:42:21 -06007644 :term:`TARGET_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007645 The target machine's architecture. The OpenEmbedded build system
7646 supports many architectures. Here is an example list of architectures
7647 supported. This list is by no means complete as the architecture is
7648 configurable:
7649
7650 - arm
7651 - i586
7652 - x86_64
7653 - powerpc
7654 - powerpc64
7655 - mips
7656 - mipsel
7657
7658 For additional information on machine architectures, see the
7659 :term:`TUNE_ARCH` variable.
7660
Andrew Geisslerf0343792020-11-18 10:42:21 -06007661 :term:`TARGET_AS_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007662 Specifies architecture-specific assembler flags for the target
7663 system. ``TARGET_AS_ARCH`` is initialized from
7664 :term:`TUNE_ASARGS` by default in the BitBake
7665 configuration file (``meta/conf/bitbake.conf``):
7666 ::
7667
7668 TARGET_AS_ARCH = "${TUNE_ASARGS}"
7669
Andrew Geisslerf0343792020-11-18 10:42:21 -06007670 :term:`TARGET_CC_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007671 Specifies architecture-specific C compiler flags for the target
7672 system. ``TARGET_CC_ARCH`` is initialized from
7673 :term:`TUNE_CCARGS` by default.
7674
7675 .. note::
7676
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007677 It is a common workaround to append :term:`LDFLAGS` to
7678 ``TARGET_CC_ARCH`` in recipes that build software for the target that
7679 would not otherwise respect the exported ``LDFLAGS`` variable.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007680
Andrew Geisslerf0343792020-11-18 10:42:21 -06007681 :term:`TARGET_CC_KERNEL_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007682 This is a specific kernel compiler flag for a CPU or Application
7683 Binary Interface (ABI) tune. The flag is used rarely and only for
7684 cases where a userspace :term:`TUNE_CCARGS` is not
7685 compatible with the kernel compilation. The ``TARGET_CC_KERNEL_ARCH``
7686 variable allows the kernel (and associated modules) to use a
7687 different configuration. See the
7688 ``meta/conf/machine/include/arm/feature-arm-thumb.inc`` file in the
7689 :term:`Source Directory` for an example.
7690
Andrew Geisslerf0343792020-11-18 10:42:21 -06007691 :term:`TARGET_CFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007692 Specifies the flags to pass to the C compiler when building for the
7693 target. When building in the target context,
7694 :term:`CFLAGS` is set to the value of this variable by
7695 default.
7696
7697 Additionally, the SDK's environment setup script sets the ``CFLAGS``
7698 variable in the environment to the ``TARGET_CFLAGS`` value so that
7699 executables built using the SDK also have the flags applied.
7700
Andrew Geisslerf0343792020-11-18 10:42:21 -06007701 :term:`TARGET_CPPFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007702 Specifies the flags to pass to the C pre-processor (i.e. to both the
7703 C and the C++ compilers) when building for the target. When building
7704 in the target context, :term:`CPPFLAGS` is set to the
7705 value of this variable by default.
7706
7707 Additionally, the SDK's environment setup script sets the
7708 ``CPPFLAGS`` variable in the environment to the ``TARGET_CPPFLAGS``
7709 value so that executables built using the SDK also have the flags
7710 applied.
7711
Andrew Geisslerf0343792020-11-18 10:42:21 -06007712 :term:`TARGET_CXXFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007713 Specifies the flags to pass to the C++ compiler when building for the
7714 target. When building in the target context,
7715 :term:`CXXFLAGS` is set to the value of this variable
7716 by default.
7717
7718 Additionally, the SDK's environment setup script sets the
7719 ``CXXFLAGS`` variable in the environment to the ``TARGET_CXXFLAGS``
7720 value so that executables built using the SDK also have the flags
7721 applied.
7722
Andrew Geisslerf0343792020-11-18 10:42:21 -06007723 :term:`TARGET_FPU`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007724 Specifies the method for handling FPU code. For FPU-less targets,
7725 which include most ARM CPUs, the variable must be set to "soft". If
7726 not, the kernel emulation gets used, which results in a performance
7727 penalty.
7728
Andrew Geisslerf0343792020-11-18 10:42:21 -06007729 :term:`TARGET_LD_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007730 Specifies architecture-specific linker flags for the target system.
7731 ``TARGET_LD_ARCH`` is initialized from
7732 :term:`TUNE_LDARGS` by default in the BitBake
7733 configuration file (``meta/conf/bitbake.conf``):
7734 ::
7735
7736 TARGET_LD_ARCH = "${TUNE_LDARGS}"
7737
Andrew Geisslerf0343792020-11-18 10:42:21 -06007738 :term:`TARGET_LDFLAGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007739 Specifies the flags to pass to the linker when building for the
7740 target. When building in the target context,
7741 :term:`LDFLAGS` is set to the value of this variable
7742 by default.
7743
7744 Additionally, the SDK's environment setup script sets the
7745 :term:`LDFLAGS` variable in the environment to the
7746 ``TARGET_LDFLAGS`` value so that executables built using the SDK also
7747 have the flags applied.
7748
Andrew Geisslerf0343792020-11-18 10:42:21 -06007749 :term:`TARGET_OS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007750 Specifies the target's operating system. The variable can be set to
7751 "linux" for glibc-based systems (GNU C Library) and to "linux-musl"
7752 for musl libc. For ARM/EABI targets, "linux-gnueabi" and
7753 "linux-musleabi" possible values exist.
7754
Andrew Geisslerf0343792020-11-18 10:42:21 -06007755 :term:`TARGET_PREFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007756 Specifies the prefix used for the toolchain binary target tools.
7757
7758 Depending on the type of recipe and the build target,
7759 ``TARGET_PREFIX`` is set as follows:
7760
7761 - For recipes building for the target machine, the value is
7762 "${:term:`TARGET_SYS`}-".
7763
7764 - For native recipes, the build system sets the variable to the
7765 value of ``BUILD_PREFIX``.
7766
7767 - For native SDK recipes (``nativesdk``), the build system sets the
7768 variable to the value of ``SDK_PREFIX``.
7769
Andrew Geisslerf0343792020-11-18 10:42:21 -06007770 :term:`TARGET_SYS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007771 Specifies the system, including the architecture and the operating
7772 system, for which the build is occurring in the context of the
7773 current recipe.
7774
7775 The OpenEmbedded build system automatically sets this variable based
7776 on :term:`TARGET_ARCH`,
7777 :term:`TARGET_VENDOR`, and
7778 :term:`TARGET_OS` variables.
7779
7780 .. note::
7781
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007782 You do not need to set the ``TARGET_SYS`` variable yourself.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007783
7784 Consider these two examples:
7785
7786 - Given a native recipe on a 32-bit, x86 machine running Linux, the
7787 value is "i686-linux".
7788
7789 - Given a recipe being built for a little-endian, MIPS target
7790 running Linux, the value might be "mipsel-linux".
7791
Andrew Geisslerf0343792020-11-18 10:42:21 -06007792 :term:`TARGET_VENDOR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007793 Specifies the name of the target vendor.
7794
Andrew Geisslerf0343792020-11-18 10:42:21 -06007795 :term:`TCLIBC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007796 Specifies the GNU standard C library (``libc``) variant to use during
7797 the build process. This variable replaces ``POKYLIBC``, which is no
7798 longer supported.
7799
7800 You can select "glibc", "musl", "newlib", or "baremetal"
7801
Andrew Geisslerf0343792020-11-18 10:42:21 -06007802 :term:`TCLIBCAPPEND`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007803 Specifies a suffix to be appended onto the
7804 :term:`TMPDIR` value. The suffix identifies the
7805 ``libc`` variant for building. When you are building for multiple
7806 variants with the same :term:`Build Directory`, this
7807 mechanism ensures that output for different ``libc`` variants is kept
7808 separate to avoid potential conflicts.
7809
7810 In the ``defaultsetup.conf`` file, the default value of
7811 ``TCLIBCAPPEND`` is "-${TCLIBC}". However, distros such as poky,
7812 which normally only support one ``libc`` variant, set
7813 ``TCLIBCAPPEND`` to "" in their distro configuration file resulting
7814 in no suffix being applied.
7815
Andrew Geisslerf0343792020-11-18 10:42:21 -06007816 :term:`TCMODE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007817 Specifies the toolchain selector. ``TCMODE`` controls the
7818 characteristics of the generated packages and images by telling the
7819 OpenEmbedded build system which toolchain profile to use. By default,
7820 the OpenEmbedded build system builds its own internal toolchain. The
7821 variable's default value is "default", which uses that internal
7822 toolchain.
7823
7824 .. note::
7825
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007826 If ``TCMODE`` is set to a value other than "default", then it is your
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007827 responsibility to ensure that the toolchain is compatible with the
7828 default toolchain. Using older or newer versions of these
7829 components might cause build problems. See the Release Notes for
7830 the Yocto Project release for the specific components with which
7831 the toolchain must be compatible. To access the Release Notes, go
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007832 to the :yocto_home:`Downloads </software-overview/downloads>`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007833 page on the Yocto Project website and click on the "RELEASE
7834 INFORMATION" link for the appropriate release.
7835
7836 The ``TCMODE`` variable is similar to :term:`TCLIBC`,
7837 which controls the variant of the GNU standard C library (``libc``)
7838 used during the build process: ``glibc`` or ``musl``.
7839
7840 With additional layers, it is possible to use a pre-compiled external
7841 toolchain. One example is the Sourcery G++ Toolchain. The support for
7842 this toolchain resides in the separate Mentor Graphics
7843 ``meta-sourcery`` layer at
7844 http://github.com/MentorEmbedded/meta-sourcery/.
7845
7846 The layer's ``README`` file contains information on how to use the
7847 Sourcery G++ Toolchain as an external toolchain. In summary, you must
7848 be sure to add the layer to your ``bblayers.conf`` file in front of
7849 the ``meta`` layer and then set the ``EXTERNAL_TOOLCHAIN`` variable
7850 in your ``local.conf`` file to the location in which you installed
7851 the toolchain.
7852
7853 The fundamentals used for this example apply to any external
7854 toolchain. You can use ``meta-sourcery`` as a template for adding
7855 support for other external toolchains.
7856
Andrew Geisslerf0343792020-11-18 10:42:21 -06007857 :term:`TEST_EXPORT_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007858 The location the OpenEmbedded build system uses to export tests when
7859 the :term:`TEST_EXPORT_ONLY` variable is set
7860 to "1".
7861
7862 The ``TEST_EXPORT_DIR`` variable defaults to
7863 ``"${TMPDIR}/testimage/${PN}"``.
7864
Andrew Geisslerf0343792020-11-18 10:42:21 -06007865 :term:`TEST_EXPORT_ONLY`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007866 Specifies to export the tests only. Set this variable to "1" if you
7867 do not want to run the tests but you want them to be exported in a
7868 manner that you to run them outside of the build system.
7869
Andrew Geisslerf0343792020-11-18 10:42:21 -06007870 :term:`TEST_LOG_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007871 Holds the SSH log and the boot log for QEMU machines. The
7872 ``TEST_LOG_DIR`` variable defaults to ``"${WORKDIR}/testimage"``.
7873
7874 .. note::
7875
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007876 Actual test results reside in the task log (``log.do_testimage``),
7877 which is in the ``${WORKDIR}/temp/`` directory.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007878
Andrew Geisslerf0343792020-11-18 10:42:21 -06007879 :term:`TEST_POWERCONTROL_CMD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007880 For automated hardware testing, specifies the command to use to
7881 control the power of the target machine under test. Typically, this
7882 command would point to a script that performs the appropriate action
7883 (e.g. interacting with a web-enabled power strip). The specified
7884 command should expect to receive as the last argument "off", "on" or
7885 "cycle" specifying to power off, on, or cycle (power off and then
7886 power on) the device, respectively.
7887
Andrew Geisslerf0343792020-11-18 10:42:21 -06007888 :term:`TEST_POWERCONTROL_EXTRA_ARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007889 For automated hardware testing, specifies additional arguments to
7890 pass through to the command specified in
7891 :term:`TEST_POWERCONTROL_CMD`. Setting
7892 ``TEST_POWERCONTROL_EXTRA_ARGS`` is optional. You can use it if you
7893 wish, for example, to separate the machine-specific and
7894 non-machine-specific parts of the arguments.
7895
Andrew Geisslerf0343792020-11-18 10:42:21 -06007896 :term:`TEST_QEMUBOOT_TIMEOUT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007897 The time in seconds allowed for an image to boot before automated
7898 runtime tests begin to run against an image. The default timeout
7899 period to allow the boot process to reach the login prompt is 500
7900 seconds. You can specify a different value in the ``local.conf``
7901 file.
7902
7903 For more information on testing images, see the
7904 ":ref:`dev-manual/dev-manual-common-tasks:performing automated runtime testing`"
7905 section in the Yocto Project Development Tasks Manual.
7906
Andrew Geisslerf0343792020-11-18 10:42:21 -06007907 :term:`TEST_SERIALCONTROL_CMD`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007908 For automated hardware testing, specifies the command to use to
7909 connect to the serial console of the target machine under test. This
7910 command simply needs to connect to the serial console and forward
7911 that connection to standard input and output as any normal terminal
7912 program does.
7913
7914 For example, to use the Picocom terminal program on serial device
7915 ``/dev/ttyUSB0`` at 115200bps, you would set the variable as follows:
7916 ::
7917
7918 TEST_SERIALCONTROL_CMD = "picocom /dev/ttyUSB0 -b 115200"
7919
Andrew Geisslerf0343792020-11-18 10:42:21 -06007920 :term:`TEST_SERIALCONTROL_EXTRA_ARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007921 For automated hardware testing, specifies additional arguments to
7922 pass through to the command specified in
7923 :term:`TEST_SERIALCONTROL_CMD`. Setting
7924 ``TEST_SERIALCONTROL_EXTRA_ARGS`` is optional. You can use it if you
7925 wish, for example, to separate the machine-specific and
7926 non-machine-specific parts of the command.
7927
Andrew Geisslerf0343792020-11-18 10:42:21 -06007928 :term:`TEST_SERVER_IP`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007929 The IP address of the build machine (host machine). This IP address
7930 is usually automatically detected. However, if detection fails, this
7931 variable needs to be set to the IP address of the build machine (i.e.
7932 where the build is taking place).
7933
7934 .. note::
7935
Andrew Geissler4c19ea12020-10-27 13:52:24 -05007936 The ``TEST_SERVER_IP`` variable is only used for a small number of
7937 tests such as the "dnf" test suite, which needs to download packages
7938 from ``WORKDIR/oe-rootfs-repo``.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007939
Andrew Geisslerf0343792020-11-18 10:42:21 -06007940 :term:`TEST_SUITES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05007941 An ordered list of tests (modules) to run against an image when
7942 performing automated runtime testing.
7943
7944 The OpenEmbedded build system provides a core set of tests that can
7945 be used against images.
7946
7947 .. note::
7948
7949 Currently, there is only support for running these tests under
7950 QEMU.
7951
7952 Tests include ``ping``, ``ssh``, ``df`` among others. You can add
7953 your own tests to the list of tests by appending ``TEST_SUITES`` as
7954 follows:
7955 ::
7956
7957 TEST_SUITES_append = " mytest"
7958
7959 Alternatively, you can
7960 provide the "auto" option to have all applicable tests run against
7961 the image.
7962 ::
7963
7964 TEST_SUITES_append = " auto"
7965
7966 Using this option causes the
7967 build system to automatically run tests that are applicable to the
7968 image. Tests that are not applicable are skipped.
7969
7970 The order in which tests are run is important. Tests that depend on
7971 another test must appear later in the list than the test on which
7972 they depend. For example, if you append the list of tests with two
7973 tests (``test_A`` and ``test_B``) where ``test_B`` is dependent on
7974 ``test_A``, then you must order the tests as follows:
7975 ::
7976
7977 TEST_SUITES = "test_A test_B"
7978
7979 For more information on testing images, see the
7980 ":ref:`dev-manual/dev-manual-common-tasks:performing automated runtime testing`"
7981 section in the Yocto Project Development Tasks Manual.
7982
Andrew Geisslerf0343792020-11-18 10:42:21 -06007983 :term:`TEST_TARGET`
7984 Specifies the target controller to use when running tests against a
7985 test image. The default controller to use is "qemu":
7986 ::
7987
7988 TEST_TARGET = "qemu"
7989
7990 A target controller is a class that defines how an image gets
7991 deployed on a target and how a target is started. A layer can extend
7992 the controllers by adding a module in the layer's
7993 ``/lib/oeqa/controllers`` directory and by inheriting the
7994 ``BaseTarget`` class, which is an abstract class that cannot be used
7995 as a value of ``TEST_TARGET``.
7996
7997 You can provide the following arguments with ``TEST_TARGET``:
7998
7999 - *"qemu":* Boots a QEMU image and runs the tests. See the
8000 ":ref:`qemu-image-enabling-tests`" section
8001 in the Yocto Project Development Tasks Manual for more
8002 information.
8003
8004 - *"simpleremote":* Runs the tests on target hardware that is
8005 already up and running. The hardware can be on the network or it
8006 can be a device running an image on QEMU. You must also set
8007 :term:`TEST_TARGET_IP` when you use
8008 "simpleremote".
8009
8010 .. note::
8011
8012 This argument is defined in
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008013 ``meta/lib/oeqa/controllers/simpleremote.py``.
Andrew Geisslerf0343792020-11-18 10:42:21 -06008014
8015 For information on running tests on hardware, see the
8016 ":ref:`hardware-image-enabling-tests`"
8017 section in the Yocto Project Development Tasks Manual.
8018
8019 :term:`TEST_TARGET_IP`
8020 The IP address of your hardware under test. The ``TEST_TARGET_IP``
8021 variable has no effect when :term:`TEST_TARGET` is
8022 set to "qemu".
8023
8024 When you specify the IP address, you can also include a port. Here is
8025 an example:
8026 ::
8027
8028 TEST_TARGET_IP = "192.168.1.4:2201"
8029
8030 Specifying a port is
8031 useful when SSH is started on a non-standard port or in cases when
8032 your hardware under test is behind a firewall or network that is not
8033 directly accessible from your host and you need to do port address
8034 translation.
8035
8036 :term:`TESTIMAGE_AUTO`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008037 Automatically runs the series of automated tests for images when an
8038 image is successfully built. Setting ``TESTIMAGE_AUTO`` to "1" causes
8039 any image that successfully builds to automatically boot under QEMU.
8040 Using the variable also adds in dependencies so that any SDK for
8041 which testing is requested is automatically built first.
8042
8043 These tests are written in Python making use of the ``unittest``
8044 module, and the majority of them run commands on the target system
8045 over ``ssh``. You can set this variable to "1" in your ``local.conf``
8046 file in the :term:`Build Directory` to have the
8047 OpenEmbedded build system automatically run these tests after an
8048 image successfully builds:
8049
8050 TESTIMAGE_AUTO = "1"
8051
8052 For more information
8053 on enabling, running, and writing these tests, see the
8054 ":ref:`dev-manual/dev-manual-common-tasks:performing automated runtime testing`"
8055 section in the Yocto Project Development Tasks Manual and the
8056 ":ref:`testimage*.bbclass <ref-classes-testimage*>`" section.
8057
Andrew Geisslerf0343792020-11-18 10:42:21 -06008058 :term:`THISDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008059 The directory in which the file BitBake is currently parsing is
8060 located. Do not manually set this variable.
8061
Andrew Geisslerf0343792020-11-18 10:42:21 -06008062 :term:`TIME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008063 The time the build was started. Times appear using the hour, minute,
8064 and second (HMS) format (e.g. "140159" for one minute and fifty-nine
8065 seconds past 1400 hours).
8066
Andrew Geisslerf0343792020-11-18 10:42:21 -06008067 :term:`TMPDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008068 This variable is the base directory the OpenEmbedded build system
8069 uses for all build output and intermediate files (other than the
8070 shared state cache). By default, the ``TMPDIR`` variable points to
8071 ``tmp`` within the :term:`Build Directory`.
8072
8073 If you want to establish this directory in a location other than the
8074 default, you can uncomment and edit the following statement in the
8075 ``conf/local.conf`` file in the :term:`Source Directory`:
8076 ::
8077
8078 #TMPDIR = "${TOPDIR}/tmp"
8079
8080 An example use for this scenario is to set ``TMPDIR`` to a local disk,
8081 which does not use NFS, while having the Build Directory use NFS.
8082
8083 The filesystem used by ``TMPDIR`` must have standard filesystem
8084 semantics (i.e. mixed-case files are unique, POSIX file locking, and
8085 persistent inodes). Due to various issues with NFS and bugs in some
8086 implementations, NFS does not meet this minimum requirement.
8087 Consequently, ``TMPDIR`` cannot be on NFS.
8088
Andrew Geisslerf0343792020-11-18 10:42:21 -06008089 :term:`TOOLCHAIN_HOST_TASK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008090 This variable lists packages the OpenEmbedded build system uses when
8091 building an SDK, which contains a cross-development environment. The
8092 packages specified by this variable are part of the toolchain set
8093 that runs on the :term:`SDKMACHINE`, and each
8094 package should usually have the prefix ``nativesdk-``. For example,
8095 consider the following command when building an SDK:
8096 ::
8097
8098 $ bitbake -c populate_sdk imagename
8099
8100 In this case, a default list of packages is
8101 set in this variable, but you can add additional packages to the
8102 list. See the
8103 ":ref:`sdk-manual/sdk-appendix-customizing-standard:adding individual packages to the standard sdk`" section
8104 in the Yocto Project Application Development and the Extensible
8105 Software Development Kit (eSDK) manual for more information.
8106
8107 For background information on cross-development toolchains in the
8108 Yocto Project development environment, see the
8109 ":ref:`sdk-manual/sdk-intro:the cross-development toolchain`"
8110 section in the Yocto Project Overview and Concepts Manual. For
8111 information on setting up a cross-development environment, see the
8112 :doc:`../sdk-manual/sdk-manual` manual.
8113
Andrew Geisslerf0343792020-11-18 10:42:21 -06008114 :term:`TOOLCHAIN_OUTPUTNAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008115 This variable defines the name used for the toolchain output. The
8116 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class sets
8117 the ``TOOLCHAIN_OUTPUTNAME`` variable as follows:
8118 ::
8119
8120 TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}"
8121
8122 See
8123 the :term:`SDK_NAME` and
8124 :term:`SDK_VERSION` variables for additional
8125 information.
8126
Andrew Geisslerf0343792020-11-18 10:42:21 -06008127 :term:`TOOLCHAIN_TARGET_TASK`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008128 This variable lists packages the OpenEmbedded build system uses when
8129 it creates the target part of an SDK (i.e. the part built for the
8130 target hardware), which includes libraries and headers. Use this
8131 variable to add individual packages to the part of the SDK that runs
8132 on the target. See the
8133 ":ref:`sdk-manual/sdk-appendix-customizing-standard:adding individual packages to the standard sdk`" section
8134 in the Yocto Project Application Development and the Extensible
8135 Software Development Kit (eSDK) manual for more information.
8136
8137 For background information on cross-development toolchains in the
8138 Yocto Project development environment, see the
8139 ":ref:`sdk-manual/sdk-intro:the cross-development toolchain`"
8140 section in the Yocto Project Overview and Concepts Manual. For
8141 information on setting up a cross-development environment, see the
8142 :doc:`../sdk-manual/sdk-manual` manual.
8143
Andrew Geisslerf0343792020-11-18 10:42:21 -06008144 :term:`TOPDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008145 The top-level :term:`Build Directory`. BitBake
8146 automatically sets this variable when you initialize your build
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008147 environment using :ref:`structure-core-script`.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008148
Andrew Geisslerf0343792020-11-18 10:42:21 -06008149 :term:`TRANSLATED_TARGET_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008150 A sanitized version of :term:`TARGET_ARCH`. This
8151 variable is used where the architecture is needed in a value where
8152 underscores are not allowed, for example within package filenames. In
8153 this case, dash characters replace any underscore characters used in
8154 ``TARGET_ARCH``.
8155
8156 Do not edit this variable.
8157
Andrew Geisslerf0343792020-11-18 10:42:21 -06008158 :term:`TUNE_ARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008159 The GNU canonical architecture for a specific architecture (i.e.
8160 ``arm``, ``armeb``, ``mips``, ``mips64``, and so forth). BitBake uses
8161 this value to setup configuration.
8162
8163 ``TUNE_ARCH`` definitions are specific to a given architecture. The
8164 definitions can be a single static definition, or can be dynamically
8165 adjusted. You can see details for a given CPU family by looking at
8166 the architecture's ``README`` file. For example, the
8167 ``meta/conf/machine/include/mips/README`` file in the
8168 :term:`Source Directory` provides information for
8169 ``TUNE_ARCH`` specific to the ``mips`` architecture.
8170
8171 ``TUNE_ARCH`` is tied closely to
8172 :term:`TARGET_ARCH`, which defines the target
8173 machine's architecture. The BitBake configuration file
8174 (``meta/conf/bitbake.conf``) sets ``TARGET_ARCH`` as follows:
8175 ::
8176
8177 TARGET_ARCH = "${TUNE_ARCH}"
8178
8179 The following list, which is by no means complete since architectures
8180 are configurable, shows supported machine architectures:
8181
8182 - arm
8183 - i586
8184 - x86_64
8185 - powerpc
8186 - powerpc64
8187 - mips
8188 - mipsel
8189
Andrew Geisslerf0343792020-11-18 10:42:21 -06008190 :term:`TUNE_ASARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008191 Specifies architecture-specific assembler flags for the target
8192 system. The set of flags is based on the selected tune features.
8193 ``TUNE_ASARGS`` is set using the tune include files, which are
8194 typically under ``meta/conf/machine/include/`` and are influenced
8195 through :term:`TUNE_FEATURES`. For example, the
8196 ``meta/conf/machine/include/x86/arch-x86.inc`` file defines the flags
8197 for the x86 architecture as follows:
8198 ::
8199
8200 TUNE_ASARGS += "${@bb.utils.contains("TUNE_FEATURES", "mx32", "-x32", "", d)}"
8201
8202 .. note::
8203
8204 Board Support Packages (BSPs) select the tune. The selected tune,
8205 in turn, affects the tune variables themselves (i.e. the tune can
8206 supply its own set of flags).
8207
Andrew Geisslerf0343792020-11-18 10:42:21 -06008208 :term:`TUNE_CCARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008209 Specifies architecture-specific C compiler flags for the target
8210 system. The set of flags is based on the selected tune features.
8211 ``TUNE_CCARGS`` is set using the tune include files, which are
8212 typically under ``meta/conf/machine/include/`` and are influenced
8213 through :term:`TUNE_FEATURES`.
8214
8215 .. note::
8216
8217 Board Support Packages (BSPs) select the tune. The selected tune,
8218 in turn, affects the tune variables themselves (i.e. the tune can
8219 supply its own set of flags).
8220
Andrew Geisslerf0343792020-11-18 10:42:21 -06008221 :term:`TUNE_FEATURES`
8222 Features used to "tune" a compiler for optimal use given a specific
8223 processor. The features are defined within the tune files and allow
8224 arguments (i.e. ``TUNE_*ARGS``) to be dynamically generated based on
8225 the features.
8226
8227 The OpenEmbedded build system verifies the features to be sure they
8228 are not conflicting and that they are supported.
8229
8230 The BitBake configuration file (``meta/conf/bitbake.conf``) defines
8231 ``TUNE_FEATURES`` as follows:
8232 ::
8233
8234 TUNE_FEATURES ??= "${TUNE_FEATURES_tune-${DEFAULTTUNE}}"
8235
8236 See the :term:`DEFAULTTUNE` variable for more information.
8237
8238 :term:`TUNE_LDARGS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008239 Specifies architecture-specific linker flags for the target system.
8240 The set of flags is based on the selected tune features.
8241 ``TUNE_LDARGS`` is set using the tune include files, which are
8242 typically under ``meta/conf/machine/include/`` and are influenced
8243 through :term:`TUNE_FEATURES`. For example, the
8244 ``meta/conf/machine/include/x86/arch-x86.inc`` file defines the flags
8245 for the x86 architecture as follows:
8246 ::
8247
8248 TUNE_LDARGS += "${@bb.utils.contains("TUNE_FEATURES", "mx32", "-m elf32_x86_64", "", d)}"
8249
8250 .. note::
8251
8252 Board Support Packages (BSPs) select the tune. The selected tune,
8253 in turn, affects the tune variables themselves (i.e. the tune can
8254 supply its own set of flags).
8255
Andrew Geisslerf0343792020-11-18 10:42:21 -06008256 :term:`TUNE_PKGARCH`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008257 The package architecture understood by the packaging system to define
8258 the architecture, ABI, and tuning of output packages. The specific
8259 tune is defined using the "_tune" override as follows:
8260 ::
8261
8262 TUNE_PKGARCH_tune-tune = "tune"
8263
8264 These tune-specific package architectures are defined in the machine
8265 include files. Here is an example of the "core2-32" tuning as used in
8266 the ``meta/conf/machine/include/tune-core2.inc`` file:
8267 ::
8268
8269 TUNE_PKGARCH_tune-core2-32 = "core2-32"
8270
Andrew Geisslerf0343792020-11-18 10:42:21 -06008271 :term:`TUNEABI`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008272 An underlying Application Binary Interface (ABI) used by a particular
8273 tuning in a given toolchain layer. Providers that use prebuilt
8274 libraries can use the ``TUNEABI``,
8275 :term:`TUNEABI_OVERRIDE`, and
8276 :term:`TUNEABI_WHITELIST` variables to check
8277 compatibility of tunings against their selection of libraries.
8278
8279 If ``TUNEABI`` is undefined, then every tuning is allowed. See the
8280 :ref:`sanity <ref-classes-sanity>` class to see how the variable is
8281 used.
8282
Andrew Geisslerf0343792020-11-18 10:42:21 -06008283 :term:`TUNEABI_OVERRIDE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008284 If set, the OpenEmbedded system ignores the
8285 :term:`TUNEABI_WHITELIST` variable.
8286 Providers that use prebuilt libraries can use the
8287 ``TUNEABI_OVERRIDE``, ``TUNEABI_WHITELIST``, and
8288 :term:`TUNEABI` variables to check compatibility of a
8289 tuning against their selection of libraries.
8290
8291 See the :ref:`sanity <ref-classes-sanity>` class to see how the
8292 variable is used.
8293
Andrew Geisslerf0343792020-11-18 10:42:21 -06008294 :term:`TUNEABI_WHITELIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008295 A whitelist of permissible :term:`TUNEABI` values. If
8296 ``TUNEABI_WHITELIST`` is not set, all tunes are allowed. Providers
8297 that use prebuilt libraries can use the ``TUNEABI_WHITELIST``,
8298 :term:`TUNEABI_OVERRIDE`, and ``TUNEABI``
8299 variables to check compatibility of a tuning against their selection
8300 of libraries.
8301
8302 See the :ref:`sanity <ref-classes-sanity>` class to see how the
8303 variable is used.
8304
Andrew Geisslerf0343792020-11-18 10:42:21 -06008305 :term:`TUNECONFLICTS[feature]`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008306 Specifies CPU or Application Binary Interface (ABI) tuning features
8307 that conflict with feature.
8308
8309 Known tuning conflicts are specified in the machine include files in
8310 the :term:`Source Directory`. Here is an example from
8311 the ``meta/conf/machine/include/mips/arch-mips.inc`` include file
8312 that lists the "o32" and "n64" features as conflicting with the "n32"
8313 feature:
8314 ::
8315
8316 TUNECONFLICTS[n32] = "o32 n64"
8317
Andrew Geisslerf0343792020-11-18 10:42:21 -06008318 :term:`TUNEVALID[feature]`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008319 Specifies a valid CPU or Application Binary Interface (ABI) tuning
8320 feature. The specified feature is stored as a flag. Valid features
8321 are specified in the machine include files (e.g.
8322 ``meta/conf/machine/include/arm/arch-arm.inc``). Here is an example
8323 from that file:
8324 ::
8325
8326 TUNEVALID[bigendian] = "Enable big-endian mode."
8327
8328 See the machine include files in the :term:`Source Directory`
8329 for these features.
8330
Andrew Geisslerf0343792020-11-18 10:42:21 -06008331 :term:`UBOOT_CONFIG`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008332 Configures the :term:`UBOOT_MACHINE` and can
8333 also define :term:`IMAGE_FSTYPES` for individual
8334 cases.
8335
8336 Following is an example from the ``meta-fsl-arm`` layer. ::
8337
8338 UBOOT_CONFIG ??= "sd"
8339 UBOOT_CONFIG[sd] = "mx6qsabreauto_config,sdcard"
8340 UBOOT_CONFIG[eimnor] = "mx6qsabreauto_eimnor_config"
8341 UBOOT_CONFIG[nand] = "mx6qsabreauto_nand_config,ubifs"
8342 UBOOT_CONFIG[spinor] = "mx6qsabreauto_spinor_config"
8343
8344 In this example, "sd" is selected as the configuration of the possible four for the
8345 ``UBOOT_MACHINE``. The "sd" configuration defines
8346 "mx6qsabreauto_config" as the value for ``UBOOT_MACHINE``, while the
8347 "sdcard" specifies the ``IMAGE_FSTYPES`` to use for the U-boot image.
8348
8349 For more information on how the ``UBOOT_CONFIG`` is handled, see the
8350 :ref:`uboot-config <ref-classes-uboot-config>`
8351 class.
8352
Andrew Geisslerf0343792020-11-18 10:42:21 -06008353 :term:`UBOOT_DTB_LOADADDRESS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008354 Specifies the load address for the dtb image used by U-boot. During FIT
8355 image creation, the ``UBOOT_DTB_LOADADDRESS`` variable is used in
8356 :ref:`kernel-fitimage <ref-classes-kernel-fitimage>` class to specify
8357 the load address to be used in
8358 creating the dtb sections of Image Tree Source for the FIT image.
8359
Andrew Geisslerf0343792020-11-18 10:42:21 -06008360 :term:`UBOOT_DTBO_LOADADDRESS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008361 Specifies the load address for the dtbo image used by U-boot. During FIT
8362 image creation, the ``UBOOT_DTBO_LOADADDRESS`` variable is used in
8363 :ref:`kernel-fitimage <ref-classes-kernel-fitimage>` class to specify the load address to be used in
8364 creating the dtbo sections of Image Tree Source for the FIT image.
8365
Andrew Geisslerf0343792020-11-18 10:42:21 -06008366 :term:`UBOOT_ENTRYPOINT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008367 Specifies the entry point for the U-Boot image. During U-Boot image
8368 creation, the ``UBOOT_ENTRYPOINT`` variable is passed as a
8369 command-line parameter to the ``uboot-mkimage`` utility.
8370
Andrew Geisslerf0343792020-11-18 10:42:21 -06008371 :term:`UBOOT_LOADADDRESS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008372 Specifies the load address for the U-Boot image. During U-Boot image
8373 creation, the ``UBOOT_LOADADDRESS`` variable is passed as a
8374 command-line parameter to the ``uboot-mkimage`` utility.
8375
Andrew Geisslerf0343792020-11-18 10:42:21 -06008376 :term:`UBOOT_LOCALVERSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008377 Appends a string to the name of the local version of the U-Boot
8378 image. For example, assuming the version of the U-Boot image built
8379 was "2013.10", the full version string reported by U-Boot would be
8380 "2013.10-yocto" given the following statement:
8381 ::
8382
8383 UBOOT_LOCALVERSION = "-yocto"
8384
Andrew Geisslerf0343792020-11-18 10:42:21 -06008385 :term:`UBOOT_MACHINE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008386 Specifies the value passed on the ``make`` command line when building
8387 a U-Boot image. The value indicates the target platform
8388 configuration. You typically set this variable from the machine
8389 configuration file (i.e. ``conf/machine/machine_name.conf``).
8390
8391 Please see the "Selection of Processor Architecture and Board Type"
8392 section in the U-Boot README for valid values for this variable.
8393
Andrew Geisslerf0343792020-11-18 10:42:21 -06008394 :term:`UBOOT_MAKE_TARGET`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008395 Specifies the target called in the ``Makefile``. The default target
8396 is "all".
8397
Andrew Geisslerf0343792020-11-18 10:42:21 -06008398 :term:`UBOOT_MKIMAGE_DTCOPTS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008399 Options for the device tree compiler passed to mkimage '-D'
8400 feature while creating FIT image in :ref:`kernel-fitimage <ref-classes-kernel-fitimage>` class.
8401
Andrew Geisslerf0343792020-11-18 10:42:21 -06008402 :term:`UBOOT_RD_ENTRYPOINT`
Andrew Geissler4873add2020-11-02 18:44:49 -06008403 Specifies the entrypoint for the RAM disk image.
8404 During FIT image creation, the
8405 ``UBOOT_RD_ENTRYPOINT`` variable is used
8406 in :ref:`kernel-fitimage <ref-classes-kernel-fitimage>` class to specify the
8407 entrypoint to be used in creating the Image Tree Source for
8408 the FIT image.
8409
Andrew Geisslerf0343792020-11-18 10:42:21 -06008410 :term:`UBOOT_RD_LOADADDRESS`
8411 Specifies the load address for the RAM disk image.
8412 During FIT image creation, the
8413 ``UBOOT_RD_LOADADDRESS`` variable is used
8414 in :ref:`kernel-fitimage <ref-classes-kernel-fitimage>` class to specify the
8415 load address to be used in creating the Image Tree Source for
8416 the FIT image.
8417
8418 :term:`UBOOT_SIGN_ENABLE`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008419 Enable signing of FIT image. The default value is "0".
8420
Andrew Geisslerf0343792020-11-18 10:42:21 -06008421 :term:`UBOOT_SIGN_KEYDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008422 Location of the directory containing the RSA key and
8423 certificate used for signing FIT image.
8424
Andrew Geisslerf0343792020-11-18 10:42:21 -06008425 :term:`UBOOT_SIGN_KEYNAME`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008426 The name of keys used for signing U-boot FIT image stored in
8427 :term:`UBOOT_SIGN_KEYDIR` directory. For e.g. dev.key key and dev.crt
8428 certificate stored in :term:`UBOOT_SIGN_KEYDIR` directory will have
8429 :term:`UBOOT_SIGN_KEYNAME` set to "dev".
8430
Andrew Geisslerf0343792020-11-18 10:42:21 -06008431 :term:`UBOOT_SUFFIX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008432 Points to the generated U-Boot extension. For example, ``u-boot.sb``
8433 has a ``.sb`` extension.
8434
8435 The default U-Boot extension is ``.bin``
8436
Andrew Geisslerf0343792020-11-18 10:42:21 -06008437 :term:`UBOOT_TARGET`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008438 Specifies the target used for building U-Boot. The target is passed
8439 directly as part of the "make" command (e.g. SPL and AIS). If you do
8440 not specifically set this variable, the OpenEmbedded build process
8441 passes and uses "all" for the target during the U-Boot building
8442 process.
8443
Andrew Geisslerf0343792020-11-18 10:42:21 -06008444 :term:`UNKNOWN_CONFIGURE_WHITELIST`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008445 Specifies a list of options that, if reported by the configure script
8446 as being invalid, should not generate a warning during the
8447 :ref:`ref-tasks-configure` task. Normally, invalid
8448 configure options are simply not passed to the configure script (e.g.
8449 should be removed from :term:`EXTRA_OECONF` or
8450 :term:`PACKAGECONFIG_CONFARGS`).
8451 However, common options, for example, exist that are passed to all
8452 configure scripts at a class level that might not be valid for some
8453 configure scripts. It follows that no benefit exists in seeing a
8454 warning about these options. For these cases, the options are added
8455 to ``UNKNOWN_CONFIGURE_WHITELIST``.
8456
8457 The configure arguments check that uses
8458 ``UNKNOWN_CONFIGURE_WHITELIST`` is part of the
8459 :ref:`insane <ref-classes-insane>` class and is only enabled if the
8460 recipe inherits the :ref:`autotools <ref-classes-autotools>` class.
8461
Andrew Geisslerf0343792020-11-18 10:42:21 -06008462 :term:`UPDATERCPN`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008463 For recipes inheriting the
8464 :ref:`update-rc.d <ref-classes-update-rc.d>` class, ``UPDATERCPN``
8465 specifies the package that contains the initscript that is enabled.
8466
8467 The default value is "${PN}". Given that almost all recipes that
8468 install initscripts package them in the main package for the recipe,
8469 you rarely need to set this variable in individual recipes.
8470
Andrew Geisslerf0343792020-11-18 10:42:21 -06008471 :term:`UPSTREAM_CHECK_GITTAGREGEX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008472 You can perform a per-recipe check for what the latest upstream
8473 source code version is by calling ``bitbake -c checkpkg`` recipe. If
8474 the recipe source code is provided from Git repositories, the
8475 OpenEmbedded build system determines the latest upstream version by
8476 picking the latest tag from the list of all repository tags.
8477
8478 You can use the ``UPSTREAM_CHECK_GITTAGREGEX`` variable to provide a
8479 regular expression to filter only the relevant tags should the
8480 default filter not work correctly.
8481 ::
8482
8483 UPSTREAM_CHECK_GITTAGREGEX = "git_tag_regex"
8484
Andrew Geisslerf0343792020-11-18 10:42:21 -06008485 :term:`UPSTREAM_CHECK_REGEX`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008486 Use the ``UPSTREAM_CHECK_REGEX`` variable to specify a different
8487 regular expression instead of the default one when the package
8488 checking system is parsing the page found using
8489 :term:`UPSTREAM_CHECK_URI`.
8490 ::
8491
8492 UPSTREAM_CHECK_REGEX = "package_regex"
8493
Andrew Geisslerf0343792020-11-18 10:42:21 -06008494 :term:`UPSTREAM_CHECK_URI`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008495 You can perform a per-recipe check for what the latest upstream
8496 source code version is by calling ``bitbake -c checkpkg`` recipe. If
8497 the source code is provided from tarballs, the latest version is
8498 determined by fetching the directory listing where the tarball is and
8499 attempting to find a later tarball. When this approach does not work,
8500 you can use ``UPSTREAM_CHECK_URI`` to provide a different URI that
8501 contains the link to the latest tarball.
8502 ::
8503
8504 UPSTREAM_CHECK_URI = "recipe_url"
8505
Andrew Geisslerf0343792020-11-18 10:42:21 -06008506 :term:`USE_DEVFS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008507 Determines if ``devtmpfs`` is used for ``/dev`` population. The
8508 default value used for ``USE_DEVFS`` is "1" when no value is
8509 specifically set. Typically, you would set ``USE_DEVFS`` to "0" for a
8510 statically populated ``/dev`` directory.
8511
8512 See the ":ref:`selecting-dev-manager`" section in
8513 the Yocto Project Development Tasks Manual for information on how to
8514 use this variable.
8515
Andrew Geisslerf0343792020-11-18 10:42:21 -06008516 :term:`USE_VT`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008517 When using
8518 :ref:`SysVinit <new-recipe-enabling-system-services>`,
8519 determines whether or not to run a
8520 `getty <http://en.wikipedia.org/wiki/Getty_%28Unix%29>`__ on any
8521 virtual terminals in order to enable logging in through those
8522 terminals.
8523
8524 The default value used for ``USE_VT`` is "1" when no default value is
8525 specifically set. Typically, you would set ``USE_VT`` to "0" in the
8526 machine configuration file for machines that do not have a graphical
8527 display attached and therefore do not need virtual terminal
8528 functionality.
8529
Andrew Geisslerf0343792020-11-18 10:42:21 -06008530 :term:`USER_CLASSES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008531 A list of classes to globally inherit. These classes are used by the
8532 OpenEmbedded build system to enable extra features (e.g.
8533 ``buildstats``, ``image-mklibs``, and so forth).
8534
8535 The default list is set in your ``local.conf`` file:
8536 ::
8537
8538 USER_CLASSES ?= "buildstats image-mklibs image-prelink"
8539
8540 For more information, see
8541 ``meta-poky/conf/local.conf.sample`` in the :term:`Source Directory`.
8542
Andrew Geisslerf0343792020-11-18 10:42:21 -06008543 :term:`USERADD_ERROR_DYNAMIC`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008544 If set to ``error``, forces the OpenEmbedded build system to produce
8545 an error if the user identification (``uid``) and group
8546 identification (``gid``) values are not defined in any of the files
8547 listed in :term:`USERADD_UID_TABLES` and
8548 :term:`USERADD_GID_TABLES`. If set to
8549 ``warn``, a warning will be issued instead.
8550
8551 The default behavior for the build system is to dynamically apply
8552 ``uid`` and ``gid`` values. Consequently, the
8553 ``USERADD_ERROR_DYNAMIC`` variable is by default not set. If you plan
8554 on using statically assigned ``gid`` and ``uid`` values, you should
8555 set the ``USERADD_ERROR_DYNAMIC`` variable in your ``local.conf``
8556 file as follows:
8557 ::
8558
8559 USERADD_ERROR_DYNAMIC = "error"
8560
8561 Overriding the
8562 default behavior implies you are going to also take steps to set
8563 static ``uid`` and ``gid`` values through use of the
8564 :term:`USERADDEXTENSION`,
8565 :term:`USERADD_UID_TABLES`, and
8566 :term:`USERADD_GID_TABLES` variables.
8567
8568 .. note::
8569
8570 There is a difference in behavior between setting
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008571 ``USERADD_ERROR_DYNAMIC`` to ``error`` and setting it to ``warn``.
8572 When it is set to ``warn``, the build system will report a warning for
8573 every undefined ``uid`` and ``gid`` in any recipe. But when it is set
8574 to ``error``, it will only report errors for recipes that are actually
8575 built.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008576 This saves you from having to add static IDs for recipes that you
8577 know will never be built.
8578
Andrew Geisslerf0343792020-11-18 10:42:21 -06008579 :term:`USERADD_GID_TABLES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008580 Specifies a password file to use for obtaining static group
8581 identification (``gid``) values when the OpenEmbedded build system
8582 adds a group to the system during package installation.
8583
8584 When applying static group identification (``gid``) values, the
8585 OpenEmbedded build system looks in :term:`BBPATH` for a
8586 ``files/group`` file and then applies those ``uid`` values. Set the
8587 variable as follows in your ``local.conf`` file:
8588 ::
8589
8590
8591 USERADD_GID_TABLES = "files/group"
8592
8593 .. note::
8594
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008595 Setting the :term:`USERADDEXTENSION` variable to "useradd-staticids"
8596 causes the build system to use static ``gid`` values.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008597
Andrew Geisslerf0343792020-11-18 10:42:21 -06008598 :term:`USERADD_PACKAGES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008599 When inheriting the :ref:`useradd <ref-classes-useradd>` class,
8600 this variable specifies the individual packages within the recipe
8601 that require users and/or groups to be added.
8602
8603 You must set this variable if the recipe inherits the class. For
8604 example, the following enables adding a user for the main package in
8605 a recipe:
8606 ::
8607
8608 USERADD_PACKAGES = "${PN}"
8609
8610 .. note::
8611
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008612 It follows that if you are going to use the ``USERADD_PACKAGES``
8613 variable, you need to set one or more of the :term:`USERADD_PARAM`,
8614 :term:`GROUPADD_PARAM`, or :term:`GROUPMEMS_PARAM` variables.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008615
Andrew Geisslerf0343792020-11-18 10:42:21 -06008616 :term:`USERADD_PARAM`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008617 When inheriting the :ref:`useradd <ref-classes-useradd>` class,
8618 this variable specifies for a package what parameters should pass to
8619 the ``useradd`` command if you add a user to the system when the
8620 package is installed.
8621
8622 Here is an example from the ``dbus`` recipe:
8623 ::
8624
8625 USERADD_PARAM_${PN} = "--system --home ${localstatedir}/lib/dbus \
8626 --no-create-home --shell /bin/false \
8627 --user-group messagebus"
8628
8629 For information on the
8630 standard Linux shell command ``useradd``, see
8631 http://linux.die.net/man/8/useradd.
8632
Andrew Geisslerf0343792020-11-18 10:42:21 -06008633 :term:`USERADD_UID_TABLES`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008634 Specifies a password file to use for obtaining static user
8635 identification (``uid``) values when the OpenEmbedded build system
8636 adds a user to the system during package installation.
8637
8638 When applying static user identification (``uid``) values, the
8639 OpenEmbedded build system looks in :term:`BBPATH` for a
8640 ``files/passwd`` file and then applies those ``uid`` values. Set the
8641 variable as follows in your ``local.conf`` file:
8642 ::
8643
8644 USERADD_UID_TABLES = "files/passwd"
8645
8646 .. note::
8647
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008648 Setting the :term:`USERADDEXTENSION` variable to "useradd-staticids"
8649 causes the build system to use static ``uid`` values.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008650
Andrew Geisslerf0343792020-11-18 10:42:21 -06008651 :term:`USERADDEXTENSION`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008652 When set to "useradd-staticids", causes the OpenEmbedded build system
8653 to base all user and group additions on a static ``passwd`` and
8654 ``group`` files found in :term:`BBPATH`.
8655
8656 To use static user identification (``uid``) and group identification
8657 (``gid``) values, set the variable as follows in your ``local.conf``
8658 file: USERADDEXTENSION = "useradd-staticids"
8659
8660 .. note::
8661
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008662 Setting this variable to use static ``uid`` and ``gid``
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008663 values causes the OpenEmbedded build system to employ the
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008664 :ref:`ref-classes-useradd` class.
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008665
8666 If you use static ``uid`` and ``gid`` information, you must also
8667 specify the ``files/passwd`` and ``files/group`` files by setting the
8668 :term:`USERADD_UID_TABLES` and
8669 :term:`USERADD_GID_TABLES` variables.
8670 Additionally, you should also set the
8671 :term:`USERADD_ERROR_DYNAMIC` variable.
8672
Andrew Geisslerf0343792020-11-18 10:42:21 -06008673 :term:`VOLATILE_LOG_DIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008674 Specifies the persistence of the target's ``/var/log`` directory,
8675 which is used to house postinstall target log files.
8676
8677 By default, ``VOLATILE_LOG_DIR`` is set to "yes", which means the
8678 file is not persistent. You can override this setting by setting the
8679 variable to "no" to make the log directory persistent.
8680
Andrew Geisslerf0343792020-11-18 10:42:21 -06008681 :term:`WARN_QA`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008682 Specifies the quality assurance checks whose failures are reported as
8683 warnings by the OpenEmbedded build system. You set this variable in
8684 your distribution configuration file. For a list of the checks you
8685 can control with this variable, see the
8686 ":ref:`insane.bbclass <ref-classes-insane>`" section.
8687
Andrew Geisslerf0343792020-11-18 10:42:21 -06008688 :term:`WKS_FILE`
8689 Specifies the location of the Wic kickstart file that is used by the
8690 OpenEmbedded build system to create a partitioned image
8691 (image\ ``.wic``). For information on how to create a partitioned
8692 image, see the
8693 ":ref:`dev-manual/dev-manual-common-tasks:creating partitioned images using wic`"
8694 section in the Yocto Project Development Tasks Manual. For details on
8695 the kickstart file format, see the ":doc:`../ref-manual/ref-kickstart`" Chapter.
8696
8697 :term:`WKS_FILE_DEPENDS`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008698 When placed in the recipe that builds your image, this variable lists
8699 build-time dependencies. The ``WKS_FILE_DEPENDS`` variable is only
8700 applicable when Wic images are active (i.e. when
8701 :term:`IMAGE_FSTYPES` contains entries related
8702 to Wic). If your recipe does not create Wic images, the variable has
8703 no effect.
8704
8705 The ``WKS_FILE_DEPENDS`` variable is similar to the
8706 :term:`DEPENDS` variable. When you use the variable in
8707 your recipe that builds the Wic image, dependencies you list in the
8708 ``WIC_FILE_DEPENDS`` variable are added to the ``DEPENDS`` variable.
8709
8710 With the ``WKS_FILE_DEPENDS`` variable, you have the possibility to
8711 specify a list of additional dependencies (e.g. native tools,
8712 bootloaders, and so forth), that are required to build Wic images.
8713 Following is an example:
8714 ::
8715
8716 WKS_FILE_DEPENDS = "some-native-tool"
8717
8718 In the
8719 previous example, some-native-tool would be replaced with an actual
8720 native tool on which the build would depend.
8721
Andrew Geisslerf0343792020-11-18 10:42:21 -06008722 :term:`WORKDIR`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008723 The pathname of the work directory in which the OpenEmbedded build
8724 system builds a recipe. This directory is located within the
8725 :term:`TMPDIR` directory structure and is specific to
8726 the recipe being built and the system for which it is being built.
8727
8728 The ``WORKDIR`` directory is defined as follows:
8729 ::
8730
8731 ${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}
8732
8733 The actual directory depends on several things:
8734
Andrew Geissler4c19ea12020-10-27 13:52:24 -05008735 - :term:`TMPDIR`: The top-level build output directory
8736 - :term:`MULTIMACH_TARGET_SYS`: The target system identifier
8737 - :term:`PN`: The recipe name
8738 - :term:`EXTENDPE`: The epoch - (if :term:`PE` is not specified, which
8739 is usually the case for most recipes, then `EXTENDPE` is blank)
8740 - :term:`PV`: The recipe version
8741 - :term:`PR`: The recipe revision
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008742
8743 As an example, assume a Source Directory top-level folder name
8744 ``poky``, a default Build Directory at ``poky/build``, and a
8745 ``qemux86-poky-linux`` machine target system. Furthermore, suppose
8746 your recipe is named ``foo_1.3.0-r0.bb``. In this case, the work
8747 directory the build system uses to build the package would be as
8748 follows:
8749 ::
8750
8751 poky/build/tmp/work/qemux86-poky-linux/foo/1.3.0-r0
8752
Andrew Geisslerf0343792020-11-18 10:42:21 -06008753 :term:`XSERVER`
Andrew Geisslerc9f78652020-09-18 14:11:35 -05008754 Specifies the packages that should be installed to provide an X
8755 server and drivers for the current machine, assuming your image
8756 directly includes ``packagegroup-core-x11-xserver`` or, perhaps
8757 indirectly, includes "x11-base" in
8758 :term:`IMAGE_FEATURES`.
8759
8760 The default value of ``XSERVER``, if not specified in the machine
8761 configuration, is "xserver-xorg xf86-video-fbdev xf86-input-evdev".
8762