1.. SPDX-License-Identifier: CC-BY-SA-2.0-UK 2 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 10: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>` 18 19.. glossary:: 20 :sorted: 21 22 :term:`ABIEXTENSION` 23 Extension to the Application Binary Interface (ABI) field of the GNU 24 canonical architecture name (e.g. "eabi"). 25 26 ABI extensions are set in the machine include files. For example, the 27 ``meta/conf/machine/include/arm/arch-arm.inc`` file sets the 28 following extension:: 29 30 ABIEXTENSION = "eabi" 31 32 :term:`ALLOW_EMPTY` 33 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 ALLOW_EMPTY:${PN} = "1" 43 ALLOW_EMPTY:${PN}-dev = "1" 44 ALLOW_EMPTY:${PN}-staticdev = "1" 45 46 :term:`ALTERNATIVE` 47 Lists commands in a package that need an alternative binary naming 48 scheme. Sometimes the same command is provided in multiple packages. 49 When this occurs, the OpenEmbedded build system needs to use the 50 alternatives system to create a different binary naming scheme so the 51 commands can co-exist. 52 53 To use the variable, list out the package's commands that are also 54 provided by another package. For example, if the ``busybox`` package 55 has four such commands, you identify them as follows:: 56 57 ALTERNATIVE:busybox = "sh sed test bracket" 58 59 For more information on the alternatives system, see the 60 ":ref:`ref-classes-update-alternatives`" 61 section. 62 63 :term:`ALTERNATIVE_LINK_NAME` 64 Used by the alternatives system to map duplicated commands to actual 65 locations. For example, if the ``bracket`` command provided by the 66 ``busybox`` package is duplicated through another package, you must 67 use the :term:`ALTERNATIVE_LINK_NAME` variable to specify the actual 68 location:: 69 70 ALTERNATIVE_LINK_NAME[bracket] = "/usr/bin/[" 71 72 In this example, the binary for the ``bracket`` command (i.e. ``[``) 73 from the ``busybox`` package resides in ``/usr/bin/``. 74 75 .. note:: 76 77 If :term:`ALTERNATIVE_LINK_NAME` is not defined, it defaults to ``${bindir}/name``. 78 79 For more information on the alternatives system, see the 80 ":ref:`ref-classes-update-alternatives`" 81 section. 82 83 :term:`ALTERNATIVE_PRIORITY` 84 Used by the alternatives system to create default priorities for 85 duplicated commands. You can use the variable to create a single 86 default regardless of the command name or package, a default for 87 specific duplicated commands regardless of the package, or a default 88 for specific commands tied to particular packages. Here are the 89 available syntax forms:: 90 91 ALTERNATIVE_PRIORITY = "priority" 92 ALTERNATIVE_PRIORITY[name] = "priority" 93 ALTERNATIVE_PRIORITY_pkg[name] = "priority" 94 95 For more information on the alternatives system, see the 96 ":ref:`ref-classes-update-alternatives`" 97 section. 98 99 :term:`ALTERNATIVE_TARGET` 100 Used by the alternatives system to create default link locations for 101 duplicated commands. You can use the variable to create a single 102 default location for all duplicated commands regardless of the 103 command name or package, a default for specific duplicated commands 104 regardless of the package, or a default for specific commands tied to 105 particular packages. Here are the available syntax forms:: 106 107 ALTERNATIVE_TARGET = "target" 108 ALTERNATIVE_TARGET[name] = "target" 109 ALTERNATIVE_TARGET_pkg[name] = "target" 110 111 .. note:: 112 113 If :term:`ALTERNATIVE_TARGET` is not defined, it inherits the value 114 from the :term:`ALTERNATIVE_LINK_NAME` variable. 115 116 If :term:`ALTERNATIVE_LINK_NAME` and :term:`ALTERNATIVE_TARGET` are the 117 same, the target for :term:`ALTERNATIVE_TARGET` has "``.{BPN}``" 118 appended to it. 119 120 Finally, if the file referenced has not been renamed, the 121 alternatives system will rename it to avoid the need to rename 122 alternative files in the :ref:`ref-tasks-install` 123 task while retaining support for the command if necessary. 124 125 For more information on the alternatives system, see the 126 ":ref:`ref-classes-update-alternatives`" section. 127 128 :term:`ANY_OF_DISTRO_FEATURES` 129 When inheriting the :ref:`ref-classes-features_check` 130 class, this variable identifies a list of distribution features where 131 at least one must be enabled in the current configuration in order 132 for the OpenEmbedded build system to build the recipe. In other words, 133 if none of the features listed in :term:`ANY_OF_DISTRO_FEATURES` 134 appear in :term:`DISTRO_FEATURES` within the current configuration, then 135 the recipe will be skipped, and if the build system attempts to build 136 the recipe then an error will be triggered. 137 138 :term:`APPEND` 139 An override list of append strings for each target specified with 140 :term:`LABELS`. 141 142 See the :ref:`ref-classes-grub-efi` class for more 143 information on how this variable is used. 144 145 :term:`AR` 146 The minimal command and arguments used to run ``ar``. 147 148 :term:`ARCHIVER_MODE` 149 When used with the :ref:`ref-classes-archiver` class, 150 determines the type of information used to create a released archive. 151 You can use this variable to create archives of patched source, 152 original source, configured source, and so forth by employing the 153 following variable flags (varflags):: 154 155 ARCHIVER_MODE[src] = "original" # Uses original (unpacked) source files. 156 ARCHIVER_MODE[src] = "patched" # Uses patched source files. This is the default. 157 ARCHIVER_MODE[src] = "configured" # Uses configured source files. 158 ARCHIVER_MODE[diff] = "1" # Uses patches between do_unpack and do_patch. 159 ARCHIVER_MODE[diff-exclude] ?= "file file ..." # Lists files and directories to exclude from diff. 160 ARCHIVER_MODE[dumpdata] = "1" # Uses environment data. 161 ARCHIVER_MODE[recipe] = "1" # Uses recipe and include files. 162 ARCHIVER_MODE[srpm] = "1" # Uses RPM package files. 163 164 For information on how the variable works, see the 165 ``meta/classes/archiver.bbclass`` file in the :term:`Source Directory`. 166 167 :term:`AS` 168 Minimal command and arguments needed to run the assembler. 169 170 :term:`ASSUME_PROVIDED` 171 Lists recipe names (:term:`PN` values) BitBake does not 172 attempt to build. Instead, BitBake assumes these recipes have already 173 been built. 174 175 In OpenEmbedded-Core, :term:`ASSUME_PROVIDED` mostly specifies native 176 tools that should not be built. An example is ``git-native``, which 177 when specified, allows for the Git binary from the host to be used 178 rather than building ``git-native``. 179 180 :term:`ASSUME_SHLIBS` 181 Provides additional ``shlibs`` provider mapping information, which 182 adds to or overwrites the information provided automatically by the 183 system. Separate multiple entries using spaces. 184 185 As an example, use the following form to add an ``shlib`` provider of 186 shlibname in packagename with the optional version:: 187 188 shlibname:packagename[_version] 189 190 Here is an example that adds a shared library named ``libEGL.so.1`` 191 as being provided by the ``libegl-implementation`` package:: 192 193 ASSUME_SHLIBS = "libEGL.so.1:libegl-implementation" 194 195 :term:`AUTHOR` 196 The email address used to contact the original author or authors in 197 order to send patches and forward bugs. 198 199 :term:`AUTO_LIBNAME_PKGS` 200 When the :ref:`ref-classes-debian` class is inherited, 201 which is the default behavior, :term:`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 206 :ref:`ref-classes-debian` class to act on all packages that are 207 explicitly generated by the recipe. 208 209 :term:`AUTOREV` 210 When :term:`SRCREV` is set to the value of this variable, it specifies to 211 use the latest source revision in the repository. Here is an example:: 212 213 SRCREV = "${AUTOREV}" 214 215 If you use the previous statement to retrieve the latest version of 216 software, you need to be sure :term:`PV` contains 217 ``${``\ :term:`SRCPV`\ ``}``. For example, suppose you have a kernel 218 recipe that inherits the :ref:`ref-classes-kernel` class and you 219 use the previous statement. In this example, ``${SRCPV}`` does not 220 automatically get into :term:`PV`. Consequently, you need to change 221 :term:`PV` in your recipe so that it does contain ``${SRCPV}``. 222 223 For more information see the 224 ":ref:`dev-manual/packages:automatically incrementing a package version number`" 225 section in the Yocto Project Development Tasks Manual. 226 227 :term:`AUTO_SYSLINUXMENU` 228 Enables creating an automatic menu for the syslinux bootloader. You 229 must set this variable in your recipe. The 230 :ref:`ref-classes-syslinux` class checks this variable. 231 232 :term:`AVAILTUNES` 233 The list of defined CPU and Application Binary Interface (ABI) 234 tunings (i.e. "tunes") available for use by the OpenEmbedded build 235 system. 236 237 The list simply presents the tunes that are available. Not all tunes 238 may be compatible with a particular machine configuration, or with 239 each other in a 240 :ref:`Multilib <dev-manual/libraries:combining multiple versions of library files into one image>` 241 configuration. 242 243 To add a tune to the list, be sure to append it with spaces using the 244 "+=" BitBake operator. Do not simply replace the list by using the 245 "=" operator. See the 246 ":ref:`bitbake-user-manual/bitbake-user-manual-metadata:basic syntax`" section in the BitBake 247 User Manual for more information. 248 249 :term:`AZ_SAS` 250 Azure Storage Shared Access Signature, when using the 251 :ref:`Azure Storage fetcher (az://) <bitbake-user-manual/bitbake-user-manual-fetching:fetchers>` 252 This variable can be defined to be used by the fetcher to authenticate 253 and gain access to non-public artifacts:: 254 255 AZ_SAS = ""se=2021-01-01&sp=r&sv=2018-11-09&sr=c&skoid=<skoid>&sig=<signature>"" 256 257 For more information see Microsoft's Azure Storage documentation at 258 https://docs.microsoft.com/en-us/azure/storage/common/storage-sas-overview 259 260 :term:`B` 261 The directory within the :term:`Build Directory` in which the 262 OpenEmbedded build system places generated objects during a recipe's 263 build process. By default, this directory is the same as the 264 :term:`S` directory, which is defined as:: 265 266 S = "${WORKDIR}/${BP}" 267 268 You can separate the (:term:`S`) directory and the directory pointed to 269 by the :term:`B` variable. Most Autotools-based recipes support 270 separating these directories. The build system defaults to using 271 separate directories for ``gcc`` and some kernel recipes. 272 273 :term:`BAD_RECOMMENDATIONS` 274 Lists "recommended-only" packages to not install. Recommended-only 275 packages are packages installed only through the 276 :term:`RRECOMMENDS` variable. You can prevent any 277 of these "recommended" packages from being installed by listing them 278 with the :term:`BAD_RECOMMENDATIONS` variable:: 279 280 BAD_RECOMMENDATIONS = "package_name package_name package_name ..." 281 282 You can set this variable globally in your ``local.conf`` file or you 283 can attach it to a specific image recipe by using the recipe name 284 override:: 285 286 BAD_RECOMMENDATIONS:pn-target_image = "package_name" 287 288 It is important to realize that if you choose to not install packages 289 using this variable and some other packages are dependent on them 290 (i.e. listed in a recipe's :term:`RDEPENDS` 291 variable), the OpenEmbedded build system ignores your request and 292 will install the packages to avoid dependency errors. 293 294 This variable is supported only when using the IPK and RPM 295 packaging backends. DEB is not supported. 296 297 See the :term:`NO_RECOMMENDATIONS` and the 298 :term:`PACKAGE_EXCLUDE` variables for related 299 information. 300 301 :term:`BASE_LIB` 302 The library directory name for the CPU or Application Binary 303 Interface (ABI) tune. The :term:`BASE_LIB` applies only in the Multilib 304 context. See the ":ref:`dev-manual/libraries:combining multiple versions of library files into one image`" 305 section in the Yocto Project Development Tasks Manual for information 306 on Multilib. 307 308 The :term:`BASE_LIB` variable is defined in the machine include files in 309 the :term:`Source Directory`. If Multilib is not 310 being used, the value defaults to "lib". 311 312 :term:`BASE_WORKDIR` 313 Points to the base of the work directory for all recipes. The default 314 value is "${TMPDIR}/work". 315 316 :term:`BB_ALLOWED_NETWORKS` 317 Specifies a space-delimited list of hosts that the fetcher is allowed 318 to use to obtain the required source code. Following are 319 considerations surrounding this variable: 320 321 - This host list is only used if :term:`BB_NO_NETWORK` is either not set 322 or set to "0". 323 324 - There is limited support for wildcard matching against the beginning of 325 host names. For example, the following setting matches 326 ``git.gnu.org``, ``ftp.gnu.org``, and ``foo.git.gnu.org``:: 327 328 BB_ALLOWED_NETWORKS = "*.gnu.org" 329 330 .. note:: 331 332 The use of the "``*``" character only works at the beginning of 333 a host name and it must be isolated from the remainder of the 334 host name. You cannot use the wildcard character in any other 335 location of the name or combined with the front part of the 336 name. 337 338 For example, ``*.foo.bar`` is supported, while ``*aa.foo.bar`` 339 is not. 340 341 - Mirrors not in the host list are skipped and logged in debug. 342 343 - Attempts to access networks not in the host list cause a failure. 344 345 Using :term:`BB_ALLOWED_NETWORKS` in conjunction with 346 :term:`PREMIRRORS` is very useful. Adding the host 347 you want to use to :term:`PREMIRRORS` results in the source code being 348 fetched from an allowed location and avoids raising an error when a 349 host that is not allowed is in a :term:`SRC_URI` 350 statement. This is because the fetcher does not attempt to use the 351 host listed in :term:`SRC_URI` after a successful fetch from the 352 :term:`PREMIRRORS` occurs. 353 354 :term:`BB_BASEHASH_IGNORE_VARS` 355 See :term:`bitbake:BB_BASEHASH_IGNORE_VARS` in the BitBake manual. 356 357 :term:`BB_CACHEDIR` 358 See :term:`bitbake:BB_CACHEDIR` in the BitBake manual. 359 360 :term:`BB_CHECK_SSL_CERTS` 361 See :term:`bitbake:BB_CHECK_SSL_CERTS` in the BitBake manual. 362 363 :term:`BB_CONSOLELOG` 364 See :term:`bitbake:BB_CONSOLELOG` in the BitBake manual. 365 366 :term:`BB_CURRENTTASK` 367 See :term:`bitbake:BB_CURRENTTASK` in the BitBake manual. 368 369 :term:`BB_DANGLINGAPPENDS_WARNONLY` 370 Defines how BitBake handles situations where an append file 371 (``.bbappend``) has no corresponding recipe file (``.bb``). This 372 condition often occurs when layers get out of sync (e.g. ``oe-core`` 373 bumps a recipe version and the old recipe no longer exists and the 374 other layer has not been updated to the new version of the recipe 375 yet). 376 377 The default fatal behavior is safest because it is the sane reaction 378 given something is out of sync. It is important to realize when your 379 changes are no longer being applied. 380 381 You can change the default behavior by setting this variable to "1", 382 "yes", or "true" in your ``local.conf`` file, which is located in the 383 :term:`Build Directory`: Here is an example:: 384 385 BB_DANGLINGAPPENDS_WARNONLY = "1" 386 387 :term:`BB_DEFAULT_TASK` 388 See :term:`bitbake:BB_DEFAULT_TASK` in the BitBake manual. 389 390 :term:`BB_DEFAULT_UMASK` 391 See :term:`bitbake:BB_DEFAULT_UMASK` in the BitBake manual. 392 393 :term:`BB_DISKMON_DIRS` 394 Monitors disk space and available inodes during the build and allows 395 you to control the build based on these parameters. 396 397 Disk space monitoring is disabled by default. To enable monitoring, 398 add the :term:`BB_DISKMON_DIRS` variable to your ``conf/local.conf`` file 399 found in the :term:`Build Directory`. Use the 400 following form: 401 402 .. code-block:: none 403 404 BB_DISKMON_DIRS = "action,dir,threshold [...]" 405 406 where: 407 408 action is: 409 ABORT: Immediately stop the build when 410 a threshold is broken. 411 STOPTASKS: Stop the build after the currently 412 executing tasks have finished when 413 a threshold is broken. 414 WARN: Issue a warning but continue the 415 build when a threshold is broken. 416 Subsequent warnings are issued as 417 defined by the BB_DISKMON_WARNINTERVAL 418 variable, which must be defined in 419 the conf/local.conf file. 420 421 dir is: 422 Any directory you choose. You can specify one or 423 more directories to monitor by separating the 424 groupings with a space. If two directories are 425 on the same device, only the first directory 426 is monitored. 427 428 threshold is: 429 Either the minimum available disk space, 430 the minimum number of free inodes, or 431 both. You must specify at least one. To 432 omit one or the other, simply omit the value. 433 Specify the threshold using G, M, K for Gbytes, 434 Mbytes, and Kbytes, respectively. If you do 435 not specify G, M, or K, Kbytes is assumed by 436 default. Do not use GB, MB, or KB. 437 438 Here are some examples:: 439 440 BB_DISKMON_DIRS = "ABORT,${TMPDIR},1G,100K WARN,${SSTATE_DIR},1G,100K" 441 BB_DISKMON_DIRS = "STOPTASKS,${TMPDIR},1G" 442 BB_DISKMON_DIRS = "ABORT,${TMPDIR},,100K" 443 444 The first example works only if you also provide the 445 :term:`BB_DISKMON_WARNINTERVAL` 446 variable in the ``conf/local.conf``. This example causes the build 447 system to immediately stop when either the disk space in 448 ``${TMPDIR}`` drops below 1 Gbyte or the available free inodes drops 449 below 100 Kbytes. Because two directories are provided with the 450 variable, the build system also issue a warning when the disk space 451 in the ``${SSTATE_DIR}`` directory drops below 1 Gbyte or the number 452 of free inodes drops below 100 Kbytes. Subsequent warnings are issued 453 during intervals as defined by the :term:`BB_DISKMON_WARNINTERVAL` 454 variable. 455 456 The second example stops the build after all currently executing 457 tasks complete when the minimum disk space in the ``${TMPDIR}`` 458 directory drops below 1 Gbyte. No disk monitoring occurs for the free 459 inodes in this case. 460 461 The final example immediately stops the build when the number of 462 free inodes in the ``${TMPDIR}`` directory drops below 100 Kbytes. No 463 disk space monitoring for the directory itself occurs in this case. 464 465 :term:`BB_DISKMON_WARNINTERVAL` 466 Defines the disk space and free inode warning intervals. To set these 467 intervals, define the variable in your ``conf/local.conf`` file in 468 the :term:`Build Directory`. 469 470 If you are going to use the :term:`BB_DISKMON_WARNINTERVAL` variable, you 471 must also use the :term:`BB_DISKMON_DIRS` 472 variable and define its action as "WARN". During the build, 473 subsequent warnings are issued each time disk space or number of free 474 inodes further reduces by the respective interval. 475 476 If you do not provide a :term:`BB_DISKMON_WARNINTERVAL` variable and you 477 do use :term:`BB_DISKMON_DIRS` with the "WARN" action, the disk 478 monitoring interval defaults to the following:: 479 480 BB_DISKMON_WARNINTERVAL = "50M,5K" 481 482 When specifying the variable in your configuration file, use the 483 following form: 484 485 .. code-block:: none 486 487 BB_DISKMON_WARNINTERVAL = "disk_space_interval,disk_inode_interval" 488 489 where: 490 491 disk_space_interval is: 492 An interval of memory expressed in either 493 G, M, or K for Gbytes, Mbytes, or Kbytes, 494 respectively. You cannot use GB, MB, or KB. 495 496 disk_inode_interval is: 497 An interval of free inodes expressed in either 498 G, M, or K for Gbytes, Mbytes, or Kbytes, 499 respectively. You cannot use GB, MB, or KB. 500 501 Here is an example:: 502 503 BB_DISKMON_DIRS = "WARN,${SSTATE_DIR},1G,100K" 504 BB_DISKMON_WARNINTERVAL = "50M,5K" 505 506 These variables cause the 507 OpenEmbedded build system to issue subsequent warnings each time the 508 available disk space further reduces by 50 Mbytes or the number of 509 free inodes further reduces by 5 Kbytes in the ``${SSTATE_DIR}`` 510 directory. Subsequent warnings based on the interval occur each time 511 a respective interval is reached beyond the initial warning (i.e. 1 512 Gbytes and 100 Kbytes). 513 514 :term:`BB_ENV_PASSTHROUGH` 515 See :term:`bitbake:BB_ENV_PASSTHROUGH` in the BitBake manual. 516 517 :term:`BB_ENV_PASSTHROUGH_ADDITIONS` 518 See :term:`bitbake:BB_ENV_PASSTHROUGH_ADDITIONS` in the BitBake manual. 519 520 :term:`BB_FETCH_PREMIRRORONLY` 521 See :term:`bitbake:BB_FETCH_PREMIRRORONLY` in the BitBake manual. 522 523 :term:`BB_FILENAME` 524 See :term:`bitbake:BB_FILENAME` in the BitBake manual. 525 526 :term:`BB_GENERATE_MIRROR_TARBALLS` 527 Causes tarballs of the source control repositories (e.g. Git 528 repositories), including metadata, to be placed in the 529 :term:`DL_DIR` directory. 530 531 For performance reasons, creating and placing tarballs of these 532 repositories is not the default action by the OpenEmbedded build 533 system:: 534 535 BB_GENERATE_MIRROR_TARBALLS = "1" 536 537 Set this variable in your 538 ``local.conf`` file in the :term:`Build Directory`. 539 540 Once you have the tarballs containing your source files, you can 541 clean up your :term:`DL_DIR` directory by deleting any Git or other 542 source control work directories. 543 544 :term:`BB_GENERATE_SHALLOW_TARBALLS` 545 See :term:`bitbake:BB_GENERATE_SHALLOW_TARBALLS` in the BitBake manual. 546 547 :term:`BB_GIT_SHALLOW` 548 See :term:`bitbake:BB_GIT_SHALLOW` in the BitBake manual. 549 550 :term:`BB_GIT_SHALLOW_DEPTH` 551 See :term:`bitbake:BB_GIT_SHALLOW_DEPTH` in the BitBake manual. 552 553 :term:`BB_HASHCHECK_FUNCTION` 554 See :term:`bitbake:BB_HASHCHECK_FUNCTION` in the BitBake manual. 555 556 :term:`BB_HASHCONFIG_IGNORE_VARS` 557 See :term:`bitbake:BB_HASHCONFIG_IGNORE_VARS` in the BitBake manual. 558 559 :term:`BB_HASHSERVE` 560 See :term:`bitbake:BB_HASHSERVE` in the BitBake manual. 561 562 :term:`BB_HASHSERVE_UPSTREAM` 563 See :term:`bitbake:BB_HASHSERVE_UPSTREAM` in the BitBake manual. 564 565 :term:`BB_INVALIDCONF` 566 See :term:`bitbake:BB_INVALIDCONF` in the BitBake manual. 567 568 :term:`BB_LOGCONFIG` 569 See :term:`bitbake:BB_LOGCONFIG` in the BitBake manual. 570 571 :term:`BB_LOGFMT` 572 See :term:`bitbake:BB_LOGFMT` in the BitBake manual. 573 574 :term:`BB_MULTI_PROVIDER_ALLOWED` 575 See :term:`bitbake:BB_MULTI_PROVIDER_ALLOWED` in the BitBake manual. 576 577 :term:`BB_NICE_LEVEL` 578 See :term:`bitbake:BB_NICE_LEVEL` in the BitBake manual. 579 580 :term:`BB_NO_NETWORK` 581 See :term:`bitbake:BB_NO_NETWORK` in the BitBake manual. 582 583 :term:`BB_NUMBER_PARSE_THREADS` 584 See :term:`bitbake:BB_NUMBER_PARSE_THREADS` in the BitBake manual. 585 586 :term:`BB_NUMBER_THREADS` 587 The maximum number of tasks BitBake should run in parallel at any one 588 time. The OpenEmbedded build system automatically configures this 589 variable to be equal to the number of cores on the build system. For 590 example, a system with a dual core processor that also uses 591 hyper-threading causes the :term:`BB_NUMBER_THREADS` variable to default 592 to "4". 593 594 For single socket systems (i.e. one CPU), you should not have to 595 override this variable to gain optimal parallelism during builds. 596 However, if you have very large systems that employ multiple physical 597 CPUs, you might want to make sure the :term:`BB_NUMBER_THREADS` variable 598 is not set higher than "20". 599 600 For more information on speeding up builds, see the 601 ":ref:`dev-manual/speeding-up-build:speeding up a build`" 602 section in the Yocto Project Development Tasks Manual. 603 604 On the other hand, if your goal is to limit the amount of system 605 resources consumed by BitBake tasks, setting :term:`BB_NUMBER_THREADS` 606 to a number lower than the number of CPU threads in your machine 607 won't be sufficient. That's because each package will still be built 608 and installed through a number of parallel jobs specified by the 609 :term:`PARALLEL_MAKE` variable, which is by default the number of CPU 610 threads in your system, and is not impacted by the 611 :term:`BB_NUMBER_THREADS` value. 612 613 So, if you set :term:`BB_NUMBER_THREADS` to "1" but don't set 614 :term:`PARALLEL_MAKE`, most of your system resources will be consumed 615 anyway. 616 617 Therefore, if you intend to reduce the load of your build system by 618 setting :term:`BB_NUMBER_THREADS` to a relatively low value compared 619 to the number of CPU threads on your system, you should also set 620 :term:`PARALLEL_MAKE` to a similarly low value. 621 622 An alternative to using :term:`BB_NUMBER_THREADS` to keep the usage 623 of build system resources under control is to use the smarter 624 :term:`BB_PRESSURE_MAX_CPU`, :term:`BB_PRESSURE_MAX_IO` or 625 :term:`BB_PRESSURE_MAX_MEMORY` controls. They will prevent BitBake 626 from starting new tasks as long as thresholds are exceeded. Anyway, 627 as with :term:`BB_NUMBER_THREADS`, such controls won't prevent the 628 tasks already being run from using all CPU threads on the system 629 if :term:`PARALLEL_MAKE` is not set to a low value. 630 631 :term:`BB_ORIGENV` 632 See :term:`bitbake:BB_ORIGENV` in the BitBake manual. 633 634 :term:`BB_PRESERVE_ENV` 635 See :term:`bitbake:BB_PRESERVE_ENV` in the BitBake manual. 636 637 :term:`BB_PRESSURE_MAX_CPU` 638 See :term:`bitbake:BB_PRESSURE_MAX_CPU` in the BitBake manual. 639 640 :term:`BB_PRESSURE_MAX_IO` 641 See :term:`bitbake:BB_PRESSURE_MAX_IO` in the BitBake manual. 642 643 :term:`BB_PRESSURE_MAX_MEMORY` 644 See :term:`bitbake:BB_PRESSURE_MAX_MEMORY` in the BitBake manual. 645 646 :term:`BB_RUNFMT` 647 See :term:`bitbake:BB_RUNFMT` in the BitBake manual. 648 649 :term:`BB_RUNTASK` 650 See :term:`bitbake:BB_RUNTASK` in the BitBake manual. 651 652 :term:`BB_SCHEDULER` 653 See :term:`bitbake:BB_SCHEDULER` in the BitBake manual. 654 655 :term:`BB_SCHEDULERS` 656 See :term:`bitbake:BB_SCHEDULERS` in the BitBake manual. 657 658 :term:`BB_SERVER_TIMEOUT` 659 Specifies the time (in seconds) after which to unload the BitBake 660 server due to inactivity. Set :term:`BB_SERVER_TIMEOUT` to determine how 661 long the BitBake server stays resident between invocations. 662 663 For example, the following statement in your ``local.conf`` file 664 instructs the server to be unloaded after 20 seconds of inactivity:: 665 666 BB_SERVER_TIMEOUT = "20" 667 668 If you want the server to never be unloaded, 669 set :term:`BB_SERVER_TIMEOUT` to "-1". 670 671 :term:`BB_SETSCENE_DEPVALID` 672 See :term:`bitbake:BB_SETSCENE_DEPVALID` in the BitBake manual. 673 674 :term:`BB_SIGNATURE_EXCLUDE_FLAGS` 675 See :term:`bitbake:BB_SIGNATURE_EXCLUDE_FLAGS` in the BitBake manual. 676 677 :term:`BB_SIGNATURE_HANDLER` 678 See :term:`bitbake:BB_SIGNATURE_HANDLER` in the BitBake manual. 679 680 :term:`BB_SRCREV_POLICY` 681 See :term:`bitbake:BB_SRCREV_POLICY` in the BitBake manual. 682 683 :term:`BB_STRICT_CHECKSUM` 684 See :term:`bitbake:BB_STRICT_CHECKSUM` in the BitBake manual. 685 686 :term:`BB_TASK_IONICE_LEVEL` 687 See :term:`bitbake:BB_TASK_IONICE_LEVEL` in the BitBake manual. 688 689 :term:`BB_TASK_NICE_LEVEL` 690 See :term:`bitbake:BB_TASK_NICE_LEVEL` in the BitBake manual. 691 692 :term:`BB_TASKHASH` 693 See :term:`bitbake:BB_TASKHASH` in the BitBake manual. 694 695 :term:`BB_VERBOSE_LOGS` 696 See :term:`bitbake:BB_VERBOSE_LOGS` in the BitBake manual. 697 698 :term:`BB_WORKERCONTEXT` 699 See :term:`bitbake:BB_WORKERCONTEXT` in the BitBake manual. 700 701 :term:`BBCLASSEXTEND` 702 Allows you to extend a recipe so that it builds variants of the 703 software. There are common variants for recipes as "natives" like 704 ``quilt-native``, which is a copy of Quilt built to run on the build 705 system; "crosses" such as ``gcc-cross``, which is a compiler built to 706 run on the build machine but produces binaries that run on the target 707 :term:`MACHINE`; ":ref:`ref-classes-nativesdk`", which 708 targets the SDK machine instead of :term:`MACHINE`; and "mulitlibs" in 709 the form "``multilib:``\ multilib_name". 710 711 To build a different variant of the recipe with a minimal amount of 712 code, it usually is as simple as adding the following to your recipe:: 713 714 BBCLASSEXTEND =+ "native nativesdk" 715 BBCLASSEXTEND =+ "multilib:multilib_name" 716 717 .. note:: 718 719 Internally, the :term:`BBCLASSEXTEND` mechanism generates recipe 720 variants by rewriting variable values and applying overrides such 721 as ``:class-native``. For example, to generate a native version of 722 a recipe, a :term:`DEPENDS` on "foo" is rewritten 723 to a :term:`DEPENDS` on "foo-native". 724 725 Even when using :term:`BBCLASSEXTEND`, the recipe is only parsed once. 726 Parsing once adds some limitations. For example, it is not 727 possible to include a different file depending on the variant, 728 since ``include`` statements are processed when the recipe is 729 parsed. 730 731 :term:`BBDEBUG` 732 See :term:`bitbake:BBDEBUG` in the BitBake manual. 733 734 :term:`BBFILE_COLLECTIONS` 735 Lists the names of configured layers. These names are used to find 736 the other ``BBFILE_*`` variables. Typically, each layer will append 737 its name to this variable in its ``conf/layer.conf`` file. 738 739 :term:`BBFILE_PATTERN` 740 Variable that expands to match files from 741 :term:`BBFILES` in a particular layer. This variable 742 is used in the ``conf/layer.conf`` file and must be suffixed with the 743 name of the specific layer (e.g. ``BBFILE_PATTERN_emenlow``). 744 745 :term:`BBFILE_PRIORITY` 746 Assigns the priority for recipe files in each layer. 747 748 This variable is useful in situations where the same recipe appears 749 in more than one layer. Setting this variable allows you to 750 prioritize a layer against other layers that contain the same recipe 751 --- effectively letting you control the precedence for the multiple 752 layers. The precedence established through this variable stands 753 regardless of a recipe's version (:term:`PV` variable). For 754 example, a layer that has a recipe with a higher :term:`PV` value but for 755 which the :term:`BBFILE_PRIORITY` is set to have a lower precedence still 756 has a lower precedence. 757 758 A larger value for the :term:`BBFILE_PRIORITY` variable results in a 759 higher precedence. For example, the value 6 has a higher precedence 760 than the value 5. If not specified, the :term:`BBFILE_PRIORITY` variable 761 is set based on layer dependencies (see the :term:`LAYERDEPENDS` variable 762 for more information. The default priority, if unspecified for a 763 layer with no dependencies, is the lowest defined priority + 1 (or 1 764 if no priorities are defined). 765 766 .. tip:: 767 768 You can use the command ``bitbake-layers show-layers`` 769 to list all configured layers along with their priorities. 770 771 :term:`BBFILES` 772 A space-separated list of recipe files BitBake uses to build 773 software. 774 775 When specifying recipe files, you can pattern match using Python's 776 `glob <https://docs.python.org/3/library/glob.html>`__ syntax. 777 For details on the syntax, see the documentation by following the 778 previous link. 779 780 :term:`BBFILES_DYNAMIC` 781 Activates content when identified layers are present. You identify 782 the layers by the collections that the layers define. 783 784 Use the :term:`BBFILES_DYNAMIC` variable to avoid ``.bbappend`` files 785 whose corresponding ``.bb`` file is in a layer that attempts to 786 modify other layers through ``.bbappend`` but does not want to 787 introduce a hard dependency on those other layers. 788 789 Use the following form for :term:`BBFILES_DYNAMIC`: 790 ``collection_name:filename_pattern``. 791 792 The following example identifies two collection names and two 793 filename patterns:: 794 795 BBFILES_DYNAMIC += " \ 796 clang-layer:${LAYERDIR}/bbappends/meta-clang/*/*/*.bbappend \ 797 core:${LAYERDIR}/bbappends/openembedded-core/meta/*/*/*.bbappend \ 798 " 799 800 This next example shows an error message that occurs because invalid 801 entries are found, which cause parsing to fail: 802 803 .. code-block:: none 804 805 ERROR: BBFILES_DYNAMIC entries must be of the form <collection name>:<filename pattern>, not: 806 /work/my-layer/bbappends/meta-security-isafw/*/*/*.bbappend 807 /work/my-layer/bbappends/openembedded-core/meta/*/*/*.bbappend 808 809 :term:`BBINCLUDED` 810 See :term:`bitbake:BBINCLUDED` in the BitBake manual. 811 812 :term:`BBINCLUDELOGS` 813 Variable that controls how BitBake displays logs on build failure. 814 815 :term:`BBINCLUDELOGS_LINES` 816 If :term:`BBINCLUDELOGS` is set, specifies the 817 maximum number of lines from the task log file to print when 818 reporting a failed task. If you do not set :term:`BBINCLUDELOGS_LINES`, 819 the entire log is printed. 820 821 :term:`BBLAYERS` 822 Lists the layers to enable during the build. This variable is defined 823 in the ``bblayers.conf`` configuration file in the :term:`Build Directory`. 824 Here is an example:: 825 826 BBLAYERS = " \ 827 /home/scottrif/poky/meta \ 828 /home/scottrif/poky/meta-poky \ 829 /home/scottrif/poky/meta-yocto-bsp \ 830 /home/scottrif/poky/meta-mykernel \ 831 " 832 833 This example enables four layers, one of which is a custom, 834 user-defined layer named ``meta-mykernel``. 835 836 :term:`BBLAYERS_FETCH_DIR` 837 See :term:`bitbake:BBLAYERS_FETCH_DIR` in the BitBake manual. 838 839 :term:`BBMASK` 840 Prevents BitBake from processing recipes and recipe append files. 841 842 You can use the :term:`BBMASK` variable to "hide" these ``.bb`` and 843 ``.bbappend`` files. BitBake ignores any recipe or recipe append 844 files that match any of the expressions. It is as if BitBake does not 845 see them at all. Consequently, matching files are not parsed or 846 otherwise used by BitBake. 847 848 The values you provide are passed to Python's regular expression 849 compiler. Consequently, the syntax follows Python's Regular 850 Expression (re) syntax. The expressions are compared against the full 851 paths to the files. For complete syntax information, see Python's 852 documentation at https://docs.python.org/3/library/re.html#regular-expression-syntax. 853 854 The following example uses a complete regular expression to tell 855 BitBake to ignore all recipe and recipe append files in the 856 ``meta-ti/recipes-misc/`` directory:: 857 858 BBMASK = "meta-ti/recipes-misc/" 859 860 If you want to mask out multiple directories or recipes, you can 861 specify multiple regular expression fragments. This next example 862 masks out multiple directories and individual recipes:: 863 864 BBMASK += "/meta-ti/recipes-misc/ meta-ti/recipes-ti/packagegroup/" 865 BBMASK += "/meta-oe/recipes-support/" 866 BBMASK += "/meta-foo/.*/openldap" 867 BBMASK += "opencv.*\.bbappend" 868 BBMASK += "lzma" 869 870 .. note:: 871 872 When specifying a directory name, use the trailing slash character 873 to ensure you match just that directory name. 874 875 :term:`BBMULTICONFIG` 876 Specifies each additional separate configuration when you are 877 building targets with multiple configurations. Use this variable in 878 your ``conf/local.conf`` configuration file. Specify a 879 multiconfigname for each configuration file you are using. For 880 example, the following line specifies three configuration files:: 881 882 BBMULTICONFIG = "configA configB configC" 883 884 Each configuration file you use must reside in a ``multiconfig`` 885 subdirectory of a configuration directory within a layer, or 886 within the :term:`Build Directory` (e.g. 887 ``build_directory/conf/multiconfig/configA.conf`` or 888 ``mylayer/conf/multiconfig/configB.conf``). 889 890 For information on how to use :term:`BBMULTICONFIG` in an environment 891 that supports building targets with multiple configurations, see the 892 ":ref:`dev-manual/building:building images for multiple targets using multiple configurations`" 893 section in the Yocto Project Development Tasks Manual. 894 895 :term:`BBPATH` 896 See :term:`bitbake:BBPATH` in the BitBake manual. 897 898 :term:`BBSERVER` 899 If defined in the BitBake environment, :term:`BBSERVER` points to the 900 BitBake remote server. 901 902 Use the following format to export the variable to the BitBake 903 environment:: 904 905 export BBSERVER=localhost:$port 906 907 By default, :term:`BBSERVER` also appears in :term:`BB_BASEHASH_IGNORE_VARS`. 908 Consequently, :term:`BBSERVER` is excluded from checksum and dependency 909 data. 910 911 :term:`BBTARGETS` 912 See :term:`bitbake:BBTARGETS` in the BitBake manual. 913 914 :term:`BINCONFIG` 915 When inheriting the :ref:`ref-classes-binconfig-disabled` class, this 916 variable specifies binary configuration scripts to disable in favor of 917 using ``pkg-config`` to query the information. The 918 :ref:`ref-classes-binconfig-disabled` class will modify the specified 919 scripts to return an error so that calls to them can be easily found 920 and replaced. 921 922 To add multiple scripts, separate them by spaces. Here is an example 923 from the ``libpng`` recipe:: 924 925 BINCONFIG = "${bindir}/libpng-config ${bindir}/libpng16-config" 926 927 :term:`BINCONFIG_GLOB` 928 When inheriting the :ref:`ref-classes-binconfig` class, 929 this variable specifies a wildcard for configuration scripts that 930 need editing. The scripts are edited to correct any paths that have 931 been set up during compilation so that they are correct for use when 932 installed into the sysroot and called by the build processes of other 933 recipes. 934 935 .. note:: 936 937 The :term:`BINCONFIG_GLOB` variable uses 938 `shell globbing <https://tldp.org/LDP/abs/html/globbingref.html>`__, 939 which is recognition and expansion of wildcards during pattern 940 matching. Shell globbing is very similar to 941 `fnmatch <https://docs.python.org/3/library/fnmatch.html#module-fnmatch>`__ 942 and `glob <https://docs.python.org/3/library/glob.html>`__. 943 944 For more information on how this variable works, see 945 ``meta/classes-recipe/binconfig.bbclass`` in the :term:`Source Directory`. 946 You can also find general 947 information on the class in the 948 ":ref:`ref-classes-binconfig`" section. 949 950 :term:`BITBAKE_UI` 951 See :term:`bitbake:BITBAKE_UI` in the BitBake manual. 952 953 :term:`BP` 954 The base recipe name and version but without any special recipe name 955 suffix (i.e. ``-native``, ``lib64-``, and so forth). :term:`BP` is 956 comprised of the following:: 957 958 ${BPN}-${PV} 959 960 :term:`BPN` 961 This variable is a version of the :term:`PN` variable with 962 common prefixes and suffixes removed, such as ``nativesdk-``, 963 ``-cross``, ``-native``, and multilib's ``lib64-`` and ``lib32-``. 964 The exact lists of prefixes and suffixes removed are specified by the 965 :term:`MLPREFIX` and 966 :term:`SPECIAL_PKGSUFFIX` variables, 967 respectively. 968 969 :term:`BUGTRACKER` 970 Specifies a URL for an upstream bug tracking website for a recipe. 971 The OpenEmbedded build system does not use this variable. Rather, the 972 variable is a useful pointer in case a bug in the software being 973 built needs to be manually reported. 974 975 :term:`BUILD_ARCH` 976 Specifies the architecture of the build host (e.g. ``i686``). The 977 OpenEmbedded build system sets the value of :term:`BUILD_ARCH` from the 978 machine name reported by the ``uname`` command. 979 980 :term:`BUILD_AS_ARCH` 981 Specifies the architecture-specific assembler flags for the build 982 host. By default, the value of :term:`BUILD_AS_ARCH` is empty. 983 984 :term:`BUILD_CC_ARCH` 985 Specifies the architecture-specific C compiler flags for the build 986 host. By default, the value of :term:`BUILD_CC_ARCH` is empty. 987 988 :term:`BUILD_CCLD` 989 Specifies the linker command to be used for the build host when the C 990 compiler is being used as the linker. By default, :term:`BUILD_CCLD` 991 points to GCC and passes as arguments the value of 992 :term:`BUILD_CC_ARCH`, assuming 993 :term:`BUILD_CC_ARCH` is set. 994 995 :term:`BUILD_CFLAGS` 996 Specifies the flags to pass to the C compiler when building for the 997 build host. When building in the ``-native`` context, 998 :term:`CFLAGS` is set to the value of this variable by 999 default. 1000 1001 :term:`BUILD_CPPFLAGS` 1002 Specifies the flags to pass to the C preprocessor (i.e. to both the C 1003 and the C++ compilers) when building for the build host. When 1004 building in the ``-native`` context, :term:`CPPFLAGS` 1005 is set to the value of this variable by default. 1006 1007 :term:`BUILD_CXXFLAGS` 1008 Specifies the flags to pass to the C++ compiler when building for the 1009 build host. When building in the ``-native`` context, 1010 :term:`CXXFLAGS` is set to the value of this variable 1011 by default. 1012 1013 :term:`BUILD_FC` 1014 Specifies the Fortran compiler command for the build host. By 1015 default, :term:`BUILD_FC` points to Gfortran and passes as arguments the 1016 value of :term:`BUILD_CC_ARCH`, assuming 1017 :term:`BUILD_CC_ARCH` is set. 1018 1019 :term:`BUILD_LD` 1020 Specifies the linker command for the build host. By default, 1021 :term:`BUILD_LD` points to the GNU linker (ld) and passes as arguments 1022 the value of :term:`BUILD_LD_ARCH`, assuming 1023 :term:`BUILD_LD_ARCH` is set. 1024 1025 :term:`BUILD_LD_ARCH` 1026 Specifies architecture-specific linker flags for the build host. By 1027 default, the value of :term:`BUILD_LD_ARCH` is empty. 1028 1029 :term:`BUILD_LDFLAGS` 1030 Specifies the flags to pass to the linker when building for the build 1031 host. When building in the ``-native`` context, 1032 :term:`LDFLAGS` is set to the value of this variable 1033 by default. 1034 1035 :term:`BUILD_OPTIMIZATION` 1036 Specifies the optimization flags passed to the C compiler when 1037 building for the build host or the SDK. The flags are passed through 1038 the :term:`BUILD_CFLAGS` and 1039 :term:`BUILDSDK_CFLAGS` default values. 1040 1041 The default value of the :term:`BUILD_OPTIMIZATION` variable is "-O2 1042 -pipe". 1043 1044 :term:`BUILD_OS` 1045 Specifies the operating system in use on the build host (e.g. 1046 "linux"). The OpenEmbedded build system sets the value of 1047 :term:`BUILD_OS` from the OS reported by the ``uname`` command --- the 1048 first word, converted to lower-case characters. 1049 1050 :term:`BUILD_PREFIX` 1051 The toolchain binary prefix used for native recipes. The OpenEmbedded 1052 build system uses the :term:`BUILD_PREFIX` value to set the 1053 :term:`TARGET_PREFIX` when building for :ref:`ref-classes-native` recipes. 1054 1055 :term:`BUILD_STRIP` 1056 Specifies the command to be used to strip debugging symbols from 1057 binaries produced for the build host. By default, :term:`BUILD_STRIP` 1058 points to 1059 ``${``\ :term:`BUILD_PREFIX`\ ``}strip``. 1060 1061 :term:`BUILD_SYS` 1062 Specifies the system, including the architecture and the operating 1063 system, to use when building for the build host (i.e. when building 1064 :ref:`ref-classes-native` recipes). 1065 1066 The OpenEmbedded build system automatically sets this variable based 1067 on :term:`BUILD_ARCH`, 1068 :term:`BUILD_VENDOR`, and 1069 :term:`BUILD_OS`. You do not need to set the 1070 :term:`BUILD_SYS` variable yourself. 1071 1072 :term:`BUILD_VENDOR` 1073 Specifies the vendor name to use when building for the build host. 1074 The default value is an empty string (""). 1075 1076 :term:`BUILDDIR` 1077 Points to the location of the :term:`Build Directory`. You can define 1078 this directory indirectly through the :ref:`structure-core-script` script 1079 by passing in a :term:`Build Directory` path when you run the script. If 1080 you run the script and do not provide a :term:`Build Directory` path, the 1081 :term:`BUILDDIR` defaults to ``build`` in the current directory. 1082 1083 :term:`BUILDHISTORY_COMMIT` 1084 When inheriting the :ref:`ref-classes-buildhistory` class, this variable 1085 specifies whether or not to commit the build history output in a local 1086 Git repository. If set to "1", this local repository will be maintained 1087 automatically by the :ref:`ref-classes-buildhistory` class and a commit 1088 will be created on every build for changes to each top-level subdirectory 1089 of the build history output (images, packages, and sdk). If you want to 1090 track changes to build history over time, you should set this value to 1091 "1". 1092 1093 By default, the :ref:`ref-classes-buildhistory` class 1094 enables committing the buildhistory output in a local Git repository:: 1095 1096 BUILDHISTORY_COMMIT ?= "1" 1097 1098 :term:`BUILDHISTORY_COMMIT_AUTHOR` 1099 When inheriting the :ref:`ref-classes-buildhistory` 1100 class, this variable specifies the author to use for each Git commit. 1101 In order for the :term:`BUILDHISTORY_COMMIT_AUTHOR` variable to work, the 1102 :term:`BUILDHISTORY_COMMIT` variable must 1103 be set to "1". 1104 1105 Git requires that the value you provide for the 1106 :term:`BUILDHISTORY_COMMIT_AUTHOR` variable takes the form of "name 1107 email@host". Providing an email address or host that is not valid 1108 does not produce an error. 1109 1110 By default, the :ref:`ref-classes-buildhistory` class sets the variable 1111 as follows:: 1112 1113 BUILDHISTORY_COMMIT_AUTHOR ?= "buildhistory <buildhistory@${DISTRO}>" 1114 1115 :term:`BUILDHISTORY_DIR` 1116 When inheriting the :ref:`ref-classes-buildhistory` 1117 class, this variable specifies the directory in which build history 1118 information is kept. For more information on how the variable works, 1119 see the :ref:`ref-classes-buildhistory` class. 1120 1121 By default, the :ref:`ref-classes-buildhistory` class sets the directory 1122 as follows:: 1123 1124 BUILDHISTORY_DIR ?= "${TOPDIR}/buildhistory" 1125 1126 :term:`BUILDHISTORY_FEATURES` 1127 When inheriting the :ref:`ref-classes-buildhistory` 1128 class, this variable specifies the build history features to be 1129 enabled. For more information on how build history works, see the 1130 ":ref:`dev-manual/build-quality:maintaining build output quality`" 1131 section in the Yocto Project Development Tasks Manual. 1132 1133 You can specify these features in the form of a space-separated list: 1134 1135 - *image:* Analysis of the contents of images, which includes the 1136 list of installed packages among other things. 1137 1138 - *package:* Analysis of the contents of individual packages. 1139 1140 - *sdk:* Analysis of the contents of the software development kit 1141 (SDK). 1142 1143 - *task:* Save output file signatures for 1144 :ref:`shared state <overview-manual/concepts:shared state cache>` 1145 (sstate) tasks. 1146 This saves one file per task and lists the SHA-256 checksums for 1147 each file staged (i.e. the output of the task). 1148 1149 By default, the :ref:`ref-classes-buildhistory` class enables the 1150 following features:: 1151 1152 BUILDHISTORY_FEATURES ?= "image package sdk" 1153 1154 :term:`BUILDHISTORY_IMAGE_FILES` 1155 When inheriting the :ref:`ref-classes-buildhistory` 1156 class, this variable specifies a list of paths to files copied from 1157 the image contents into the build history directory under an 1158 "image-files" directory in the directory for the image, so that you 1159 can track the contents of each file. The default is to copy 1160 ``/etc/passwd`` and ``/etc/group``, which allows you to monitor for 1161 changes in user and group entries. You can modify the list to include 1162 any file. Specifying an invalid path does not produce an error. 1163 Consequently, you can include files that might not always be present. 1164 1165 By default, the :ref:`ref-classes-buildhistory` class provides paths to 1166 the following files:: 1167 1168 BUILDHISTORY_IMAGE_FILES ?= "/etc/passwd /etc/group" 1169 1170 :term:`BUILDHISTORY_PATH_PREFIX_STRIP` 1171 When inheriting the :ref:`ref-classes-buildhistory` 1172 class, this variable specifies a common path prefix that should be 1173 stripped off the beginning of paths in the task signature list when the 1174 ``task`` feature is active in :term:`BUILDHISTORY_FEATURES`. This can be 1175 useful when build history is populated from multiple sources that may not 1176 all use the same top level directory. 1177 1178 By default, the :ref:`ref-classes-buildhistory` class sets the variable 1179 as follows:: 1180 1181 BUILDHISTORY_PATH_PREFIX_STRIP ?= "" 1182 1183 In this case, no prefixes will be stripped. 1184 1185 :term:`BUILDHISTORY_PUSH_REPO` 1186 When inheriting the :ref:`ref-classes-buildhistory` class, this variable 1187 optionally specifies a remote repository to which build history pushes 1188 Git changes. In order for :term:`BUILDHISTORY_PUSH_REPO` to work, 1189 :term:`BUILDHISTORY_COMMIT` must be set to "1". 1190 1191 The repository should correspond to a remote address that specifies a 1192 repository as understood by Git, or alternatively to a remote name 1193 that you have set up manually using ``git remote`` within the local 1194 repository. 1195 1196 By default, the :ref:`ref-classes-buildhistory` class sets the variable 1197 as follows:: 1198 1199 BUILDHISTORY_PUSH_REPO ?= "" 1200 1201 :term:`BUILDNAME` 1202 See :term:`bitbake:BUILDNAME` in the BitBake manual. 1203 1204 :term:`BUILDSDK_CFLAGS` 1205 Specifies the flags to pass to the C compiler when building for the 1206 SDK. When building in the ``nativesdk-`` context, 1207 :term:`CFLAGS` is set to the value of this variable by 1208 default. 1209 1210 :term:`BUILDSDK_CPPFLAGS` 1211 Specifies the flags to pass to the C pre-processor (i.e. to both the 1212 C and the C++ compilers) when building for the SDK. When building in 1213 the ``nativesdk-`` context, :term:`CPPFLAGS` is set 1214 to the value of this variable by default. 1215 1216 :term:`BUILDSDK_CXXFLAGS` 1217 Specifies the flags to pass to the C++ compiler when building for the 1218 SDK. When building in the ``nativesdk-`` context, 1219 :term:`CXXFLAGS` is set to the value of this variable 1220 by default. 1221 1222 :term:`BUILDSDK_LDFLAGS` 1223 Specifies the flags to pass to the linker when building for the SDK. 1224 When building in the ``nativesdk-`` context, 1225 :term:`LDFLAGS` is set to the value of this variable 1226 by default. 1227 1228 :term:`BUILDSTATS_BASE` 1229 Points to the location of the directory that holds build statistics 1230 when you use and enable the :ref:`ref-classes-buildstats` class. The 1231 :term:`BUILDSTATS_BASE` directory defaults to 1232 ``${``\ :term:`TMPDIR`\ ``}/buildstats/``. 1233 1234 :term:`BUSYBOX_SPLIT_SUID` 1235 For the BusyBox recipe, specifies whether to split the output 1236 executable file into two parts: one for features that require 1237 ``setuid root``, and one for the remaining features (i.e. those that 1238 do not require ``setuid root``). 1239 1240 The :term:`BUSYBOX_SPLIT_SUID` variable defaults to "1", which results in 1241 splitting the output executable file. Set the variable to "0" to get 1242 a single output executable file. 1243 1244 :term:`BZRDIR` 1245 See :term:`bitbake:BZRDIR` in the BitBake manual. 1246 1247 :term:`CACHE` 1248 Specifies the directory BitBake uses to store a cache of the 1249 :term:`Metadata` so it does not need to be parsed every time 1250 BitBake is started. 1251 1252 :term:`CC` 1253 The minimal command and arguments used to run the C compiler. 1254 1255 :term:`CFLAGS` 1256 Specifies the flags to pass to the C compiler. This variable is 1257 exported to an environment variable and thus made visible to the 1258 software being built during the compilation step. 1259 1260 Default initialization for :term:`CFLAGS` varies depending on what is 1261 being built: 1262 1263 - :term:`TARGET_CFLAGS` when building for the 1264 target 1265 1266 - :term:`BUILD_CFLAGS` when building for the 1267 build host (i.e. ``-native``) 1268 1269 - :term:`BUILDSDK_CFLAGS` when building for 1270 an SDK (i.e. ``nativesdk-``) 1271 1272 :term:`CLASSOVERRIDE` 1273 An internal variable specifying the special class override that 1274 should currently apply (e.g. "class-target", "class-native", and so 1275 forth). The classes that use this variable (e.g. 1276 :ref:`ref-classes-native`, :ref:`ref-classes-nativesdk`, and so forth) 1277 set the variable to appropriate values. 1278 1279 .. note:: 1280 1281 :term:`CLASSOVERRIDE` gets its default "class-target" value from the 1282 ``bitbake.conf`` file. 1283 1284 As an example, the following override allows you to install extra 1285 files, but only when building for the target:: 1286 1287 do_install:append:class-target() { 1288 install my-extra-file ${D}${sysconfdir} 1289 } 1290 1291 Here is an example where ``FOO`` is set to 1292 "native" when building for the build host, and to "other" when not 1293 building for the build host:: 1294 1295 FOO:class-native = "native" 1296 FOO = "other" 1297 1298 The underlying mechanism behind :term:`CLASSOVERRIDE` is simply 1299 that it is included in the default value of 1300 :term:`OVERRIDES`. 1301 1302 :term:`CLEANBROKEN` 1303 If set to "1" within a recipe, :term:`CLEANBROKEN` specifies that the 1304 ``make clean`` command does not work for the software being built. 1305 Consequently, the OpenEmbedded build system will not try to run 1306 ``make clean`` during the :ref:`ref-tasks-configure` 1307 task, which is the default behavior. 1308 1309 :term:`COMBINED_FEATURES` 1310 Provides a list of hardware features that are enabled in both 1311 :term:`MACHINE_FEATURES` and 1312 :term:`DISTRO_FEATURES`. This select list of 1313 features contains features that make sense to be controlled both at 1314 the machine and distribution configuration level. For example, the 1315 "bluetooth" feature requires hardware support but should also be 1316 optional at the distribution level, in case the hardware supports 1317 Bluetooth but you do not ever intend to use it. 1318 1319 :term:`COMMERCIAL_AUDIO_PLUGINS` 1320 This variable is specific to the :yocto_git:`GStreamer recipes 1321 </poky/tree/meta/recipes-multimedia/gstreamer/gstreamer1.0-meta-base.bb>`. 1322 It allows to build the GStreamer `"ugly" 1323 <https://github.com/GStreamer/gst-plugins-ugly>`__ and 1324 `"bad" <https://github.com/GStreamer/gst-plugins-bad>`__ audio plugins. 1325 1326 See the :ref:`dev-manual/licenses:other variables related to commercial licenses` 1327 section for usage details. 1328 1329 :term:`COMMERCIAL_VIDEO_PLUGINS` 1330 This variable is specific to the :yocto_git:`GStreamer recipes 1331 </poky/tree/meta/recipes-multimedia/gstreamer/gstreamer1.0-meta-base.bb>`. 1332 It allows to build the GStreamer `"ugly" 1333 <https://github.com/GStreamer/gst-plugins-ugly>`__ and 1334 `"bad" <https://github.com/GStreamer/gst-plugins-bad>`__ video plugins. 1335 1336 See the :ref:`dev-manual/licenses:other variables related to commercial licenses` 1337 section for usage details. 1338 1339 :term:`COMMON_LICENSE_DIR` 1340 Points to ``meta/files/common-licenses`` in the 1341 :term:`Source Directory`, which is where generic license 1342 files reside. 1343 1344 :term:`COMPATIBLE_HOST` 1345 A regular expression that resolves to one or more hosts (when the 1346 recipe is native) or one or more targets (when the recipe is 1347 non-native) with which a recipe is compatible. The regular expression 1348 is matched against :term:`HOST_SYS`. You can use the 1349 variable to stop recipes from being built for classes of systems with 1350 which the recipes are not compatible. Stopping these builds is 1351 particularly useful with kernels. The variable also helps to increase 1352 parsing speed since the build system skips parsing recipes not 1353 compatible with the current system. 1354 1355 :term:`COMPATIBLE_MACHINE` 1356 A regular expression that resolves to one or more target machines 1357 with which a recipe is compatible. The regular expression is matched 1358 against :term:`MACHINEOVERRIDES`. You can use 1359 the variable to stop recipes from being built for machines with which 1360 the recipes are not compatible. Stopping these builds is particularly 1361 useful with kernels. The variable also helps to increase parsing 1362 speed since the build system skips parsing recipes not compatible 1363 with the current machine. 1364 1365 :term:`COMPLEMENTARY_GLOB` 1366 Defines wildcards to match when installing a list of complementary 1367 packages for all the packages explicitly (or implicitly) installed in 1368 an image. 1369 1370 The :term:`COMPLEMENTARY_GLOB` variable uses Unix filename pattern matching 1371 (`fnmatch <https://docs.python.org/3/library/fnmatch.html#module-fnmatch>`__), 1372 which is similar to the Unix style pathname pattern expansion 1373 (`glob <https://docs.python.org/3/library/glob.html>`__). 1374 1375 The resulting list of complementary packages is associated with an 1376 item that can be added to 1377 :term:`IMAGE_FEATURES`. An example usage of 1378 this is the "dev-pkgs" item that when added to :term:`IMAGE_FEATURES` 1379 will install -dev packages (containing headers and other development 1380 files) for every package in the image. 1381 1382 To add a new feature item pointing to a wildcard, use a variable flag 1383 to specify the feature item name and use the value to specify the 1384 wildcard. Here is an example:: 1385 1386 COMPLEMENTARY_GLOB[dev-pkgs] = '*-dev' 1387 1388 .. note:: 1389 1390 When installing complementary packages, recommends relationships 1391 (set via :term:`RRECOMMENDS`) are always ignored. 1392 1393 :term:`COMPONENTS_DIR` 1394 Stores sysroot components for each recipe. The OpenEmbedded build 1395 system uses :term:`COMPONENTS_DIR` when constructing recipe-specific 1396 sysroots for other recipes. 1397 1398 The default is 1399 "``${``\ :term:`STAGING_DIR`\ ``}-components``." 1400 (i.e. 1401 "``${``\ :term:`TMPDIR`\ ``}/sysroots-components``"). 1402 1403 :term:`CONF_VERSION` 1404 Tracks the version of the local configuration file (i.e. 1405 ``local.conf``). The value for :term:`CONF_VERSION` increments each time 1406 ``build/conf/`` compatibility changes. 1407 1408 :term:`CONFFILES` 1409 Identifies editable or configurable files that are part of a package. 1410 If the Package Management System (PMS) is being used to update 1411 packages on the target system, it is possible that configuration 1412 files you have changed after the original installation and that you 1413 now want to remain unchanged are overwritten. In other words, 1414 editable files might exist in the package that you do not want reset 1415 as part of the package update process. You can use the :term:`CONFFILES` 1416 variable to list the files in the package that you wish to prevent 1417 the PMS from overwriting during this update process. 1418 1419 To use the :term:`CONFFILES` variable, provide a package name override 1420 that identifies the resulting package. Then, provide a 1421 space-separated list of files. Here is an example:: 1422 1423 CONFFILES:${PN} += "${sysconfdir}/file1 \ 1424 ${sysconfdir}/file2 ${sysconfdir}/file3" 1425 1426 There is a relationship between the :term:`CONFFILES` and :term:`FILES` 1427 variables. The files listed within :term:`CONFFILES` must be a subset of 1428 the files listed within :term:`FILES`. Because the configuration files 1429 you provide with :term:`CONFFILES` are simply being identified so that 1430 the PMS will not overwrite them, it makes sense that the files must 1431 already be included as part of the package through the :term:`FILES` 1432 variable. 1433 1434 .. note:: 1435 1436 When specifying paths as part of the :term:`CONFFILES` variable, it is 1437 good practice to use appropriate path variables. 1438 For example, ``${sysconfdir}`` rather than ``/etc`` or ``${bindir}`` 1439 rather than ``/usr/bin``. You can find a list of these variables at 1440 the top of the ``meta/conf/bitbake.conf`` file in the 1441 :term:`Source Directory`. 1442 1443 :term:`CONFIG_INITRAMFS_SOURCE` 1444 Identifies the initial RAM filesystem (:term:`Initramfs`) source files. The 1445 OpenEmbedded build system receives and uses this kernel Kconfig 1446 variable as an environment variable. By default, the variable is set 1447 to null (""). 1448 1449 The :term:`CONFIG_INITRAMFS_SOURCE` can be either a single cpio archive 1450 with a ``.cpio`` suffix or a space-separated list of directories and 1451 files for building the :term:`Initramfs` image. A cpio archive should contain 1452 a filesystem archive to be used as an :term:`Initramfs` image. Directories 1453 should contain a filesystem layout to be included in the :term:`Initramfs` 1454 image. Files should contain entries according to the format described 1455 by the ``usr/gen_init_cpio`` program in the kernel tree. 1456 1457 If you specify multiple directories and files, the :term:`Initramfs` image 1458 will be the aggregate of all of them. 1459 1460 For information on creating an :term:`Initramfs`, see the 1461 ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" section 1462 in the Yocto Project Development Tasks Manual. 1463 1464 :term:`CONFIG_SITE` 1465 A list of files that contains ``autoconf`` test results relevant to 1466 the current build. This variable is used by the Autotools utilities 1467 when running ``configure``. 1468 1469 :term:`CONFIGURE_FLAGS` 1470 The minimal arguments for GNU configure. 1471 1472 :term:`CONFLICT_DISTRO_FEATURES` 1473 When inheriting the :ref:`ref-classes-features_check` 1474 class, this variable identifies distribution features that would be 1475 in conflict should the recipe be built. In other words, if the 1476 :term:`CONFLICT_DISTRO_FEATURES` variable lists a feature that also 1477 appears in :term:`DISTRO_FEATURES` within the current configuration, then 1478 the recipe will be skipped, and if the build system attempts to build 1479 the recipe then an error will be triggered. 1480 1481 :term:`CONVERSION_CMD` 1482 This variable is used for storing image conversion commands. 1483 Image conversion can convert an image into different objects like: 1484 1485 - Compressed version of the image 1486 1487 - Checksums for the image 1488 1489 An example of :term:`CONVERSION_CMD` from :ref:`ref-classes-image_types` 1490 class is:: 1491 1492 CONVERSION_CMD:lzo = "lzop -9 ${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.${type}" 1493 1494 :term:`COPY_LIC_DIRS` 1495 If set to "1" along with the 1496 :term:`COPY_LIC_MANIFEST` variable, the 1497 OpenEmbedded build system copies into the image the license files, 1498 which are located in ``/usr/share/common-licenses``, for each 1499 package. The license files are placed in directories within the image 1500 itself during build time. 1501 1502 .. note:: 1503 1504 The :term:`COPY_LIC_DIRS` does not offer a path for adding licenses for 1505 newly installed packages to an image, which might be most suitable for 1506 read-only filesystems that cannot be upgraded. See the 1507 :term:`LICENSE_CREATE_PACKAGE` variable for additional information. 1508 You can also reference the ":ref:`dev-manual/licenses:providing license text`" 1509 section in the Yocto Project Development Tasks Manual for 1510 information on providing license text. 1511 1512 :term:`COPY_LIC_MANIFEST` 1513 If set to "1", the OpenEmbedded build system copies the license 1514 manifest for the image to 1515 ``/usr/share/common-licenses/license.manifest`` within the image 1516 itself during build time. 1517 1518 .. note:: 1519 1520 The :term:`COPY_LIC_MANIFEST` does not offer a path for adding licenses for 1521 newly installed packages to an image, which might be most suitable for 1522 read-only filesystems that cannot be upgraded. See the 1523 :term:`LICENSE_CREATE_PACKAGE` variable for additional information. 1524 You can also reference the ":ref:`dev-manual/licenses:providing license text`" 1525 section in the Yocto Project Development Tasks Manual for 1526 information on providing license text. 1527 1528 :term:`COPYLEFT_LICENSE_EXCLUDE` 1529 A space-separated list of licenses to exclude from the source archived by 1530 the :ref:`ref-classes-archiver` class. In other words, if a license in a 1531 recipe's :term:`LICENSE` value is in the value of 1532 :term:`COPYLEFT_LICENSE_EXCLUDE`, then its source is not archived by the 1533 class. 1534 1535 .. note:: 1536 1537 The :term:`COPYLEFT_LICENSE_EXCLUDE` variable takes precedence over the 1538 :term:`COPYLEFT_LICENSE_INCLUDE` variable. 1539 1540 The default value, which is "CLOSED Proprietary", for 1541 :term:`COPYLEFT_LICENSE_EXCLUDE` is set by the 1542 :ref:`ref-classes-copyleft_filter` class, which 1543 is inherited by the :ref:`ref-classes-archiver` class. 1544 1545 :term:`COPYLEFT_LICENSE_INCLUDE` 1546 A space-separated list of licenses to include in the source archived 1547 by the :ref:`ref-classes-archiver` class. In other 1548 words, if a license in a recipe's :term:`LICENSE` 1549 value is in the value of :term:`COPYLEFT_LICENSE_INCLUDE`, then its 1550 source is archived by the class. 1551 1552 The default value is set by the :ref:`ref-classes-copyleft_filter` class, 1553 which is inherited by the :ref:`ref-classes-archiver` class. The default 1554 value includes "GPL*", "LGPL*", and "AGPL*". 1555 1556 :term:`COPYLEFT_PN_EXCLUDE` 1557 A list of recipes to exclude in the source archived by the 1558 :ref:`ref-classes-archiver` class. The :term:`COPYLEFT_PN_EXCLUDE` 1559 variable overrides the license inclusion and exclusion caused through the 1560 :term:`COPYLEFT_LICENSE_INCLUDE` and :term:`COPYLEFT_LICENSE_EXCLUDE` 1561 variables, respectively. 1562 1563 The default value, which is "" indicating to not explicitly exclude 1564 any recipes by name, for :term:`COPYLEFT_PN_EXCLUDE` is set by the 1565 :ref:`ref-classes-copyleft_filter` class, which is inherited by the 1566 :ref:`ref-classes-archiver` class. 1567 1568 :term:`COPYLEFT_PN_INCLUDE` 1569 A list of recipes to include in the source archived by the 1570 :ref:`ref-classes-archiver` class. The :term:`COPYLEFT_PN_INCLUDE` 1571 variable overrides the license inclusion and exclusion caused through the 1572 :term:`COPYLEFT_LICENSE_INCLUDE` and :term:`COPYLEFT_LICENSE_EXCLUDE` 1573 variables, respectively. 1574 1575 The default value, which is "" indicating to not explicitly include 1576 any recipes by name, for :term:`COPYLEFT_PN_INCLUDE` is set by the 1577 :ref:`ref-classes-copyleft_filter` class, which is inherited by the 1578 :ref:`ref-classes-archiver` class. 1579 1580 :term:`COPYLEFT_RECIPE_TYPES` 1581 A space-separated list of recipe types to include in the source 1582 archived by the :ref:`archiver <ref-classes-archiver>` class. 1583 Recipe types are ``target``, :ref:`ref-classes-native`, 1584 :ref:`ref-classes-nativesdk`, :ref:`ref-classes-cross`, 1585 :ref:`ref-classes-crosssdk`, and :ref:`ref-classes-cross-canadian`. 1586 1587 The default value, which is "target*", for :term:`COPYLEFT_RECIPE_TYPES` 1588 is set by the :ref:`ref-classes-copyleft_filter` class, which is 1589 inherited by the :ref:`ref-classes-archiver` class. 1590 1591 :term:`CORE_IMAGE_EXTRA_INSTALL` 1592 Specifies the list of packages to be added to the image. You should 1593 only set this variable in the ``local.conf`` configuration file found 1594 in the :term:`Build Directory`. 1595 1596 This variable replaces ``POKY_EXTRA_INSTALL``, which is no longer 1597 supported. 1598 1599 :term:`COREBASE` 1600 Specifies the parent directory of the OpenEmbedded-Core Metadata 1601 layer (i.e. ``meta``). 1602 1603 It is an important distinction that :term:`COREBASE` points to the parent 1604 of this layer and not the layer itself. Consider an example where you 1605 have cloned the Poky Git repository and retained the ``poky`` name 1606 for your local copy of the repository. In this case, :term:`COREBASE` 1607 points to the ``poky`` folder because it is the parent directory of 1608 the ``poky/meta`` layer. 1609 1610 :term:`COREBASE_FILES` 1611 Lists files from the :term:`COREBASE` directory that 1612 should be copied other than the layers listed in the 1613 ``bblayers.conf`` file. The :term:`COREBASE_FILES` variable allows 1614 to copy metadata from the OpenEmbedded build system 1615 into the extensible SDK. 1616 1617 Explicitly listing files in :term:`COREBASE` is needed because it 1618 typically contains build directories and other files that should not 1619 normally be copied into the extensible SDK. Consequently, the value 1620 of :term:`COREBASE_FILES` is used in order to only copy the files that 1621 are actually needed. 1622 1623 :term:`CPP` 1624 The minimal command and arguments used to run the C preprocessor. 1625 1626 :term:`CPPFLAGS` 1627 Specifies the flags to pass to the C pre-processor (i.e. to both the 1628 C and the C++ compilers). This variable is exported to an environment 1629 variable and thus made visible to the software being built during the 1630 compilation step. 1631 1632 Default initialization for :term:`CPPFLAGS` varies depending on what is 1633 being built: 1634 1635 - :term:`TARGET_CPPFLAGS` when building for 1636 the target 1637 1638 - :term:`BUILD_CPPFLAGS` when building for the 1639 build host (i.e. ``-native``) 1640 1641 - :term:`BUILDSDK_CPPFLAGS` when building 1642 for an SDK (i.e. ``nativesdk-``) 1643 1644 :term:`CROSS_COMPILE` 1645 The toolchain binary prefix for the target tools. The 1646 :term:`CROSS_COMPILE` variable is the same as the 1647 :term:`TARGET_PREFIX` variable. 1648 1649 .. note:: 1650 1651 The OpenEmbedded build system sets the :term:`CROSS_COMPILE` 1652 variable only in certain contexts (e.g. when building for kernel 1653 and kernel module recipes). 1654 1655 :term:`CVE_CHECK_IGNORE` 1656 The list of CVE IDs which are ignored. Here is 1657 an example from the :oe_layerindex:`Python3 recipe</layerindex/recipe/23823>`:: 1658 1659 # This is windows only issue. 1660 CVE_CHECK_IGNORE += "CVE-2020-15523" 1661 1662 :term:`CVE_CHECK_SHOW_WARNINGS` 1663 Specifies whether or not the :ref:`ref-classes-cve-check` 1664 class should generate warning messages on the console when unpatched 1665 CVEs are found. The default is "1", but you may wish to set it to "0" if 1666 you are already examining/processing the logs after the build has 1667 completed and thus do not need the warning messages. 1668 1669 :term:`CVE_CHECK_SKIP_RECIPE` 1670 The list of package names (:term:`PN`) for which 1671 CVEs (Common Vulnerabilities and Exposures) are ignored. 1672 1673 :term:`CVE_DB_UPDATE_INTERVAL` 1674 Specifies the CVE database update interval in seconds, as used by 1675 ``cve-update-db-native``. The default value is "86400" i.e. once a day 1676 (24*60*60). If the value is set to "0" then the update will be forced 1677 every time. Alternatively, a negative value e.g. "-1" will disable 1678 updates entirely. 1679 1680 :term:`CVE_PRODUCT` 1681 In a recipe, defines the name used to match the recipe name 1682 against the name in the upstream `NIST CVE database <https://nvd.nist.gov/>`__. 1683 1684 The default is ${:term:`BPN`} (except for recipes that inherit the 1685 :ref:`ref-classes-pypi` class where it is set based upon 1686 :term:`PYPI_PACKAGE`). If it does not match the name in the NIST CVE 1687 database or matches with multiple entries in the database, the default 1688 value needs to be changed. 1689 1690 Here is an example from the :oe_layerindex:`Berkeley DB recipe </layerindex/recipe/544>`:: 1691 1692 CVE_PRODUCT = "oracle_berkeley_db berkeley_db" 1693 1694 Sometimes the product name is not specific enough, for example 1695 "tar" has been matching CVEs for the GNU ``tar`` package and also 1696 the ``node-tar`` node.js extension. To avoid this problem, use the 1697 vendor name as a prefix. The syntax for this is:: 1698 1699 CVE_PRODUCT = "vendor:package" 1700 1701 :term:`CVE_VERSION` 1702 In a recipe, defines the version used to match the recipe version 1703 against the version in the `NIST CVE database <https://nvd.nist.gov/>`__ 1704 when usign :ref:`ref-classes-cve-check`. 1705 1706 The default is ${:term:`PV`} but if recipes use custom version numbers 1707 which do not map to upstream software component release versions and the versions 1708 used in the CVE database, then this variable can be used to set the 1709 version number for :ref:`ref-classes-cve-check`. Example:: 1710 1711 CVE_VERSION = "2.39" 1712 1713 :term:`CVSDIR` 1714 The directory in which files checked out under the CVS system are 1715 stored. 1716 1717 :term:`CXX` 1718 The minimal command and arguments used to run the C++ compiler. 1719 1720 :term:`CXXFLAGS` 1721 Specifies the flags to pass to the C++ compiler. This variable is 1722 exported to an environment variable and thus made visible to the 1723 software being built during the compilation step. 1724 1725 Default initialization for :term:`CXXFLAGS` varies depending on what is 1726 being built: 1727 1728 - :term:`TARGET_CXXFLAGS` when building for 1729 the target 1730 1731 - :term:`BUILD_CXXFLAGS` when building for the 1732 build host (i.e. ``-native``) 1733 1734 - :term:`BUILDSDK_CXXFLAGS` when building 1735 for an SDK (i.e. ``nativesdk-``) 1736 1737 :term:`D` 1738 The destination directory. The location in the :term:`Build Directory` 1739 where components are installed by the 1740 :ref:`ref-tasks-install` task. This location defaults 1741 to:: 1742 1743 ${WORKDIR}/image 1744 1745 .. note:: 1746 1747 Tasks that read from or write to this directory should run under 1748 :ref:`fakeroot <overview-manual/concepts:fakeroot and pseudo>`. 1749 1750 :term:`DATE` 1751 The date the build was started. Dates appear using the year, month, 1752 and day (YMD) format (e.g. "20150209" for February 9th, 2015). 1753 1754 :term:`DATETIME` 1755 The date and time on which the current build started. The format is 1756 suitable for timestamps. 1757 1758 :term:`DEBIAN_NOAUTONAME` 1759 When the :ref:`ref-classes-debian` class is inherited, 1760 which is the default behavior, :term:`DEBIAN_NOAUTONAME` specifies a 1761 particular package should not be renamed according to Debian library 1762 package naming. You must use the package name as an override when you 1763 set this variable. Here is an example from the ``fontconfig`` recipe:: 1764 1765 DEBIAN_NOAUTONAME:fontconfig-utils = "1" 1766 1767 :term:`DEBIANNAME` 1768 When the :ref:`ref-classes-debian` class is inherited, 1769 which is the default behavior, :term:`DEBIANNAME` allows you to override 1770 the library name for an individual package. Overriding the library 1771 name in these cases is rare. You must use the package name as an 1772 override when you set this variable. Here is an example from the 1773 ``dbus`` recipe:: 1774 1775 DEBIANNAME:${PN} = "dbus-1" 1776 1777 :term:`DEBUG_BUILD` 1778 Specifies to build packages with debugging information. This 1779 influences the value of the :term:`SELECTED_OPTIMIZATION` variable. 1780 1781 :term:`DEBUG_OPTIMIZATION` 1782 The options to pass in :term:`TARGET_CFLAGS` and :term:`CFLAGS` when 1783 compiling a system for debugging. This variable defaults to "-O 1784 -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe". 1785 1786 :term:`DEBUG_PREFIX_MAP` 1787 Allows to set C compiler options, such as ``-fdebug-prefix-map``, 1788 ``-fmacro-prefix-map``, and ``-ffile-prefix-map``, which allow to 1789 replace build-time paths by install-time ones in the debugging sections 1790 of binaries. This makes compiler output files location independent, 1791 at the cost of having to pass an extra command to tell the debugger 1792 where source files are. 1793 1794 This is used by the Yocto Project to guarantee 1795 :doc:`/test-manual/reproducible-builds` even when the source code of 1796 a package uses the ``__FILE__`` or ``assert()`` macros. See the 1797 `reproducible-builds.org <https://reproducible-builds.org/docs/build-path/>`__ 1798 website for details. 1799 1800 This variable is set in the ``meta/conf/bitbake.conf`` file. It is 1801 not intended to be user-configurable. 1802 1803 :term:`DEFAULT_PREFERENCE` 1804 Specifies a weak bias for recipe selection priority. 1805 1806 The most common usage of this is variable is to set it to "-1" within 1807 a recipe for a development version of a piece of software. Using the 1808 variable in this way causes the stable version of the recipe to build 1809 by default in the absence of :term:`PREFERRED_VERSION` being used to 1810 build the development version. 1811 1812 .. note:: 1813 1814 The bias provided by :term:`DEFAULT_PREFERENCE` is weak and is overridden 1815 by :term:`BBFILE_PRIORITY` if that variable is different between two 1816 layers that contain different versions of the same recipe. 1817 1818 :term:`DEFAULTTUNE` 1819 The default CPU and Application Binary Interface (ABI) tunings (i.e. 1820 the "tune") used by the OpenEmbedded build system. The 1821 :term:`DEFAULTTUNE` helps define 1822 :term:`TUNE_FEATURES`. 1823 1824 The default tune is either implicitly or explicitly set by the 1825 machine (:term:`MACHINE`). However, you can override 1826 the setting using available tunes as defined with 1827 :term:`AVAILTUNES`. 1828 1829 :term:`DEPENDS` 1830 Lists a recipe's build-time dependencies. These are dependencies on 1831 other recipes whose contents (e.g. headers and shared libraries) are 1832 needed by the recipe at build time. 1833 1834 As an example, consider a recipe ``foo`` that contains the following 1835 assignment:: 1836 1837 DEPENDS = "bar" 1838 1839 The practical effect of the previous assignment is that all files 1840 installed by bar will be available in the appropriate staging sysroot, 1841 given by the :term:`STAGING_DIR* <STAGING_DIR>` variables, by the time 1842 the :ref:`ref-tasks-configure` task for ``foo`` runs. This mechanism is 1843 implemented by having :ref:`ref-tasks-configure` depend on the 1844 :ref:`ref-tasks-populate_sysroot` task of each recipe listed in 1845 :term:`DEPENDS`, through a 1846 ``[``\ :ref:`deptask <bitbake-user-manual/bitbake-user-manual-metadata:variable flags>`\ ``]`` 1847 declaration in the :ref:`ref-classes-base` class. 1848 1849 .. note:: 1850 1851 It seldom is necessary to reference, for example, :term:`STAGING_DIR_HOST` 1852 explicitly. The standard classes and build-related variables are 1853 configured to automatically use the appropriate staging sysroots. 1854 1855 As another example, :term:`DEPENDS` can also be used to add utilities 1856 that run on the build machine during the build. For example, a recipe 1857 that makes use of a code generator built by the recipe ``codegen`` 1858 might have the following:: 1859 1860 DEPENDS = "codegen-native" 1861 1862 For more 1863 information, see the :ref:`ref-classes-native` class and 1864 the :term:`EXTRANATIVEPATH` variable. 1865 1866 .. note:: 1867 1868 - :term:`DEPENDS` is a list of recipe names. Or, to be more precise, 1869 it is a list of :term:`PROVIDES` names, which 1870 usually match recipe names. Putting a package name such as 1871 "foo-dev" in :term:`DEPENDS` does not make sense. Use "foo" 1872 instead, as this will put files from all the packages that make 1873 up ``foo``, which includes those from ``foo-dev``, into the 1874 sysroot. 1875 1876 - One recipe having another recipe in :term:`DEPENDS` does not by 1877 itself add any runtime dependencies between the packages 1878 produced by the two recipes. However, as explained in the 1879 ":ref:`overview-manual/concepts:automatically added runtime dependencies`" 1880 section in the Yocto Project Overview and Concepts Manual, 1881 runtime dependencies will often be added automatically, meaning 1882 :term:`DEPENDS` alone is sufficient for most recipes. 1883 1884 - Counterintuitively, :term:`DEPENDS` is often necessary even for 1885 recipes that install precompiled components. For example, if 1886 ``libfoo`` is a precompiled library that links against 1887 ``libbar``, then linking against ``libfoo`` requires both 1888 ``libfoo`` and ``libbar`` to be available in the sysroot. 1889 Without a :term:`DEPENDS` from the recipe that installs ``libfoo`` 1890 to the recipe that installs ``libbar``, other recipes might 1891 fail to link against ``libfoo``. 1892 1893 For information on runtime dependencies, see the :term:`RDEPENDS` 1894 variable. You can also see the 1895 ":ref:`bitbake-user-manual/bitbake-user-manual-metadata:tasks`" and 1896 ":ref:`bitbake-user-manual/bitbake-user-manual-execution:dependencies`" 1897 sections in the BitBake User Manual for additional information on tasks 1898 and dependencies. 1899 1900 :term:`DEPLOY_DIR` 1901 Points to the general area that the OpenEmbedded build system uses to 1902 place images, packages, SDKs, and other output files that are ready 1903 to be used outside of the build system. By default, this directory 1904 resides within the :term:`Build Directory` as ``${TMPDIR}/deploy``. 1905 1906 For more information on the structure of the Build Directory, see 1907 ":ref:`ref-manual/structure:the build directory --- \`\`build/\`\``" section. 1908 For more detail on the contents of the ``deploy`` directory, see the 1909 ":ref:`overview-manual/concepts:images`", 1910 ":ref:`overview-manual/concepts:package feeds`", and 1911 ":ref:`overview-manual/concepts:application development sdk`" sections all in the 1912 Yocto Project Overview and Concepts Manual. 1913 1914 :term:`DEPLOY_DIR_DEB` 1915 Points to the area that the OpenEmbedded build system uses to place 1916 Debian packages that are ready to be used outside of the build 1917 system. This variable applies only when :term:`PACKAGE_CLASSES` contains 1918 ":ref:`ref-classes-package_deb`". 1919 1920 The BitBake configuration file initially defines the 1921 :term:`DEPLOY_DIR_DEB` variable as a sub-folder of 1922 :term:`DEPLOY_DIR`:: 1923 1924 DEPLOY_DIR_DEB = "${DEPLOY_DIR}/deb" 1925 1926 The :ref:`ref-classes-package_deb` class uses the 1927 :term:`DEPLOY_DIR_DEB` variable to make sure the 1928 :ref:`ref-tasks-package_write_deb` task 1929 writes Debian packages into the appropriate folder. For more 1930 information on how packaging works, see the 1931 ":ref:`overview-manual/concepts:package feeds`" section 1932 in the Yocto Project Overview and Concepts Manual. 1933 1934 :term:`DEPLOY_DIR_IMAGE` 1935 Points to the area that the OpenEmbedded build system uses to place 1936 images and other associated output files that are ready to be 1937 deployed onto the target machine. The directory is machine-specific 1938 as it contains the ``${MACHINE}`` name. By default, this directory 1939 resides within the :term:`Build Directory` as 1940 ``${DEPLOY_DIR}/images/${MACHINE}/``. 1941 1942 It must not be used directly in recipes when deploying files. Instead, 1943 it's only useful when a recipe needs to "read" a file already deployed 1944 by a dependency. So, it should be filled with the contents of 1945 :term:`DEPLOYDIR` by the :ref:`ref-classes-deploy` class or with the 1946 contents of :term:`IMGDEPLOYDIR` by the :ref:`ref-classes-image` class. 1947 1948 For more information on the structure of the :term:`Build Directory`, see 1949 ":ref:`ref-manual/structure:the build directory --- \`\`build/\`\``" section. 1950 For more detail on the contents of the ``deploy`` directory, see the 1951 ":ref:`overview-manual/concepts:images`" and 1952 ":ref:`overview-manual/concepts:application development sdk`" sections both in 1953 the Yocto Project Overview and Concepts Manual. 1954 1955 :term:`DEPLOY_DIR_IPK` 1956 Points to the area that the OpenEmbedded build system uses to place 1957 IPK packages that are ready to be used outside of the build system. 1958 This variable applies only when :term:`PACKAGE_CLASSES` contains 1959 ":ref:`ref-classes-package_ipk`". 1960 1961 The BitBake configuration file initially defines this variable as a 1962 sub-folder of :term:`DEPLOY_DIR`:: 1963 1964 DEPLOY_DIR_IPK = "${DEPLOY_DIR}/ipk" 1965 1966 The :ref:`ref-classes-package_ipk` class uses the :term:`DEPLOY_DIR_IPK` 1967 variable to make sure the :ref:`ref-tasks-package_write_ipk` task 1968 writes IPK packages into the appropriate folder. For more information 1969 on how packaging works, see the 1970 ":ref:`overview-manual/concepts:package feeds`" section 1971 in the Yocto Project Overview and Concepts Manual. 1972 1973 :term:`DEPLOY_DIR_RPM` 1974 Points to the area that the OpenEmbedded build system uses to place 1975 RPM packages that are ready to be used outside of the build system. 1976 This variable applies only when :term:`PACKAGE_CLASSES` contains 1977 ":ref:`ref-classes-package_rpm`". 1978 1979 The BitBake configuration file initially defines this variable as a 1980 sub-folder of :term:`DEPLOY_DIR`:: 1981 1982 DEPLOY_DIR_RPM = "${DEPLOY_DIR}/rpm" 1983 1984 The :ref:`ref-classes-package_rpm` class uses the 1985 :term:`DEPLOY_DIR_RPM` variable to make sure the 1986 :ref:`ref-tasks-package_write_rpm` task 1987 writes RPM packages into the appropriate folder. For more information 1988 on how packaging works, see the 1989 ":ref:`overview-manual/concepts:package feeds`" section 1990 in the Yocto Project Overview and Concepts Manual. 1991 1992 :term:`DEPLOYDIR` 1993 When inheriting the :ref:`ref-classes-deploy` class, the 1994 :term:`DEPLOYDIR` points to a temporary work area for deployed files that 1995 is set in the :ref:`ref-classes-deploy` class as follows:: 1996 1997 DEPLOYDIR = "${WORKDIR}/deploy-${PN}" 1998 1999 Recipes inheriting the :ref:`ref-classes-deploy` class should copy files to be 2000 deployed into :term:`DEPLOYDIR`, and the class will take care of copying 2001 them into :term:`DEPLOY_DIR_IMAGE` 2002 afterwards. 2003 2004 :term:`DESCRIPTION` 2005 The package description used by package managers. If not set, 2006 :term:`DESCRIPTION` takes the value of the :term:`SUMMARY` 2007 variable. 2008 2009 :term:`DEV_PKG_DEPENDENCY` 2010 Provides an easy way for recipes to disable or adjust the runtime recommendation 2011 (:term:`RRECOMMENDS`) of the ``${PN}-dev`` package on the main 2012 (``${PN}``) package. 2013 2014 :term:`DISABLE_STATIC` 2015 Used in order to disable static linking by default (in order to save 2016 space, since static libraries are often unused in embedded systems.) 2017 The default value is " --disable-static", however it can be set to "" 2018 in order to enable static linking if desired. Certain recipes do this 2019 individually, and also there is a 2020 ``meta/conf/distro/include/no-static-libs.inc`` include file that 2021 disables static linking for a number of recipes. Some software 2022 packages or build tools (such as CMake) have explicit support for 2023 enabling / disabling static linking, and in those cases 2024 :term:`DISABLE_STATIC` is not used. 2025 2026 :term:`DISTRO` 2027 The short name of the distribution. For information on the long name 2028 of the distribution, see the :term:`DISTRO_NAME` 2029 variable. 2030 2031 The :term:`DISTRO` variable corresponds to a distribution configuration 2032 file whose root name is the same as the variable's argument and whose 2033 filename extension is ``.conf``. For example, the distribution 2034 configuration file for the Poky distribution is named ``poky.conf`` 2035 and resides in the ``meta-poky/conf/distro`` directory of the 2036 :term:`Source Directory`. 2037 2038 Within that ``poky.conf`` file, the :term:`DISTRO` variable is set as 2039 follows:: 2040 2041 DISTRO = "poky" 2042 2043 Distribution configuration files are located in a ``conf/distro`` 2044 directory within the :term:`Metadata` that contains the 2045 distribution configuration. The value for :term:`DISTRO` must not contain 2046 spaces, and is typically all lower-case. 2047 2048 .. note:: 2049 2050 If the :term:`DISTRO` variable is blank, a set of default configurations 2051 are used, which are specified within 2052 ``meta/conf/distro/defaultsetup.conf`` also in the Source Directory. 2053 2054 :term:`DISTRO_CODENAME` 2055 Specifies a codename for the distribution being built. 2056 2057 :term:`DISTRO_EXTRA_RDEPENDS` 2058 Specifies a list of distro-specific packages to add to all images. 2059 This variable takes effect through ``packagegroup-base`` so the 2060 variable only really applies to the more full-featured images that 2061 include ``packagegroup-base``. You can use this variable to keep 2062 distro policy out of generic images. As with all other distro 2063 variables, you set this variable in the distro ``.conf`` file. 2064 2065 :term:`DISTRO_EXTRA_RRECOMMENDS` 2066 Specifies a list of distro-specific packages to add to all images if 2067 the packages exist. The packages might not exist or be empty (e.g. 2068 kernel modules). The list of packages are automatically installed but 2069 you can remove them. 2070 2071 :term:`DISTRO_FEATURES` 2072 The software support you want in your distribution for various 2073 features. You define your distribution features in the distribution 2074 configuration file. 2075 2076 In most cases, the presence or absence of a feature in 2077 :term:`DISTRO_FEATURES` is translated to the appropriate option supplied 2078 to the configure script during the 2079 :ref:`ref-tasks-configure` task for recipes that 2080 optionally support the feature. For example, specifying "x11" in 2081 :term:`DISTRO_FEATURES`, causes every piece of software built for the 2082 target that can optionally support X11 to have its X11 support 2083 enabled. 2084 2085 .. note:: 2086 2087 Just enabling :term:`DISTRO_FEATURES` alone doesn't 2088 enable feature support for packages. Mechanisms such as making 2089 :term:`PACKAGECONFIG` track :term:`DISTRO_FEATURES` are used 2090 to enable/disable package features. 2091 2092 Two more examples are Bluetooth and NFS support. For a more complete 2093 list of features that ships with the Yocto Project and that you can 2094 provide with this variable, see the ":ref:`ref-features-distro`" section. 2095 2096 :term:`DISTRO_FEATURES_BACKFILL` 2097 A space-separated list of features to be added to :term:`DISTRO_FEATURES` 2098 if not also present in :term:`DISTRO_FEATURES_BACKFILL_CONSIDERED`. 2099 2100 This variable is set in the ``meta/conf/bitbake.conf`` file. It is 2101 not intended to be user-configurable. It is best to just reference 2102 the variable to see which distro features are being 2103 :ref:`backfilled <ref-features-backfill>` for all distro configurations. 2104 2105 :term:`DISTRO_FEATURES_BACKFILL_CONSIDERED` 2106 A space-separated list of features from :term:`DISTRO_FEATURES_BACKFILL` 2107 that should not be :ref:`backfilled <ref-features-backfill>` (i.e. added 2108 to :term:`DISTRO_FEATURES`) during the build. 2109 2110 This corresponds to an opt-out mechanism. When new default distro 2111 features are introduced, distribution maintainers can review (`consider`) 2112 them and decide to exclude them from the 2113 :ref:`backfilled <ref-features-backfill>` features. Therefore, the 2114 combination of :term:`DISTRO_FEATURES_BACKFILL` and 2115 :term:`DISTRO_FEATURES_BACKFILL_CONSIDERED` makes it possible to 2116 add new default features without breaking existing distributions. 2117 2118 2119 :term:`DISTRO_FEATURES_DEFAULT` 2120 A convenience variable that gives you the default list of distro 2121 features with the exception of any features specific to the C library 2122 (``libc``). 2123 2124 When creating a custom distribution, you might find it useful to be 2125 able to reuse the default 2126 :term:`DISTRO_FEATURES` options without the 2127 need to write out the full set. Here is an example that uses 2128 :term:`DISTRO_FEATURES_DEFAULT` from a custom distro configuration file:: 2129 2130 DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULT} myfeature" 2131 2132 :term:`DISTRO_FEATURES_FILTER_NATIVE` 2133 Specifies a list of features that if present in the target 2134 :term:`DISTRO_FEATURES` value should be 2135 included in :term:`DISTRO_FEATURES` when building native recipes. This 2136 variable is used in addition to the features filtered using the 2137 :term:`DISTRO_FEATURES_NATIVE` 2138 variable. 2139 2140 :term:`DISTRO_FEATURES_FILTER_NATIVESDK` 2141 Specifies a list of features that if present in the target 2142 :term:`DISTRO_FEATURES` value should be included in 2143 :term:`DISTRO_FEATURES` when building :ref:`ref-classes-nativesdk` 2144 recipes. This variable is used in addition to the features filtered using 2145 the :term:`DISTRO_FEATURES_NATIVESDK` variable. 2146 2147 :term:`DISTRO_FEATURES_NATIVE` 2148 Specifies a list of features that should be included in 2149 :term:`DISTRO_FEATURES` when building native 2150 recipes. This variable is used in addition to the features filtered 2151 using the 2152 :term:`DISTRO_FEATURES_FILTER_NATIVE` 2153 variable. 2154 2155 :term:`DISTRO_FEATURES_NATIVESDK` 2156 Specifies a list of features that should be included in 2157 :term:`DISTRO_FEATURES` when building 2158 :ref:`ref-classes-nativesdk` recipes. This variable is used 2159 in addition to the features filtered using the 2160 :term:`DISTRO_FEATURES_FILTER_NATIVESDK` variable. 2161 2162 :term:`DISTRO_NAME` 2163 The long name of the distribution. For information on the short name 2164 of the distribution, see the :term:`DISTRO` variable. 2165 2166 The :term:`DISTRO_NAME` variable corresponds to a distribution 2167 configuration file whose root name is the same as the variable's 2168 argument and whose filename extension is ``.conf``. For example, the 2169 distribution configuration file for the Poky distribution is named 2170 ``poky.conf`` and resides in the ``meta-poky/conf/distro`` directory 2171 of the :term:`Source Directory`. 2172 2173 Within that ``poky.conf`` file, the :term:`DISTRO_NAME` variable is set 2174 as follows:: 2175 2176 DISTRO_NAME = "Poky (Yocto Project Reference Distro)" 2177 2178 Distribution configuration files are located in a ``conf/distro`` 2179 directory within the :term:`Metadata` that contains the 2180 distribution configuration. 2181 2182 .. note:: 2183 2184 If the :term:`DISTRO_NAME` variable is blank, a set of default 2185 configurations are used, which are specified within 2186 ``meta/conf/distro/defaultsetup.conf`` also in the Source Directory. 2187 2188 :term:`DISTRO_VERSION` 2189 The version of the distribution. 2190 2191 :term:`DISTROOVERRIDES` 2192 A colon-separated list of overrides specific to the current 2193 distribution. By default, this list includes the value of 2194 :term:`DISTRO`. 2195 2196 You can extend :term:`DISTROOVERRIDES` to add extra overrides that should 2197 apply to the distribution. 2198 2199 The underlying mechanism behind :term:`DISTROOVERRIDES` is simply that it 2200 is included in the default value of 2201 :term:`OVERRIDES`. 2202 2203 :term:`DL_DIR` 2204 The central download directory used by the build process to store 2205 downloads. By default, :term:`DL_DIR` gets files suitable for mirroring 2206 for everything except Git repositories. If you want tarballs of Git 2207 repositories, use the 2208 :term:`BB_GENERATE_MIRROR_TARBALLS` 2209 variable. 2210 2211 You can set this directory by defining the :term:`DL_DIR` variable in the 2212 ``conf/local.conf`` file. This directory is self-maintaining and you 2213 should not have to touch it. By default, the directory is 2214 ``downloads`` in the :term:`Build Directory`:: 2215 2216 #DL_DIR ?= "${TOPDIR}/downloads" 2217 2218 To specify a different download directory, 2219 simply remove the comment from the line and provide your directory. 2220 2221 During a first build, the system downloads many different source code 2222 tarballs from various upstream projects. Downloading can take a 2223 while, particularly if your network connection is slow. Tarballs are 2224 all stored in the directory defined by :term:`DL_DIR` and the build 2225 system looks there first to find source tarballs. 2226 2227 .. note:: 2228 2229 When wiping and rebuilding, you can preserve this directory to 2230 speed up this part of subsequent builds. 2231 2232 You can safely share this directory between multiple builds on the 2233 same development machine. For additional information on how the build 2234 process gets source files when working behind a firewall or proxy 2235 server, see this specific question in the ":doc:`faq`" 2236 chapter. You can also refer to the 2237 ":yocto_wiki:`Working Behind a Network Proxy </Working_Behind_a_Network_Proxy>`" 2238 Wiki page. 2239 2240 :term:`DOC_COMPRESS` 2241 When inheriting the :ref:`ref-classes-compress_doc` 2242 class, this variable sets the compression policy used when the 2243 OpenEmbedded build system compresses man pages and info pages. By 2244 default, the compression method used is gz (gzip). Other policies 2245 available are xz and bz2. 2246 2247 For information on policies and on how to use this variable, see the 2248 comments in the ``meta/classes-recipe/compress_doc.bbclass`` file. 2249 2250 :term:`EFI_PROVIDER` 2251 When building bootable images (i.e. where ``hddimg``, ``iso``, or 2252 ``wic.vmdk`` is in :term:`IMAGE_FSTYPES`), the 2253 :term:`EFI_PROVIDER` variable specifies the EFI bootloader to use. The 2254 default is "grub-efi", but "systemd-boot" can be used instead. 2255 2256 See the :ref:`ref-classes-systemd-boot` and :ref:`ref-classes-image-live` 2257 classes for more information. 2258 2259 :term:`ENABLE_BINARY_LOCALE_GENERATION` 2260 Variable that controls which locales for ``glibc`` are generated 2261 during the build (useful if the target device has 64Mbytes of RAM or 2262 less). 2263 2264 :term:`ERR_REPORT_DIR` 2265 When used with the :ref:`ref-classes-report-error` class, specifies the 2266 path used for storing the debug files created by the :ref:`error reporting 2267 tool <dev-manual/error-reporting-tool:using the error reporting tool>`, 2268 which allows you to submit build errors you encounter to a central 2269 database. By default, the value of this variable is 2270 ``${``\ :term:`LOG_DIR`\ ``}/error-report``. 2271 2272 You can set :term:`ERR_REPORT_DIR` to the path you want the error 2273 reporting tool to store the debug files as follows in your 2274 ``local.conf`` file:: 2275 2276 ERR_REPORT_DIR = "path" 2277 2278 :term:`ERROR_QA` 2279 Specifies the quality assurance checks whose failures are reported as 2280 errors by the OpenEmbedded build system. You set this variable in 2281 your distribution configuration file. For a list of the checks you 2282 can control with this variable, see the 2283 ":ref:`ref-classes-insane`" section. 2284 2285 :term:`ESDK_CLASS_INHERIT_DISABLE` 2286 A list of classes to remove from the :term:`INHERIT` 2287 value globally within the extensible SDK configuration. The 2288 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class sets the 2289 default value:: 2290 2291 ESDK_CLASS_INHERIT_DISABLE ?= "buildhistory icecc" 2292 2293 Some classes are not generally applicable within the extensible SDK 2294 context. You can use this variable to disable those classes. 2295 2296 For additional information on how to customize the extensible SDK's 2297 configuration, see the 2298 ":ref:`sdk-manual/appendix-customizing:configuring the extensible sdk`" 2299 section in the Yocto Project Application Development and the 2300 Extensible Software Development Kit (eSDK) manual. 2301 2302 :term:`ESDK_LOCALCONF_ALLOW` 2303 A list of variables allowed through from the OpenEmbedded build 2304 system configuration into the extensible SDK configuration. By 2305 default, the list of variables is empty and is set in the 2306 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class. 2307 2308 This list overrides the variables specified using the 2309 :term:`ESDK_LOCALCONF_REMOVE` variable as well as 2310 other variables automatically added due to the "/" character 2311 being found at the start of the 2312 value, which is usually indicative of being a path and thus might not 2313 be valid on the system where the SDK is installed. 2314 2315 For additional information on how to customize the extensible SDK's 2316 configuration, see the 2317 ":ref:`sdk-manual/appendix-customizing:configuring the extensible sdk`" 2318 section in the Yocto Project Application Development and the 2319 Extensible Software Development Kit (eSDK) manual. 2320 2321 :term:`ESDK_LOCALCONF_REMOVE` 2322 A list of variables not allowed through from the OpenEmbedded build 2323 system configuration into the extensible SDK configuration. Usually, 2324 these are variables that are specific to the machine on which the 2325 build system is running and thus would be potentially problematic 2326 within the extensible SDK. 2327 2328 By default, :term:`ESDK_LOCALCONF_REMOVE` is set in the 2329 :ref:`populate-sdk-ext <ref-classes-populate-sdk-*>` class and 2330 excludes the following variables: 2331 2332 - :term:`CONF_VERSION` 2333 - :term:`BB_NUMBER_THREADS` 2334 - :term:`BB_NUMBER_PARSE_THREADS` 2335 - :term:`PARALLEL_MAKE` 2336 - :term:`PRSERV_HOST` 2337 - :term:`SSTATE_MIRRORS` :term:`DL_DIR` 2338 - :term:`SSTATE_DIR` :term:`TMPDIR` 2339 - :term:`BB_SERVER_TIMEOUT` 2340 2341 For additional information on how to customize the extensible SDK's 2342 configuration, see the 2343 ":ref:`sdk-manual/appendix-customizing:configuring the extensible sdk`" 2344 section in the Yocto Project Application Development and the 2345 Extensible Software Development Kit (eSDK) manual. 2346 2347 :term:`EXCLUDE_FROM_SHLIBS` 2348 Triggers the OpenEmbedded build system's shared libraries resolver to 2349 exclude an entire package when scanning for shared libraries. 2350 2351 .. note:: 2352 2353 The shared libraries resolver's functionality results in part from 2354 the internal function ``package_do_shlibs``, which is part of the 2355 :ref:`ref-tasks-package` task. You should be aware that the shared 2356 libraries resolver might implicitly define some dependencies between 2357 packages. 2358 2359 The :term:`EXCLUDE_FROM_SHLIBS` variable is similar to the 2360 :term:`PRIVATE_LIBS` variable, which excludes a 2361 package's particular libraries only and not the whole package. 2362 2363 Use the :term:`EXCLUDE_FROM_SHLIBS` variable by setting it to "1" for a 2364 particular package:: 2365 2366 EXCLUDE_FROM_SHLIBS = "1" 2367 2368 :term:`EXCLUDE_FROM_WORLD` 2369 Directs BitBake to exclude a recipe from world builds (i.e. 2370 ``bitbake world``). During world builds, BitBake locates, parses and 2371 builds all recipes found in every layer exposed in the 2372 ``bblayers.conf`` configuration file. 2373 2374 To exclude a recipe from a world build using this variable, set the 2375 variable to "1" in the recipe. 2376 2377 .. note:: 2378 2379 Recipes added to :term:`EXCLUDE_FROM_WORLD` may still be built during a 2380 world build in order to satisfy dependencies of other recipes. Adding 2381 a recipe to :term:`EXCLUDE_FROM_WORLD` only ensures that the recipe is not 2382 explicitly added to the list of build targets in a world build. 2383 2384 :term:`EXTENDPE` 2385 Used with file and pathnames to create a prefix for a recipe's 2386 version based on the recipe's :term:`PE` value. If :term:`PE` 2387 is set and greater than zero for a recipe, :term:`EXTENDPE` becomes that 2388 value (e.g if :term:`PE` is equal to "1" then :term:`EXTENDPE` becomes "1"). 2389 If a recipe's :term:`PE` is not set (the default) or is equal to zero, 2390 :term:`EXTENDPE` becomes "". 2391 2392 See the :term:`STAMP` variable for an example. 2393 2394 :term:`EXTENDPKGV` 2395 The full package version specification as it appears on the final 2396 packages produced by a recipe. The variable's value is normally used 2397 to fix a runtime dependency to the exact same version of another 2398 package in the same recipe:: 2399 2400 RDEPENDS:${PN}-additional-module = "${PN} (= ${EXTENDPKGV})" 2401 2402 The dependency relationships are intended to force the package 2403 manager to upgrade these types of packages in lock-step. 2404 2405 :term:`EXTERNAL_KERNEL_TOOLS` 2406 When set, the :term:`EXTERNAL_KERNEL_TOOLS` variable indicates that these 2407 tools are not in the source tree. 2408 2409 When kernel tools are available in the tree, they are preferred over 2410 any externally installed tools. Setting the :term:`EXTERNAL_KERNEL_TOOLS` 2411 variable tells the OpenEmbedded build system to prefer the installed 2412 external tools. See the :ref:`ref-classes-kernel-yocto` class in 2413 ``meta/classes-recipe`` to see how the variable is used. 2414 2415 :term:`EXTERNAL_TOOLCHAIN` 2416 When you intend to use an 2417 :ref:`external toolchain <dev-manual/external-toolchain:optionally using an external toolchain>`, 2418 this variable allows to specify the directory where this toolchain was 2419 installed. 2420 2421 :term:`EXTERNALSRC` 2422 When inheriting the :ref:`ref-classes-externalsrc` 2423 class, this variable points to the source tree, which is outside of 2424 the OpenEmbedded build system. When set, this variable sets the 2425 :term:`S` variable, which is what the OpenEmbedded build 2426 system uses to locate unpacked recipe source code. 2427 2428 See the ":ref:`ref-classes-externalsrc`" section for details. You 2429 can also find information on how to use this variable in the 2430 ":ref:`dev-manual/building:building software from an external source`" 2431 section in the Yocto Project Development Tasks Manual. 2432 2433 :term:`EXTERNALSRC_BUILD` 2434 When inheriting the :ref:`ref-classes-externalsrc` 2435 class, this variable points to the directory in which the recipe's 2436 source code is built, which is outside of the OpenEmbedded build 2437 system. When set, this variable sets the :term:`B` variable, 2438 which is what the OpenEmbedded build system uses to locate the 2439 :term:`Build Directory`. 2440 2441 See the ":ref:`ref-classes-externalsrc`" section for details. You 2442 can also find information on how to use this variable in the 2443 ":ref:`dev-manual/building:building software from an external source`" 2444 section in the Yocto Project Development Tasks Manual. 2445 2446 :term:`EXTRA_AUTORECONF` 2447 For recipes inheriting the :ref:`ref-classes-autotools` 2448 class, you can use :term:`EXTRA_AUTORECONF` to specify extra options to 2449 pass to the ``autoreconf`` command that is executed during the 2450 :ref:`ref-tasks-configure` task. 2451 2452 The default value is "--exclude=autopoint". 2453 2454 :term:`EXTRA_IMAGE_FEATURES` 2455 A list of additional features to include in an image. When listing 2456 more than one feature, separate them with a space. 2457 2458 Typically, you configure this variable in your ``local.conf`` file, 2459 which is found in the :term:`Build Directory`. Although you can use this 2460 variable from within a recipe, best practices dictate that you do not. 2461 2462 .. note:: 2463 2464 To enable primary features from within the image recipe, use the 2465 :term:`IMAGE_FEATURES` variable. 2466 2467 Here are some examples of features you can add: 2468 2469 - "dbg-pkgs" --- adds -dbg packages for all installed packages including 2470 symbol information for debugging and profiling. 2471 2472 - "debug-tweaks" --- makes an image suitable for debugging. For example, allows root logins without passwords and 2473 enables post-installation logging. See the 'allow-empty-password' and 2474 'post-install-logging' features in the ":ref:`ref-features-image`" 2475 section for more information. 2476 - "dev-pkgs" --- adds -dev packages for all installed packages. This is 2477 useful if you want to develop against the libraries in the image. 2478 - "read-only-rootfs" --- creates an image whose root filesystem is 2479 read-only. See the 2480 ":ref:`dev-manual/read-only-rootfs:creating a read-only root filesystem`" 2481 section in the Yocto Project Development Tasks Manual for more 2482 information 2483 - "tools-debug" --- adds debugging tools such as gdb and strace. 2484 - "tools-sdk" --- adds development tools such as gcc, make, 2485 pkgconfig and so forth. 2486 - "tools-testapps" --- adds useful testing tools 2487 such as ts_print, aplay, arecord and so forth. 2488 2489 For a complete list of image features that ships with the Yocto 2490 Project, see the ":ref:`ref-features-image`" section. 2491 2492 For an example that shows how to customize your image by using this 2493 variable, see the ":ref:`dev-manual/customizing-images:customizing images using custom \`\`image_features\`\` and \`\`extra_image_features\`\``" 2494 section in the Yocto Project Development Tasks Manual. 2495 2496 :term:`EXTRA_IMAGECMD` 2497 Specifies additional options for the image creation command that has 2498 been specified in :term:`IMAGE_CMD`. When setting 2499 this variable, use an override for the associated image type. Here is 2500 an example:: 2501 2502 EXTRA_IMAGECMD:ext3 ?= "-i 4096" 2503 2504 :term:`EXTRA_IMAGEDEPENDS` 2505 A list of recipes to build that do not provide packages for 2506 installing into the root filesystem. 2507 2508 Sometimes a recipe is required to build the final image but is not 2509 needed in the root filesystem. You can use the :term:`EXTRA_IMAGEDEPENDS` 2510 variable to list these recipes and thus specify the dependencies. A 2511 typical example is a required bootloader in a machine configuration. 2512 2513 .. note:: 2514 2515 To add packages to the root filesystem, see the various 2516 :term:`RDEPENDS` and :term:`RRECOMMENDS` variables. 2517 2518 :term:`EXTRA_OECMAKE` 2519 Additional `CMake <https://cmake.org/overview/>`__ options. See the 2520 :ref:`ref-classes-cmake` class for additional information. 2521 2522 :term:`EXTRA_OECONF` 2523 Additional ``configure`` script options. See 2524 :term:`PACKAGECONFIG_CONFARGS` for 2525 additional information on passing configure script options. 2526 2527 :term:`EXTRA_OEMAKE` 2528 Additional GNU ``make`` options. 2529 2530 Because the :term:`EXTRA_OEMAKE` defaults to "", you need to set the 2531 variable to specify any required GNU options. 2532 2533 :term:`PARALLEL_MAKE` and 2534 :term:`PARALLEL_MAKEINST` also make use of 2535 :term:`EXTRA_OEMAKE` to pass the required flags. 2536 2537 :term:`EXTRA_OESCONS` 2538 When inheriting the :ref:`ref-classes-scons` class, this 2539 variable specifies additional configuration options you want to pass 2540 to the ``scons`` command line. 2541 2542 :term:`EXTRA_OEMESON` 2543 Additional `Meson <https://mesonbuild.com/>`__ options. See the 2544 :ref:`ref-classes-meson` class for additional information. 2545 2546 In addition to standard Meson options, such options correspond to 2547 `Meson build options <https://mesonbuild.com/Build-options.html>`__ 2548 defined in the ``meson_options.txt`` file in the sources to build. 2549 Here is an example:: 2550 2551 EXTRA_OEMESON = "-Dpython=disabled -Dvalgrind=disabled" 2552 2553 Note that any custom value for the Meson ``--buildtype`` option 2554 should be set through the :term:`MESON_BUILDTYPE` variable. 2555 2556 :term:`EXTRA_USERS_PARAMS` 2557 When inheriting the :ref:`ref-classes-extrausers` 2558 class, this variable provides image level user and group operations. 2559 This is a more global method of providing user and group 2560 configuration as compared to using the 2561 :ref:`ref-classes-useradd` class, which ties user and 2562 group configurations to a specific recipe. 2563 2564 The set list of commands you can configure using the 2565 :term:`EXTRA_USERS_PARAMS` is shown in the 2566 :ref:`ref-classes-extrausers` class. These commands map to the normal 2567 Unix commands of the same names:: 2568 2569 # EXTRA_USERS_PARAMS = "\ 2570 # useradd -p '' tester; \ 2571 # groupadd developers; \ 2572 # userdel nobody; \ 2573 # groupdel -g video; \ 2574 # groupmod -g 1020 developers; \ 2575 # usermod -s /bin/sh tester; \ 2576 # " 2577 2578 Hardcoded passwords are supported via the ``-p`` parameters for 2579 ``useradd`` or ``usermod``, but only hashed. 2580 2581 Here is an example that adds two users named "tester-jim" and "tester-sue" and assigns 2582 passwords. First on host, create the (escaped) password hash:: 2583 2584 printf "%q" $(mkpasswd -m sha256crypt tester01) 2585 2586 The resulting hash is set to a variable and used in ``useradd`` command parameters:: 2587 2588 inherit extrausers 2589 PASSWD = "\$X\$ABC123\$A-Long-Hash" 2590 EXTRA_USERS_PARAMS = "\ 2591 useradd -p '${PASSWD}' tester-jim; \ 2592 useradd -p '${PASSWD}' tester-sue; \ 2593 " 2594 2595 Finally, here is an example that sets the root password:: 2596 2597 inherit extrausers 2598 EXTRA_USERS_PARAMS = "\ 2599 usermod -p '${PASSWD}' root; \ 2600 " 2601 2602 .. note:: 2603 2604 From a security perspective, hardcoding a default password is not 2605 generally a good idea or even legal in some jurisdictions. It is 2606 recommended that you do not do this if you are building a production 2607 image. 2608 2609 Additionally there is a special ``passwd-expire`` command that will 2610 cause the password for a user to be expired and thus force changing it 2611 on first login, for example:: 2612 2613 EXTRA_USERS_PARAMS += " useradd myuser; passwd-expire myuser;" 2614 2615 .. note:: 2616 2617 At present, ``passwd-expire`` may only work for remote logins when 2618 using OpenSSH and not dropbear as an SSH server. 2619 2620 :term:`EXTRANATIVEPATH` 2621 A list of subdirectories of 2622 ``${``\ :term:`STAGING_BINDIR_NATIVE`\ ``}`` 2623 added to the beginning of the environment variable ``PATH``. As an 2624 example, the following prepends 2625 "${STAGING_BINDIR_NATIVE}/foo:${STAGING_BINDIR_NATIVE}/bar:" to 2626 ``PATH``:: 2627 2628 EXTRANATIVEPATH = "foo bar" 2629 2630 :term:`FAKEROOT` 2631 See :term:`bitbake:FAKEROOT` in the BitBake manual. 2632 2633 :term:`FAKEROOTBASEENV` 2634 See :term:`bitbake:FAKEROOTBASEENV` in the BitBake manual. 2635 2636 :term:`FAKEROOTCMD` 2637 See :term:`bitbake:FAKEROOTCMD` in the BitBake manual. 2638 2639 :term:`FAKEROOTDIRS` 2640 See :term:`bitbake:FAKEROOTDIRS` in the BitBake manual. 2641 2642 :term:`FAKEROOTENV` 2643 See :term:`bitbake:FAKEROOTENV` in the BitBake manual. 2644 2645 :term:`FAKEROOTNOENV` 2646 See :term:`bitbake:FAKEROOTNOENV` in the BitBake manual. 2647 2648 :term:`FEATURE_PACKAGES` 2649 Defines one or more packages to include in an image when a specific 2650 item is included in :term:`IMAGE_FEATURES`. 2651 When setting the value, :term:`FEATURE_PACKAGES` should have the name of 2652 the feature item as an override. Here is an example:: 2653 2654 FEATURE_PACKAGES_widget = "package1 package2" 2655 2656 In this example, if "widget" were added to :term:`IMAGE_FEATURES`, 2657 package1 and package2 would be included in the image. 2658 2659 .. note:: 2660 2661 Packages installed by features defined through :term:`FEATURE_PACKAGES` 2662 are often package groups. While similarly named, you should not 2663 confuse the :term:`FEATURE_PACKAGES` variable with package groups, which 2664 are discussed elsewhere in the documentation. 2665 2666 :term:`FEED_DEPLOYDIR_BASE_URI` 2667 Points to the base URL of the server and location within the 2668 document-root that provides the metadata and packages required by 2669 OPKG to support runtime package management of IPK packages. You set 2670 this variable in your ``local.conf`` file. 2671 2672 Consider the following example:: 2673 2674 FEED_DEPLOYDIR_BASE_URI = "http://192.168.7.1/BOARD-dir" 2675 2676 This example assumes you are serving 2677 your packages over HTTP and your databases are located in a directory 2678 named ``BOARD-dir``, which is underneath your HTTP server's 2679 document-root. In this case, the OpenEmbedded build system generates 2680 a set of configuration files for you in your target that work with 2681 the feed. 2682 2683 :term:`FETCHCMD` 2684 See :term:`bitbake:FETCHCMD` in the BitBake manual. 2685 2686 :term:`FILE` 2687 See :term:`bitbake:FILE` in the BitBake manual. 2688 2689 :term:`FILES` 2690 The list of files and directories that are placed in a package. The 2691 :term:`PACKAGES` variable lists the packages 2692 generated by a recipe. 2693 2694 To use the :term:`FILES` variable, provide a package name override that 2695 identifies the resulting package. Then, provide a space-separated 2696 list of files or paths that identify the files you want included as 2697 part of the resulting package. Here is an example:: 2698 2699 FILES:${PN} += "${bindir}/mydir1 ${bindir}/mydir2/myfile" 2700 2701 .. note:: 2702 2703 - When specifying files or paths, you can pattern match using 2704 Python's 2705 `glob <https://docs.python.org/3/library/glob.html>`__ 2706 syntax. For details on the syntax, see the documentation by 2707 following the previous link. 2708 2709 - When specifying paths as part of the :term:`FILES` variable, it is 2710 good practice to use appropriate path variables. For example, 2711 use ``${sysconfdir}`` rather than ``/etc``, or ``${bindir}`` 2712 rather than ``/usr/bin``. You can find a list of these 2713 variables at the top of the ``meta/conf/bitbake.conf`` file in 2714 the :term:`Source Directory`. You will also 2715 find the default values of the various ``FILES:*`` variables in 2716 this file. 2717 2718 If some of the files you provide with the :term:`FILES` variable are 2719 editable and you know they should not be overwritten during the 2720 package update process by the Package Management System (PMS), you 2721 can identify these files so that the PMS will not overwrite them. See 2722 the :term:`CONFFILES` variable for information on 2723 how to identify these files to the PMS. 2724 2725 :term:`FILES_SOLIBSDEV` 2726 Defines the file specification to match 2727 :term:`SOLIBSDEV`. In other words, 2728 :term:`FILES_SOLIBSDEV` defines the full path name of the development 2729 symbolic link (symlink) for shared libraries on the target platform. 2730 2731 The following statement from the ``bitbake.conf`` shows how it is 2732 set:: 2733 2734 FILES_SOLIBSDEV ?= "${base_libdir}/lib*${SOLIBSDEV} ${libdir}/lib*${SOLIBSDEV}" 2735 2736 :term:`FILESEXTRAPATHS` 2737 Extends the search path the OpenEmbedded build system uses when 2738 looking for files and patches as it processes recipes and append 2739 files. The default directories BitBake uses when it processes recipes 2740 are initially defined by the :term:`FILESPATH` 2741 variable. You can extend :term:`FILESPATH` variable by using 2742 :term:`FILESEXTRAPATHS`. 2743 2744 Best practices dictate that you accomplish this by using 2745 :term:`FILESEXTRAPATHS` from within a ``.bbappend`` file and that you 2746 prepend paths as follows:: 2747 2748 FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" 2749 2750 In the above example, the build system first 2751 looks for files in a directory that has the same name as the 2752 corresponding append file. 2753 2754 .. note:: 2755 2756 When extending :term:`FILESEXTRAPATHS`, be sure to use the immediate 2757 expansion (``:=``) operator. Immediate expansion makes sure that 2758 BitBake evaluates :term:`THISDIR` at the time the 2759 directive is encountered rather than at some later time when 2760 expansion might result in a directory that does not contain the 2761 files you need. 2762 2763 Also, include the trailing separating colon character if you are 2764 prepending. The trailing colon character is necessary because you 2765 are directing BitBake to extend the path by prepending directories 2766 to the search path. 2767 2768 Here is another common use:: 2769 2770 FILESEXTRAPATHS:prepend := "${THISDIR}/files:" 2771 2772 In this example, the build system extends the 2773 :term:`FILESPATH` variable to include a directory named ``files`` that is 2774 in the same directory as the corresponding append file. 2775 2776 This next example specifically adds three paths:: 2777 2778 FILESEXTRAPATHS:prepend := "path_1:path_2:path_3:" 2779 2780 A final example shows how you can extend the search path and include 2781 a :term:`MACHINE`-specific override, which is useful 2782 in a BSP layer:: 2783 2784 FILESEXTRAPATHS:prepend:intel-x86-common := "${THISDIR}/${PN}:" 2785 2786 The previous statement appears in the 2787 ``linux-yocto-dev.bbappend`` file, which is found in the 2788 :ref:`overview-manual/development-environment:yocto project source repositories` in 2789 ``meta-intel/common/recipes-kernel/linux``. Here, the machine 2790 override is a special :term:`PACKAGE_ARCH` 2791 definition for multiple ``meta-intel`` machines. 2792 2793 .. note:: 2794 2795 For a layer that supports a single BSP, the override could just be 2796 the value of :term:`MACHINE`. 2797 2798 By prepending paths in ``.bbappend`` files, you allow multiple append 2799 files that reside in different layers but are used for the same 2800 recipe to correctly extend the path. 2801 2802 :term:`FILESOVERRIDES` 2803 A subset of :term:`OVERRIDES` used by the OpenEmbedded build system for 2804 creating :term:`FILESPATH`. The :term:`FILESOVERRIDES` variable uses 2805 overrides to automatically extend the :term:`FILESPATH` variable. For an 2806 example of how that works, see the :term:`FILESPATH` variable 2807 description. Additionally, you find more information on how overrides 2808 are handled in the 2809 ":ref:`bitbake-user-manual/bitbake-user-manual-metadata:conditional syntax (overrides)`" 2810 section of the BitBake User Manual. 2811 2812 By default, the :term:`FILESOVERRIDES` variable is defined as:: 2813 2814 FILESOVERRIDES = "${TRANSLATED_TARGET_ARCH}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}" 2815 2816 .. note:: 2817 2818 Do not hand-edit the :term:`FILESOVERRIDES` variable. The values match up 2819 with expected overrides and are used in an expected manner by the 2820 build system. 2821 2822 :term:`FILESPATH` 2823 The default set of directories the OpenEmbedded build system uses 2824 when searching for patches and files. 2825 2826 During the build process, BitBake searches each directory in 2827 :term:`FILESPATH` in the specified order when looking for files and 2828 patches specified by each ``file://`` URI in a recipe's 2829 :term:`SRC_URI` statements. 2830 2831 The default value for the :term:`FILESPATH` variable is defined in the 2832 :ref:`ref-classes-base` class found in ``meta/classes-global`` in the 2833 :term:`Source Directory`:: 2834 2835 FILESPATH = "${@base_set_filespath(["${FILE_DIRNAME}/${BP}", \ 2836 "${FILE_DIRNAME}/${BPN}", "${FILE_DIRNAME}/files"], d)}" 2837 2838 The 2839 :term:`FILESPATH` variable is automatically extended using the overrides 2840 from the :term:`FILESOVERRIDES` variable. 2841 2842 .. note:: 2843 2844 - Do not hand-edit the :term:`FILESPATH` variable. If you want the 2845 build system to look in directories other than the defaults, 2846 extend the :term:`FILESPATH` variable by using the 2847 :term:`FILESEXTRAPATHS` variable. 2848 2849 - Be aware that the default :term:`FILESPATH` directories do not map 2850 to directories in custom layers where append files 2851 (``.bbappend``) are used. If you want the build system to find 2852 patches or files that reside with your append files, you need 2853 to extend the :term:`FILESPATH` variable by using the 2854 :term:`FILESEXTRAPATHS` variable. 2855 2856 You can take advantage of this searching behavior in useful ways. For 2857 example, consider a case where there is the following directory structure 2858 for general and machine-specific configurations:: 2859 2860 files/defconfig 2861 files/MACHINEA/defconfig 2862 files/MACHINEB/defconfig 2863 2864 Also in the example, the :term:`SRC_URI` statement contains 2865 "file://defconfig". Given this scenario, you can set 2866 :term:`MACHINE` to "MACHINEA" and cause the build 2867 system to use files from ``files/MACHINEA``. Set :term:`MACHINE` to 2868 "MACHINEB" and the build system uses files from ``files/MACHINEB``. 2869 Finally, for any machine other than "MACHINEA" and "MACHINEB", the 2870 build system uses files from ``files/defconfig``. 2871 2872 You can find out more about the patching process in the 2873 ":ref:`overview-manual/concepts:patching`" section 2874 in the Yocto Project Overview and Concepts Manual and the 2875 ":ref:`dev-manual/new-recipe:patching code`" section in 2876 the Yocto Project Development Tasks Manual. See the 2877 :ref:`ref-tasks-patch` task as well. 2878 2879 :term:`FILESYSTEM_PERMS_TABLES` 2880 Allows you to define your own file permissions settings table as part 2881 of your configuration for the packaging process. For example, suppose 2882 you need a consistent set of custom permissions for a set of groups 2883 and users across an entire work project. It is best to do this in the 2884 packages themselves but this is not always possible. 2885 2886 By default, the OpenEmbedded build system uses the ``fs-perms.txt``, 2887 which is located in the ``meta/files`` folder in the :term:`Source Directory`. 2888 If you create your own file 2889 permissions setting table, you should place it in your layer or the 2890 distro's layer. 2891 2892 You define the :term:`FILESYSTEM_PERMS_TABLES` variable in the 2893 ``conf/local.conf`` file, which is found in the :term:`Build Directory`, 2894 to point to your custom ``fs-perms.txt``. You can specify more than a 2895 single file permissions setting table. The paths you specify to these 2896 files must be defined within the :term:`BBPATH` variable. 2897 2898 For guidance on how to create your own file permissions settings 2899 table file, examine the existing ``fs-perms.txt``. 2900 2901 :term:`FIT_ADDRESS_CELLS` 2902 2903 Specifies the value of the ``#address-cells`` value for the 2904 description of the kernel FIT image. 2905 2906 The default value is set to "1" by the :ref:`ref-classes-kernel-fitimage` 2907 class, which corresponds to 32 bit addresses. 2908 2909 For platforms who need to set 64 bit addresses in 2910 :term:`UBOOT_LOADADDRESS` and :term:`UBOOT_ENTRYPOINT`, you need to 2911 set this value to "2", as two 32 bit values (cells) will be needed 2912 to represent such addresses. 2913 2914 Here is an example setting "0x400000000" as a load address:: 2915 2916 FIT_ADDRESS_CELLS = "2" 2917 UBOOT_LOADADDRESS= "0x04 0x00000000" 2918 2919 See `more details about #address-cells <https://elinux.org/Device_Tree_Usage#How_Addressing_Works>`__. 2920 2921 :term:`FIT_CONF_DEFAULT_DTB` 2922 Specifies the default device tree binary (dtb) file for a fitImage when 2923 multiple are provided. 2924 2925 :term:`FIT_DESC` 2926 Specifies the description string encoded into a fitImage. The default 2927 value is set by the :ref:`ref-classes-kernel-fitimage` 2928 class as follows:: 2929 2930 FIT_DESC ?= "U-Boot fitImage for ${DISTRO_NAME}/${PV}/${MACHINE}" 2931 2932 :term:`FIT_GENERATE_KEYS` 2933 Decides whether to generate the keys for signing fitImage if they 2934 don't already exist. The keys are created in :term:`UBOOT_SIGN_KEYDIR`. 2935 The default value is 0. 2936 2937 :term:`FIT_HASH_ALG` 2938 Specifies the hash algorithm used in creating the FIT Image. For e.g. sha256. 2939 2940 :term:`FIT_KERNEL_COMP_ALG` 2941 Compression algorithm to use for the kernel image inside the FIT Image. 2942 At present, the only supported values are "gzip" (default), "lzo" or "none". 2943 If you set this variable to anything other than "none" you may also need 2944 to set :term:`FIT_KERNEL_COMP_ALG_EXTENSION`. 2945 2946 :term:`FIT_KERNEL_COMP_ALG_EXTENSION` 2947 File extension corresponding to :term:`FIT_KERNEL_COMP_ALG`. The default 2948 value is ".gz". If you set :term:`FIT_KERNEL_COMP_ALG` to "lzo", 2949 you may want to set this variable to ".lzo". 2950 2951 :term:`FIT_KEY_GENRSA_ARGS` 2952 Arguments to openssl genrsa for generating RSA private key for signing 2953 fitImage. The default value is "-F4". i.e. the public exponent 65537 to 2954 use. 2955 2956 :term:`FIT_KEY_REQ_ARGS` 2957 Arguments to openssl req for generating certificate for signing fitImage. 2958 The default value is "-batch -new". batch for non interactive mode 2959 and new for generating new keys. 2960 2961 :term:`FIT_KEY_SIGN_PKCS` 2962 Format for public key certificate used in signing fitImage. 2963 The default value is "x509". 2964 2965 :term:`FIT_SIGN_ALG` 2966 Specifies the signature algorithm used in creating the FIT Image. 2967 For e.g. rsa2048. 2968 2969 :term:`FIT_PAD_ALG` 2970 Specifies the padding algorithm used in creating the FIT Image. 2971 The default value is "pkcs-1.5". 2972 2973 :term:`FIT_SIGN_INDIVIDUAL` 2974 If set to "1", then the :ref:`ref-classes-kernel-fitimage` 2975 class will sign the kernel, dtb and ramdisk images individually in addition 2976 to signing the fitImage itself. This could be useful if you are 2977 intending to verify signatures in another context than booting via 2978 U-Boot. 2979 2980 :term:`FIT_SIGN_NUMBITS` 2981 Size of private key in number of bits used in fitImage. The default 2982 value is "2048". 2983 2984 :term:`FONT_EXTRA_RDEPENDS` 2985 When inheriting the :ref:`ref-classes-fontcache` class, 2986 this variable specifies the runtime dependencies for font packages. 2987 By default, the :term:`FONT_EXTRA_RDEPENDS` is set to "fontconfig-utils". 2988 2989 :term:`FONT_PACKAGES` 2990 When inheriting the :ref:`ref-classes-fontcache` class, this variable 2991 identifies packages containing font files that need to be cached by 2992 Fontconfig. By default, the :ref:`ref-classes-fontcache` class assumes 2993 that fonts are in the recipe's main package (i.e. 2994 ``${``\ :term:`PN`\ ``}``). Use this variable if fonts you 2995 need are in a package other than that main package. 2996 2997 :term:`FORCE_RO_REMOVE` 2998 Forces the removal of the packages listed in ``ROOTFS_RO_UNNEEDED`` 2999 during the generation of the root filesystem. 3000 3001 Set the variable to "1" to force the removal of these packages. 3002 3003 :term:`FULL_OPTIMIZATION` 3004 The options to pass in :term:`TARGET_CFLAGS` and :term:`CFLAGS` when 3005 compiling an optimized system. This variable defaults to "-O2 -pipe 3006 ${DEBUG_FLAGS}". 3007 3008 :term:`GCCPIE` 3009 Enables Position Independent Executables (PIE) within the GNU C 3010 Compiler (GCC). Enabling PIE in the GCC makes Return Oriented 3011 Programming (ROP) attacks much more difficult to execute. 3012 3013 By default the ``security_flags.inc`` file enables PIE by setting the 3014 variable as follows:: 3015 3016 GCCPIE ?= "--enable-default-pie" 3017 3018 :term:`GCCVERSION` 3019 Specifies the default version of the GNU C Compiler (GCC) used for 3020 compilation. By default, :term:`GCCVERSION` is set to "8.x" in the 3021 ``meta/conf/distro/include/tcmode-default.inc`` include file:: 3022 3023 GCCVERSION ?= "8.%" 3024 3025 You can override this value by setting it in a 3026 configuration file such as the ``local.conf``. 3027 3028 :term:`GDB` 3029 The minimal command and arguments to run the GNU Debugger. 3030 3031 :term:`GIR_EXTRA_LIBS_PATH` 3032 Allows to specify an extra search path for ``.so`` files 3033 in GLib related recipes using GObject introspection, 3034 and which do not compile without this setting. 3035 See the ":ref:`dev-manual/gobject-introspection:enabling gobject introspection support`" 3036 section for details. 3037 3038 :term:`GITDIR` 3039 The directory in which a local copy of a Git repository is stored 3040 when it is cloned. 3041 3042 :term:`GITHUB_BASE_URI` 3043 When inheriting the :ref:`ref-classes-github-releases` 3044 class, specifies the base URL for fetching releases for the github 3045 project you wish to fetch sources from. The default value is as follows:: 3046 3047 GITHUB_BASE_URI ?= "https://github.com/${BPN}/${BPN}/releases/" 3048 3049 :term:`GLIBC_GENERATE_LOCALES` 3050 Specifies the list of GLIBC locales to generate should you not wish 3051 to generate all LIBC locals, which can be time consuming. 3052 3053 .. note:: 3054 3055 If you specifically remove the locale ``en_US.UTF-8``, you must set 3056 :term:`IMAGE_LINGUAS` appropriately. 3057 3058 You can set :term:`GLIBC_GENERATE_LOCALES` in your ``local.conf`` file. 3059 By default, all locales are generated:: 3060 3061 GLIBC_GENERATE_LOCALES = "en_GB.UTF-8 en_US.UTF-8" 3062 3063 :term:`GO_IMPORT` 3064 When inheriting the :ref:`ref-classes-go` class, this mandatory variable 3065 sets the import path for the Go package that will be created for the code 3066 to build. If you have a ``go.mod`` file in the source directory, this 3067 typically matches the path in the ``module`` line in this file. 3068 3069 Other Go programs importing this package will use this path. 3070 3071 Here is an example setting from the 3072 :yocto_git:`go-helloworld_0.1.bb </poky/tree/meta/recipes-extended/go-examples/go-helloworld_0.1.bb>` 3073 recipe:: 3074 3075 GO_IMPORT = "golang.org/x/example" 3076 3077 :term:`GO_INSTALL` 3078 When inheriting the :ref:`ref-classes-go` class, this optional variable 3079 specifies which packages in the sources should be compiled and 3080 installed in the Go build space by the 3081 `go install <https://go.dev/ref/mod#go-install>`__ command. 3082 3083 Here is an example setting from the 3084 :oe_git:`crucible </meta-openembedded/tree/meta-oe/recipes-support/crucible/>` 3085 recipe:: 3086 3087 GO_INSTALL = "\ 3088 ${GO_IMPORT}/cmd/crucible \ 3089 ${GO_IMPORT}/cmd/habtool \ 3090 " 3091 3092 By default, :term:`GO_INSTALL` is defined as:: 3093 3094 GO_INSTALL ?= "${GO_IMPORT}/..." 3095 3096 The ``...`` wildcard means that it will catch all 3097 packages found in the sources. 3098 3099 See the :term:`GO_INSTALL_FILTEROUT` variable for 3100 filtering out unwanted packages from the ones 3101 found from the :term:`GO_INSTALL` value. 3102 3103 :term:`GO_INSTALL_FILTEROUT` 3104 When using the Go "vendor" mechanism to bring in dependencies for a Go 3105 package, the default :term:`GO_INSTALL` setting, which uses the ``...`` 3106 wildcard, will include the vendored packages in the build, which produces 3107 incorrect results. 3108 3109 There are also some Go packages that are structured poorly, so that the 3110 ``...`` wildcard results in building example or test code that should not 3111 be included in the build, or could fail to build. 3112 3113 This optional variable allows for filtering out a subset of the sources. 3114 It defaults to excluding everything under the ``vendor`` subdirectory 3115 under package's main directory. This is the normal location for vendored 3116 packages, but it can be overridden by a recipe to filter out other 3117 subdirectories if needed. 3118 3119 :term:`GO_WORKDIR` 3120 When using Go Modules, the current working directory must be the directory 3121 containing the ``go.mod`` file, or one of its subdirectories. When the 3122 ``go`` tool is used, it will automatically look for the ``go.mod`` file 3123 in the Go working directory or in any parent directory, but not in 3124 subdirectories. 3125 3126 When using the :ref:`ref-classes-go-mod` class to use Go modules, 3127 the optional :term:`GO_WORKDIR` variable, defaulting to the value 3128 of :term:`GO_IMPORT`, allows to specify a different Go working directory. 3129 3130 :term:`GROUPADD_PARAM` 3131 When inheriting the :ref:`ref-classes-useradd` class, 3132 this variable specifies for a package what parameters should be 3133 passed to the ``groupadd`` command if you wish to add a group to the 3134 system when the package is installed. 3135 3136 Here is an example from the ``dbus`` recipe:: 3137 3138 GROUPADD_PARAM:${PN} = "-r netdev" 3139 3140 For information on the standard Linux shell command 3141 ``groupadd``, see https://linux.die.net/man/8/groupadd. 3142 3143 :term:`GROUPMEMS_PARAM` 3144 When inheriting the :ref:`ref-classes-useradd` class, 3145 this variable specifies for a package what parameters should be 3146 passed to the ``groupmems`` command if you wish to modify the members 3147 of a group when the package is installed. 3148 3149 For information on the standard Linux shell command ``groupmems``, 3150 see https://linux.die.net/man/8/groupmems. 3151 3152 :term:`GRUB_GFXSERIAL` 3153 Configures the GNU GRand Unified Bootloader (GRUB) to have graphics 3154 and serial in the boot menu. Set this variable to "1" in your 3155 ``local.conf`` or distribution configuration file to enable graphics 3156 and serial in the menu. 3157 3158 See the :ref:`ref-classes-grub-efi` class for more 3159 information on how this variable is used. 3160 3161 :term:`GRUB_OPTS` 3162 Additional options to add to the GNU GRand Unified Bootloader (GRUB) 3163 configuration. Use a semi-colon character (``;``) to separate 3164 multiple options. 3165 3166 The :term:`GRUB_OPTS` variable is optional. See the 3167 :ref:`ref-classes-grub-efi` class for more information 3168 on how this variable is used. 3169 3170 :term:`GRUB_TIMEOUT` 3171 Specifies the timeout before executing the default ``LABEL`` in the 3172 GNU GRand Unified Bootloader (GRUB). 3173 3174 The :term:`GRUB_TIMEOUT` variable is optional. See the 3175 :ref:`ref-classes-grub-efi` class for more information 3176 on how this variable is used. 3177 3178 :term:`GTKIMMODULES_PACKAGES` 3179 When inheriting the :ref:`ref-classes-gtk-immodules-cache` class, 3180 this variable specifies the packages that contain the GTK+ input 3181 method modules being installed when the modules are in packages other 3182 than the main package. 3183 3184 :term:`HGDIR` 3185 See :term:`bitbake:HGDIR` in the BitBake manual. 3186 3187 :term:`HOMEPAGE` 3188 Website where more information about the software the recipe is 3189 building can be found. 3190 3191 :term:`HOST_ARCH` 3192 The name of the target architecture, which is normally the same as 3193 :term:`TARGET_ARCH`. The OpenEmbedded build system 3194 supports many architectures. Here is an example list of architectures 3195 supported. This list is by no means complete as the architecture is 3196 configurable: 3197 3198 - arm 3199 - i586 3200 - x86_64 3201 - powerpc 3202 - powerpc64 3203 - mips 3204 - mipsel 3205 3206 :term:`HOST_CC_ARCH` 3207 Specifies architecture-specific compiler flags that are passed to the 3208 C compiler. 3209 3210 Default initialization for :term:`HOST_CC_ARCH` varies depending on what 3211 is being built: 3212 3213 - :term:`TARGET_CC_ARCH` when building for the 3214 target 3215 3216 - :term:`BUILD_CC_ARCH` when building for the build host (i.e. 3217 ``-native``) 3218 3219 - ``BUILDSDK_CC_ARCH`` when building for an SDK (i.e. 3220 ``nativesdk-``) 3221 3222 :term:`HOST_OS` 3223 Specifies the name of the target operating system, which is normally 3224 the same as the :term:`TARGET_OS`. The variable can 3225 be set to "linux" for ``glibc``-based systems and to "linux-musl" for 3226 ``musl``. For ARM/EABI targets, there are also "linux-gnueabi" and 3227 "linux-musleabi" values possible. 3228 3229 :term:`HOST_PREFIX` 3230 Specifies the prefix for the cross-compile toolchain. :term:`HOST_PREFIX` 3231 is normally the same as :term:`TARGET_PREFIX`. 3232 3233 :term:`HOST_SYS` 3234 Specifies the system, including the architecture and the operating 3235 system, for which the build is occurring in the context of the 3236 current recipe. 3237 3238 The OpenEmbedded build system automatically sets this variable based 3239 on :term:`HOST_ARCH`, 3240 :term:`HOST_VENDOR`, and 3241 :term:`HOST_OS` variables. 3242 3243 .. note:: 3244 3245 You do not need to set the variable yourself. 3246 3247 Consider these two examples: 3248 3249 - Given a native recipe on a 32-bit x86 machine running Linux, the 3250 value is "i686-linux". 3251 3252 - Given a recipe being built for a little-endian MIPS target running 3253 Linux, the value might be "mipsel-linux". 3254 3255 :term:`HOST_VENDOR` 3256 Specifies the name of the vendor. :term:`HOST_VENDOR` is normally the 3257 same as :term:`TARGET_VENDOR`. 3258 3259 :term:`HOSTTOOLS` 3260 A space-separated list (filter) of tools on the build host that 3261 should be allowed to be called from within build tasks. Using this 3262 filter helps reduce the possibility of host contamination. If a tool 3263 specified in the value of :term:`HOSTTOOLS` is not found on the build 3264 host, the OpenEmbedded build system produces an error and the build 3265 is not started. 3266 3267 For additional information, see 3268 :term:`HOSTTOOLS_NONFATAL`. 3269 3270 :term:`HOSTTOOLS_NONFATAL` 3271 A space-separated list (filter) of tools on the build host that 3272 should be allowed to be called from within build tasks. Using this 3273 filter helps reduce the possibility of host contamination. Unlike 3274 :term:`HOSTTOOLS`, the OpenEmbedded build system 3275 does not produce an error if a tool specified in the value of 3276 :term:`HOSTTOOLS_NONFATAL` is not found on the build host. Thus, you can 3277 use :term:`HOSTTOOLS_NONFATAL` to filter optional host tools. 3278 3279 :term:`ICECC_CLASS_DISABLE` 3280 Identifies user classes that you do not want the Icecream distributed 3281 compile support to consider. This variable is used by the 3282 :ref:`ref-classes-icecc` class. You set this variable in 3283 your ``local.conf`` file. 3284 3285 When you list classes using this variable, the recipes inheriting 3286 those classes will not benefit from distributed compilation across 3287 remote hosts. Instead they will be built locally. 3288 3289 :term:`ICECC_DISABLED` 3290 Disables or enables the ``icecc`` (Icecream) function. For more 3291 information on this function and best practices for using this 3292 variable, see the ":ref:`ref-classes-icecc`" 3293 section. 3294 3295 Setting this variable to "1" in your ``local.conf`` disables the 3296 function:: 3297 3298 ICECC_DISABLED ??= "1" 3299 3300 To enable the function, set the variable as follows:: 3301 3302 ICECC_DISABLED = "" 3303 3304 :term:`ICECC_ENV_EXEC` 3305 Points to the ``icecc-create-env`` script that you provide. This 3306 variable is used by the :ref:`ref-classes-icecc` class. You 3307 set this variable in your ``local.conf`` file. 3308 3309 If you do not point to a script that you provide, the OpenEmbedded 3310 build system uses the default script provided by the 3311 :oe_git:`icecc-create-env_0.1.bb 3312 </openembedded-core/tree/meta/recipes-devtools/icecc-create-env/icecc-create-env_0.1.bb>` 3313 recipe, which is a modified version and not the one that comes with 3314 ``icecream``. 3315 3316 :term:`ICECC_PARALLEL_MAKE` 3317 Extra options passed to the ``make`` command during the 3318 :ref:`ref-tasks-compile` task that specify parallel 3319 compilation. This variable usually takes the form of "-j x", where x 3320 represents the maximum number of parallel threads ``make`` can run. 3321 3322 .. note:: 3323 3324 The options passed affect builds on all enabled machines on the 3325 network, which are machines running the ``iceccd`` daemon. 3326 3327 If your enabled machines support multiple cores, coming up with the 3328 maximum number of parallel threads that gives you the best 3329 performance could take some experimentation since machine speed, 3330 network lag, available memory, and existing machine loads can all 3331 affect build time. Consequently, unlike the 3332 :term:`PARALLEL_MAKE` variable, there is no 3333 rule-of-thumb for setting :term:`ICECC_PARALLEL_MAKE` to achieve optimal 3334 performance. 3335 3336 If you do not set :term:`ICECC_PARALLEL_MAKE`, the build system does not 3337 use it (i.e. the system does not detect and assign the number of 3338 cores as is done with :term:`PARALLEL_MAKE`). 3339 3340 :term:`ICECC_PATH` 3341 The location of the ``icecc`` binary. You can set this variable in 3342 your ``local.conf`` file. If your ``local.conf`` file does not define 3343 this variable, the :ref:`ref-classes-icecc` class attempts 3344 to define it by locating ``icecc`` using ``which``. 3345 3346 :term:`ICECC_RECIPE_DISABLE` 3347 Identifies user recipes that you do not want the Icecream distributed 3348 compile support to consider. This variable is used by the 3349 :ref:`ref-classes-icecc` class. You set this variable in 3350 your ``local.conf`` file. 3351 3352 When you list recipes using this variable, you are excluding them 3353 from distributed compilation across remote hosts. Instead they will 3354 be built locally. 3355 3356 :term:`ICECC_RECIPE_ENABLE` 3357 Identifies user recipes that use an empty 3358 :term:`PARALLEL_MAKE` variable that you want to 3359 force remote distributed compilation on using the Icecream 3360 distributed compile support. This variable is used by the 3361 :ref:`ref-classes-icecc` class. You set this variable in 3362 your ``local.conf`` file. 3363 3364 :term:`IMAGE_BASENAME` 3365 The base name of image output files. This variable defaults to the 3366 recipe name (``${``\ :term:`PN`\ ``}``). 3367 3368 :term:`IMAGE_BOOT_FILES` 3369 A space-separated list of files installed into the boot partition 3370 when preparing an image using the Wic tool with the 3371 ``bootimg-partition`` source plugin. By default, 3372 the files are 3373 installed under the same name as the source files. To change the 3374 installed name, separate it from the original name with a semi-colon 3375 (;). Source files need to be located in 3376 :term:`DEPLOY_DIR_IMAGE`. Here are two 3377 examples:: 3378 3379 IMAGE_BOOT_FILES = "u-boot.img uImage;kernel" 3380 IMAGE_BOOT_FILES = "u-boot.${UBOOT_SUFFIX} ${KERNEL_IMAGETYPE}" 3381 3382 Alternatively, source files can be picked up using a glob pattern. In 3383 this case, the destination file must have the same name as the base 3384 name of the source file path. To install files into a directory 3385 within the target location, pass its name after a semi-colon (;). 3386 Here are two examples:: 3387 3388 IMAGE_BOOT_FILES = "bcm2835-bootfiles/*" 3389 IMAGE_BOOT_FILES = "bcm2835-bootfiles/*;boot/" 3390 3391 The first example 3392 installs all files from ``${DEPLOY_DIR_IMAGE}/bcm2835-bootfiles`` 3393 into the root of the target partition. The second example installs 3394 the same files into a ``boot`` directory within the target partition. 3395 3396 You can find information on how to use the Wic tool in the 3397 ":ref:`dev-manual/wic:creating partitioned images using wic`" 3398 section of the Yocto Project Development Tasks Manual. Reference 3399 material for Wic is located in the 3400 ":doc:`/ref-manual/kickstart`" chapter. 3401 3402 :term:`IMAGE_BUILDINFO_FILE` 3403 When using the :ref:`ref-classes-image-buildinfo` class, 3404 specifies the file in the image to write the build information into. The 3405 default value is "``${sysconfdir}/buildinfo``". 3406 3407 :term:`IMAGE_BUILDINFO_VARS` 3408 When using the :ref:`ref-classes-image-buildinfo` class, 3409 specifies the list of variables to include in the `Build Configuration` 3410 section of the output file (as a space-separated list). Defaults to 3411 ":term:`DISTRO` :term:`DISTRO_VERSION`". 3412 3413 :term:`IMAGE_CLASSES` 3414 A list of classes that all images should inherit. This is typically used 3415 to enable functionality across all image recipes. 3416 3417 Classes specified in :term:`IMAGE_CLASSES` must be located in the 3418 ``classes-recipe/`` or ``classes/`` subdirectories. 3419 3420 :term:`IMAGE_CMD` 3421 Specifies the command to create the image file for a specific image 3422 type, which corresponds to the value set in 3423 :term:`IMAGE_FSTYPES`, (e.g. ``ext3``, 3424 ``btrfs``, and so forth). When setting this variable, you should use 3425 an override for the associated type. Here is an example:: 3426 3427 IMAGE_CMD:jffs2 = "mkfs.jffs2 --root=${IMAGE_ROOTFS} --faketime \ 3428 --output=${IMGDEPLOYDIR}/${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.jffs2 \ 3429 ${EXTRA_IMAGECMD}" 3430 3431 You typically do not need to set this variable unless you are adding 3432 support for a new image type. For more examples on how to set this 3433 variable, see the :ref:`ref-classes-image_types` 3434 class file, which is ``meta/classes-recipe/image_types.bbclass``. 3435 3436 :term:`IMAGE_DEVICE_TABLES` 3437 Specifies one or more files that contain custom device tables that 3438 are passed to the ``makedevs`` command as part of creating an image. 3439 These files list basic device nodes that should be created under 3440 ``/dev`` within the image. If :term:`IMAGE_DEVICE_TABLES` is not set, 3441 ``files/device_table-minimal.txt`` is used, which is located by 3442 :term:`BBPATH`. For details on how you should write 3443 device table files, see ``meta/files/device_table-minimal.txt`` as an 3444 example. 3445 3446 :term:`IMAGE_EFI_BOOT_FILES` 3447 A space-separated list of files installed into the boot partition 3448 when preparing an image using the Wic tool with the 3449 ``bootimg-efi`` source plugin. By default, 3450 the files are 3451 installed under the same name as the source files. To change the 3452 installed name, separate it from the original name with a semi-colon 3453 (;). Source files need to be located in 3454 :term:`DEPLOY_DIR_IMAGE`. Here are two 3455 examples:: 3456 3457 IMAGE_EFI_BOOT_FILES = "${KERNEL_IMAGETYPE};bz2" 3458 IMAGE_EFI_BOOT_FILES = "${KERNEL_IMAGETYPE} microcode.cpio" 3459 3460 Alternatively, source files can be picked up using a glob pattern. In 3461 this case, the destination file must have the same name as the base 3462 name of the source file path. To install files into a directory 3463 within the target location, pass its name after a semi-colon (;). 3464 Here are two examples:: 3465 3466 IMAGE_EFI_BOOT_FILES = "boot/loader/*" 3467 IMAGE_EFI_BOOT_FILES = "boot/loader/*;boot/" 3468 3469 The first example 3470 installs all files from ``${DEPLOY_DIR_IMAGE}/boot/loader/`` 3471 into the root of the target partition. The second example installs 3472 the same files into a ``boot`` directory within the target partition. 3473 3474 You can find information on how to use the Wic tool in the 3475 ":ref:`dev-manual/wic:creating partitioned images using wic`" 3476 section of the Yocto Project Development Tasks Manual. Reference 3477 material for Wic is located in the 3478 ":doc:`/ref-manual/kickstart`" chapter. 3479 3480 :term:`IMAGE_FEATURES` 3481 The primary list of features to include in an image. Typically, you 3482 configure this variable in an image recipe. Although you can use this 3483 variable from your ``local.conf`` file, which is found in the 3484 :term:`Build Directory`, best practices dictate that you do 3485 not. 3486 3487 .. note:: 3488 3489 To enable extra features from outside the image recipe, use the 3490 :term:`EXTRA_IMAGE_FEATURES` variable. 3491 3492 For a list of image features that ships with the Yocto Project, see 3493 the ":ref:`ref-features-image`" section. 3494 3495 For an example that shows how to customize your image by using this 3496 variable, see the ":ref:`dev-manual/customizing-images:customizing images using custom \`\`image_features\`\` and \`\`extra_image_features\`\``" 3497 section in the Yocto Project Development Tasks Manual. 3498 3499 :term:`IMAGE_FSTYPES` 3500 Specifies the formats the OpenEmbedded build system uses during the 3501 build when creating the root filesystem. For example, setting 3502 :term:`IMAGE_FSTYPES` as follows causes the build system to create root 3503 filesystems using two formats: ``.ext3`` and ``.tar.bz2``:: 3504 3505 IMAGE_FSTYPES = "ext3 tar.bz2" 3506 3507 For the complete list of supported image formats from which you can 3508 choose, see :term:`IMAGE_TYPES`. 3509 3510 .. note:: 3511 3512 - If an image recipe uses the "inherit image" line and you are 3513 setting :term:`IMAGE_FSTYPES` inside the recipe, you must set 3514 :term:`IMAGE_FSTYPES` prior to using the "inherit image" line. 3515 3516 - Due to the way the OpenEmbedded build system processes this 3517 variable, you cannot update its contents by using ``:append`` 3518 or ``:prepend``. You must use the ``+=`` operator to add one or 3519 more options to the :term:`IMAGE_FSTYPES` variable. 3520 3521 :term:`IMAGE_INSTALL` 3522 Used by recipes to specify the packages to install into an image 3523 through the :ref:`ref-classes-image` class. Use the 3524 :term:`IMAGE_INSTALL` variable with care to avoid ordering issues. 3525 3526 Image recipes set :term:`IMAGE_INSTALL` to specify the packages to 3527 install into an image through :ref:`ref-classes-image`. Additionally, 3528 there are "helper" classes such as the :ref:`ref-classes-core-image` 3529 class which can take lists used with :term:`IMAGE_FEATURES` and turn 3530 them into auto-generated entries in :term:`IMAGE_INSTALL` in addition 3531 to its default contents. 3532 3533 When you use this variable, it is best to use it as follows:: 3534 3535 IMAGE_INSTALL:append = " package-name" 3536 3537 Be sure to include the space 3538 between the quotation character and the start of the package name or 3539 names. 3540 3541 .. note:: 3542 3543 - When working with a 3544 :ref:`core-image-minimal-initramfs <ref-manual/images:images>` 3545 image, do not use the :term:`IMAGE_INSTALL` variable to specify 3546 packages for installation. Instead, use the 3547 :term:`PACKAGE_INSTALL` variable, which 3548 allows the initial RAM filesystem (:term:`Initramfs`) recipe to use a 3549 fixed set of packages and not be affected by :term:`IMAGE_INSTALL`. 3550 For information on creating an :term:`Initramfs`, see the 3551 ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" 3552 section in the Yocto Project Development Tasks Manual. 3553 3554 - Using :term:`IMAGE_INSTALL` with the 3555 :ref:`+= <bitbake-user-manual/bitbake-user-manual-metadata:appending (+=) and prepending (=+) with spaces>` 3556 BitBake operator within the ``/conf/local.conf`` file or from 3557 within an image recipe is not recommended. Use of this operator in 3558 these ways can cause ordering issues. Since 3559 :ref:`ref-classes-core-image` sets :term:`IMAGE_INSTALL` to a 3560 default value using the 3561 :ref:`?= <bitbake-user-manual/bitbake-user-manual-metadata:setting a default value (?=)>` 3562 operator, using a ``+=`` operation against :term:`IMAGE_INSTALL` 3563 results in unexpected behavior when used within 3564 ``conf/local.conf``. Furthermore, the same operation from within an 3565 image recipe may or may not succeed depending on the specific 3566 situation. In both these cases, the behavior is contrary to how 3567 most users expect the ``+=`` operator to work. 3568 3569 :term:`IMAGE_LINGUAS` 3570 Specifies the list of locales to install into the image during the 3571 root filesystem construction process. The OpenEmbedded build system 3572 automatically splits locale files, which are used for localization, 3573 into separate packages. Setting the :term:`IMAGE_LINGUAS` variable 3574 ensures that any locale packages that correspond to packages already 3575 selected for installation into the image are also installed. Here is 3576 an example:: 3577 3578 IMAGE_LINGUAS = "pt-br de-de" 3579 3580 In this example, the build system ensures any Brazilian Portuguese 3581 and German locale files that correspond to packages in the image are 3582 installed (i.e. ``*-locale-pt-br`` and ``*-locale-de-de`` as well as 3583 ``*-locale-pt`` and ``*-locale-de``, since some software packages 3584 only provide locale files by language and not by country-specific 3585 language). 3586 3587 See the :term:`GLIBC_GENERATE_LOCALES` 3588 variable for information on generating GLIBC locales. 3589 3590 3591 :term:`IMAGE_LINK_NAME` 3592 The name of the output image symlink (which does not include 3593 the version part as :term:`IMAGE_NAME` does). The default value 3594 is derived using the :term:`IMAGE_BASENAME` and 3595 :term:`IMAGE_MACHINE_SUFFIX` variables:: 3596 3597 IMAGE_LINK_NAME ?= "${IMAGE_BASENAME}${IMAGE_MACHINE_SUFFIX}" 3598 3599 .. note:: 3600 3601 It is possible to set this to "" to disable symlink creation, 3602 however, you also need to set :term:`IMAGE_NAME` to still have 3603 a reasonable value e.g.:: 3604 3605 IMAGE_LINK_NAME = "" 3606 IMAGE_NAME = "${IMAGE_BASENAME}${IMAGE_MACHINE_SUFFIX}${IMAGE_VERSION_SUFFIX}" 3607 3608 :term:`IMAGE_MACHINE_SUFFIX` 3609 Specifies the by default machine-specific suffix for image file names 3610 (before the extension). The default value is set as follows:: 3611 3612 IMAGE_MACHINE_SUFFIX ??= "-${MACHINE}" 3613 3614 The default :term:`DEPLOY_DIR_IMAGE` already has a :term:`MACHINE` 3615 subdirectory, so you may find it unnecessary to also include this suffix 3616 in the name of every image file. If you prefer to remove the suffix you 3617 can set this variable to an empty string:: 3618 3619 IMAGE_MACHINE_SUFFIX = "" 3620 3621 (Not to be confused with :term:`IMAGE_NAME_SUFFIX`.) 3622 3623 :term:`IMAGE_MANIFEST` 3624 The manifest file for the image. This file lists all the installed 3625 packages that make up the image. The file contains package 3626 information on a line-per-package basis as follows:: 3627 3628 packagename packagearch version 3629 3630 The :ref:`rootfs-postcommands <ref-classes-rootfs*>` class defines the manifest 3631 file as follows:: 3632 3633 IMAGE_MANIFEST ="${IMGDEPLOYDIR}/${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.manifest" 3634 3635 The location is 3636 derived using the :term:`IMGDEPLOYDIR` 3637 and :term:`IMAGE_NAME` variables. You can find 3638 information on how the image is created in the ":ref:`overview-manual/concepts:image generation`" 3639 section in the Yocto Project Overview and Concepts Manual. 3640 3641 :term:`IMAGE_NAME` 3642 The name of the output image files minus the extension. By default 3643 this variable is set using the :term:`IMAGE_LINK_NAME`, and 3644 :term:`IMAGE_VERSION_SUFFIX` variables:: 3645 3646 IMAGE_NAME ?= "${IMAGE_LINK_NAME}${IMAGE_VERSION_SUFFIX}" 3647 3648 :term:`IMAGE_NAME_SUFFIX` 3649 Suffix used for the image output filename --- defaults to ``".rootfs"`` 3650 to distinguish the image file from other files created during image 3651 building; however if this suffix is redundant or not desired you can 3652 clear the value of this variable (set the value to ""). For example, 3653 this is typically cleared in :term:`Initramfs` image recipes. 3654 3655 :term:`IMAGE_OVERHEAD_FACTOR` 3656 Defines a multiplier that the build system applies to the initial 3657 image size for cases when the multiplier times the returned disk 3658 usage value for the image is greater than the sum of 3659 :term:`IMAGE_ROOTFS_SIZE` and :term:`IMAGE_ROOTFS_EXTRA_SPACE`. The result of 3660 the multiplier applied to the initial image size creates free disk 3661 space in the image as overhead. By default, the build process uses a 3662 multiplier of 1.3 for this variable. This default value results in 3663 30% free disk space added to the image when this method is used to 3664 determine the final generated image size. You should be aware that 3665 post install scripts and the package management system uses disk 3666 space inside this overhead area. Consequently, the multiplier does 3667 not produce an image with all the theoretical free disk space. See 3668 :term:`IMAGE_ROOTFS_SIZE` for information on how the build system 3669 determines the overall image size. 3670 3671 The default 30% free disk space typically gives the image enough room 3672 to boot and allows for basic post installs while still leaving a 3673 small amount of free disk space. If 30% free space is inadequate, you 3674 can increase the default value. For example, the following setting 3675 gives you 50% free space added to the image:: 3676 3677 IMAGE_OVERHEAD_FACTOR = "1.5" 3678 3679 Alternatively, you can ensure a specific amount of free disk space is 3680 added to the image by using the :term:`IMAGE_ROOTFS_EXTRA_SPACE` 3681 variable. 3682 3683 :term:`IMAGE_PKGTYPE` 3684 Defines the package type (i.e. DEB, RPM, IPK, or TAR) used by the 3685 OpenEmbedded build system. The variable is defined appropriately by 3686 the :ref:`ref-classes-package_deb`, :ref:`ref-classes-package_rpm`, 3687 or :ref:`ref-classes-package_ipk` class. 3688 3689 The :ref:`ref-classes-populate-sdk-*` and :ref:`ref-classes-image` 3690 classes use the :term:`IMAGE_PKGTYPE` for packaging up images and SDKs. 3691 3692 You should not set the :term:`IMAGE_PKGTYPE` manually. Rather, the 3693 variable is set indirectly through the appropriate 3694 :ref:`package_* <ref-classes-package>` class using the 3695 :term:`PACKAGE_CLASSES` variable. The 3696 OpenEmbedded build system uses the first package type (e.g. DEB, RPM, 3697 or IPK) that appears with the variable 3698 3699 .. note:: 3700 3701 Files using the ``.tar`` format are never used as a substitute 3702 packaging format for DEB, RPM, and IPK formatted files for your image 3703 or SDK. 3704 3705 :term:`IMAGE_POSTPROCESS_COMMAND` 3706 Specifies a list of functions to call once the OpenEmbedded build 3707 system creates the final image output files. You can specify 3708 functions separated by semicolons:: 3709 3710 IMAGE_POSTPROCESS_COMMAND += "function; ... " 3711 3712 If you need to pass the root filesystem path to a command within the 3713 function, you can use ``${IMAGE_ROOTFS}``, which points to the 3714 directory that becomes the root filesystem image. See the 3715 :term:`IMAGE_ROOTFS` variable for more 3716 information. 3717 3718 :term:`IMAGE_PREPROCESS_COMMAND` 3719 Specifies a list of functions to call before the OpenEmbedded build 3720 system creates the final image output files. You can specify 3721 functions separated by semicolons:: 3722 3723 IMAGE_PREPROCESS_COMMAND += "function; ... " 3724 3725 If you need to pass the root filesystem path to a command within the 3726 function, you can use ``${IMAGE_ROOTFS}``, which points to the 3727 directory that becomes the root filesystem image. See the 3728 :term:`IMAGE_ROOTFS` variable for more 3729 information. 3730 3731 :term:`IMAGE_ROOTFS` 3732 The location of the root filesystem while it is under construction 3733 (i.e. during the :ref:`ref-tasks-rootfs` task). This 3734 variable is not configurable. Do not change it. 3735 3736 :term:`IMAGE_ROOTFS_ALIGNMENT` 3737 Specifies the alignment for the output image file in Kbytes. If the 3738 size of the image is not a multiple of this value, then the size is 3739 rounded up to the nearest multiple of the value. The default value is 3740 "1". See :term:`IMAGE_ROOTFS_SIZE` for 3741 additional information. 3742 3743 :term:`IMAGE_ROOTFS_EXTRA_SPACE` 3744 Defines additional free disk space created in the image in Kbytes. By 3745 default, this variable is set to "0". This free disk space is added 3746 to the image after the build system determines the image size as 3747 described in :term:`IMAGE_ROOTFS_SIZE`. 3748 3749 This variable is particularly useful when you want to ensure that a 3750 specific amount of free disk space is available on a device after an 3751 image is installed and running. For example, to be sure 5 Gbytes of 3752 free disk space is available, set the variable as follows:: 3753 3754 IMAGE_ROOTFS_EXTRA_SPACE = "5242880" 3755 3756 For example, the Yocto Project Build Appliance specifically requests 3757 40 Gbytes of extra space with the line:: 3758 3759 IMAGE_ROOTFS_EXTRA_SPACE = "41943040" 3760 3761 :term:`IMAGE_ROOTFS_SIZE` 3762 Defines the size in Kbytes for the generated image. The OpenEmbedded 3763 build system determines the final size for the generated image using 3764 an algorithm that takes into account the initial disk space used for 3765 the generated image, a requested size for the image, and requested 3766 additional free disk space to be added to the image. Programatically, 3767 the build system determines the final size of the generated image as 3768 follows:: 3769 3770 if (image-du * overhead) < rootfs-size: 3771 internal-rootfs-size = rootfs-size + xspace 3772 else: 3773 internal-rootfs-size = (image-du * overhead) + xspace 3774 where: 3775 image-du = Returned value of the du command on the image. 3776 overhead = IMAGE_OVERHEAD_FACTOR 3777 rootfs-size = IMAGE_ROOTFS_SIZE 3778 internal-rootfs-size = Initial root filesystem size before any modifications. 3779 xspace = IMAGE_ROOTFS_EXTRA_SPACE 3780 3781 See the :term:`IMAGE_OVERHEAD_FACTOR` 3782 and :term:`IMAGE_ROOTFS_EXTRA_SPACE` 3783 variables for related information. 3784 3785 :term:`IMAGE_TYPEDEP` 3786 Specifies a dependency from one image type on another. Here is an 3787 example from the :ref:`ref-classes-image-live` class:: 3788 3789 IMAGE_TYPEDEP:live = "ext3" 3790 3791 In the previous example, the variable ensures that when "live" is 3792 listed with the :term:`IMAGE_FSTYPES` variable, 3793 the OpenEmbedded build system produces an ``ext3`` image first since 3794 one of the components of the live image is an ``ext3`` formatted 3795 partition containing the root filesystem. 3796 3797 :term:`IMAGE_TYPES` 3798 Specifies the complete list of supported image types by default: 3799 3800 - btrfs 3801 - container 3802 - cpio 3803 - cpio.gz 3804 - cpio.lz4 3805 - cpio.lzma 3806 - cpio.xz 3807 - cramfs 3808 - erofs 3809 - erofs-lz4 3810 - erofs-lz4hc 3811 - ext2 3812 - ext2.bz2 3813 - ext2.gz 3814 - ext2.lzma 3815 - ext3 3816 - ext3.gz 3817 - ext4 3818 - ext4.gz 3819 - f2fs 3820 - hddimg 3821 - iso 3822 - jffs2 3823 - jffs2.sum 3824 - multiubi 3825 - squashfs 3826 - squashfs-lz4 3827 - squashfs-lzo 3828 - squashfs-xz 3829 - tar 3830 - tar.bz2 3831 - tar.gz 3832 - tar.lz4 3833 - tar.xz 3834 - tar.zst 3835 - ubi 3836 - ubifs 3837 - wic 3838 - wic.bz2 3839 - wic.gz 3840 - wic.lzma 3841 3842 For more information about these types of images, see 3843 ``meta/classes-recipe/image_types*.bbclass`` in the :term:`Source Directory`. 3844 3845 :term:`IMAGE_VERSION_SUFFIX` 3846 Version suffix that is part of the default :term:`IMAGE_NAME` and 3847 :term:`KERNEL_ARTIFACT_NAME` values. 3848 Defaults to ``"-${DATETIME}"``, however you could set this to a 3849 version string that comes from your external build environment if 3850 desired, and this suffix would then be used consistently across 3851 the build artifacts. 3852 3853 :term:`IMGDEPLOYDIR` 3854 When inheriting the :ref:`ref-classes-image` class directly or 3855 through the :ref:`ref-classes-core-image` class, the 3856 :term:`IMGDEPLOYDIR` points to a temporary work area for deployed files 3857 that is set in the ``image`` class as follows:: 3858 3859 IMGDEPLOYDIR = "${WORKDIR}/deploy-${PN}-image-complete" 3860 3861 Recipes inheriting the :ref:`ref-classes-image` class should copy 3862 files to be deployed into :term:`IMGDEPLOYDIR`, and the class will take 3863 care of copying them into :term:`DEPLOY_DIR_IMAGE` afterwards. 3864 3865 :term:`INCOMPATIBLE_LICENSE` 3866 Specifies a space-separated list of license names (as they would 3867 appear in :term:`LICENSE`) that should be excluded 3868 from the build. Recipes that provide no alternatives to listed 3869 incompatible licenses are not built. Packages that are individually 3870 licensed with the specified incompatible licenses will be deleted. 3871 3872 There is some support for wildcards in this variable's value, 3873 however it is restricted to specific licenses. Currently only 3874 these wildcards are allowed and expand as follows: 3875 3876 - ``AGPL-3.0*"``: ``AGPL-3.0-only``, ``AGPL-3.0-or-later`` 3877 - ``GPL-3.0*``: ``GPL-3.0-only``, ``GPL-3.0-or-later`` 3878 - ``LGPL-3.0*``: ``LGPL-3.0-only``, ``LGPL-3.0-or-later`` 3879 3880 .. note:: 3881 3882 This functionality is only regularly tested using the following 3883 setting:: 3884 3885 INCOMPATIBLE_LICENSE = "GPL-3.0* LGPL-3.0* AGPL-3.0*" 3886 3887 3888 Although you can use other settings, you might be required to 3889 remove dependencies on (or provide alternatives to) components that 3890 are required to produce a functional system image. 3891 3892 :term:`INCOMPATIBLE_LICENSE_EXCEPTIONS` 3893 Specifies a space-separated list of package and license pairs that 3894 are allowed to be used even if the license is specified in 3895 :term:`INCOMPATIBLE_LICENSE`. The package and license pairs are 3896 separated using a colon. Example:: 3897 3898 INCOMPATIBLE_LICENSE_EXCEPTIONS = "gdbserver:GPL-3.0-only gdbserver:LGPL-3.0-only" 3899 3900 :term:`INHERIT` 3901 Causes the named class or classes to be inherited globally. Anonymous 3902 functions in the class or classes are not executed for the base 3903 configuration and in each individual recipe. The OpenEmbedded build 3904 system ignores changes to :term:`INHERIT` in individual recipes. 3905 Classes inherited using :term:`INHERIT` must be located in the 3906 ``classes-global/`` or ``classes/`` subdirectories. 3907 3908 For more information on :term:`INHERIT`, see the 3909 :ref:`bitbake-user-manual/bitbake-user-manual-metadata:\`\`inherit\`\` configuration directive`" 3910 section in the BitBake User Manual. 3911 3912 :term:`INHERIT_DISTRO` 3913 Lists classes that will be inherited at the distribution level. It is 3914 unlikely that you want to edit this variable. 3915 3916 Classes specified in :term:`INHERIT_DISTRO` must be located in the 3917 ``classes-global/`` or ``classes/`` subdirectories. 3918 3919 The default value of the variable is set as follows in the 3920 ``meta/conf/distro/defaultsetup.conf`` file:: 3921 3922 INHERIT_DISTRO ?= "debian devshell sstate license" 3923 3924 :term:`INHIBIT_DEFAULT_DEPS` 3925 Prevents the default dependencies, namely the C compiler and standard 3926 C library (libc), from being added to :term:`DEPENDS`. 3927 This variable is usually used within recipes that do not require any 3928 compilation using the C compiler. 3929 3930 Set the variable to "1" to prevent the default dependencies from 3931 being added. 3932 3933 :term:`INHIBIT_PACKAGE_DEBUG_SPLIT` 3934 Prevents the OpenEmbedded build system from splitting out debug 3935 information during packaging. By default, the build system splits out 3936 debugging information during the 3937 :ref:`ref-tasks-package` task. For more information on 3938 how debug information is split out, see the 3939 :term:`PACKAGE_DEBUG_SPLIT_STYLE` 3940 variable. 3941 3942 To prevent the build system from splitting out debug information 3943 during packaging, set the :term:`INHIBIT_PACKAGE_DEBUG_SPLIT` variable as 3944 follows:: 3945 3946 INHIBIT_PACKAGE_DEBUG_SPLIT = "1" 3947 3948 :term:`INHIBIT_PACKAGE_STRIP` 3949 If set to "1", causes the build to not strip binaries in resulting 3950 packages and prevents the ``-dbg`` package from containing the source 3951 files. 3952 3953 By default, the OpenEmbedded build system strips binaries and puts 3954 the debugging symbols into ``${``\ :term:`PN`\ ``}-dbg``. 3955 Consequently, you should not set :term:`INHIBIT_PACKAGE_STRIP` when you 3956 plan to debug in general. 3957 3958 :term:`INHIBIT_SYSROOT_STRIP` 3959 If set to "1", causes the build to not strip binaries in the 3960 resulting sysroot. 3961 3962 By default, the OpenEmbedded build system strips binaries in the 3963 resulting sysroot. When you specifically set the 3964 :term:`INHIBIT_SYSROOT_STRIP` variable to "1" in your recipe, you inhibit 3965 this stripping. 3966 3967 If you want to use this variable, include the :ref:`ref-classes-staging` 3968 class. This class uses a ``sys_strip()`` function to test for the variable 3969 and acts accordingly. 3970 3971 .. note:: 3972 3973 Use of the :term:`INHIBIT_SYSROOT_STRIP` variable occurs in rare and 3974 special circumstances. For example, suppose you are building 3975 bare-metal firmware by using an external GCC toolchain. Furthermore, 3976 even if the toolchain's binaries are strippable, there are other files 3977 needed for the build that are not strippable. 3978 3979 :term:`INIT_MANAGER` 3980 Specifies the system init manager to use. Available options are: 3981 3982 - ``sysvinit`` 3983 - ``systemd`` 3984 - ``mdev-busybox`` 3985 3986 With ``sysvinit``, the init manager is set to 3987 :wikipedia:`SysVinit <Init#SysV-style>`, the traditional UNIX init 3988 system. This is the default choice in the Poky distribution, together with 3989 the Udev device manager (see the ":ref:`device-manager`" section). 3990 3991 With ``systemd``, the init manager becomes :wikipedia:`systemd <Systemd>`, 3992 which comes with the :wikipedia:`udev <Udev>` device manager. 3993 3994 With ``mdev-busybox``, the init manager becomes the much simpler BusyBox 3995 init, together with the BusyBox mdev device manager. This is the simplest 3996 and lightest solution, and probably the best choice for low-end systems 3997 with a rather slow CPU and a limited amount of RAM. 3998 3999 More concretely, this is used to include 4000 ``conf/distro/include/init-manager-${INIT_MANAGER}.inc`` into the global 4001 configuration. You can have a look at the 4002 :yocto_git:`meta/conf/distro/include/init-manager-*.inc </poky/tree/meta/conf/distro/include>` 4003 files for more information, and also the ":ref:`init-manager`" 4004 section in the Yocto Project Development Tasks Manual. 4005 4006 :term:`INITRAMFS_DEPLOY_DIR_IMAGE` 4007 Indicates the deploy directory used by :ref:`ref-tasks-bundle_initramfs` 4008 where the :term:`INITRAMFS_IMAGE` will be fetched from. This variable is 4009 set by default to ``${DEPLOY_DIR_IMAGE}`` in the 4010 :ref:`ref-classes-kernel` class and it's only meant to be changed when 4011 building an :term:`Initramfs` image from a separate multiconfig via 4012 :term:`INITRAMFS_MULTICONFIG`. 4013 4014 :term:`INITRAMFS_FSTYPES` 4015 Defines the format for the output image of an initial RAM filesystem 4016 (:term:`Initramfs`), which is used during boot. Supported formats are the 4017 same as those supported by the 4018 :term:`IMAGE_FSTYPES` variable. 4019 4020 The default value of this variable, which is set in the 4021 ``meta/conf/bitbake.conf`` configuration file in the 4022 :term:`Source Directory`, is "cpio.gz". The Linux kernel's 4023 :term:`Initramfs` mechanism, as opposed to the initial RAM filesystem 4024 :wikipedia:`initrd <Initrd>` mechanism, expects 4025 an optionally compressed cpio archive. 4026 4027 :term:`INITRAMFS_IMAGE` 4028 Specifies the :term:`PROVIDES` name of an image 4029 recipe that is used to build an initial RAM filesystem (:term:`Initramfs`) 4030 image. In other words, the :term:`INITRAMFS_IMAGE` variable causes an 4031 additional recipe to be built as a dependency to whatever root 4032 filesystem recipe you might be using (e.g. ``core-image-sato``). The 4033 :term:`Initramfs` image recipe you provide should set 4034 :term:`IMAGE_FSTYPES` to 4035 :term:`INITRAMFS_FSTYPES`. 4036 4037 An :term:`Initramfs` image provides a temporary root filesystem used for 4038 early system initialization (e.g. loading of modules needed to locate 4039 and mount the "real" root filesystem). 4040 4041 .. note:: 4042 4043 See the ``meta/recipes-core/images/core-image-minimal-initramfs.bb`` 4044 recipe in the :term:`Source Directory` 4045 for an example :term:`Initramfs` recipe. To select this sample recipe as 4046 the one built to provide the :term:`Initramfs` image, set :term:`INITRAMFS_IMAGE` 4047 to "core-image-minimal-initramfs". 4048 4049 You can also find more information by referencing the 4050 ``meta-poky/conf/templates/default/local.conf.sample.extended`` 4051 configuration file in the Source Directory, the :ref:`ref-classes-image` 4052 class, and the :ref:`ref-classes-kernel` class to see how to use the 4053 :term:`INITRAMFS_IMAGE` variable. 4054 4055 If :term:`INITRAMFS_IMAGE` is empty, which is the default, then no 4056 :term:`Initramfs` image is built. 4057 4058 For more information, you can also see the 4059 :term:`INITRAMFS_IMAGE_BUNDLE` 4060 variable, which allows the generated image to be bundled inside the 4061 kernel image. Additionally, for information on creating an :term:`Initramfs` 4062 image, see the ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" section 4063 in the Yocto Project Development Tasks Manual. 4064 4065 :term:`INITRAMFS_IMAGE_BUNDLE` 4066 Controls whether or not the image recipe specified by 4067 :term:`INITRAMFS_IMAGE` is run through an 4068 extra pass 4069 (:ref:`ref-tasks-bundle_initramfs`) during 4070 kernel compilation in order to build a single binary that contains 4071 both the kernel image and the initial RAM filesystem (:term:`Initramfs`) 4072 image. This makes use of the 4073 :term:`CONFIG_INITRAMFS_SOURCE` kernel 4074 feature. 4075 4076 .. note:: 4077 4078 Bundling the :term:`Initramfs` with the kernel conflates the code in the 4079 :term:`Initramfs` with the GPLv2 licensed Linux kernel binary. Thus only GPLv2 4080 compatible software may be part of a bundled :term:`Initramfs`. 4081 4082 .. note:: 4083 4084 Using an extra compilation pass to bundle the :term:`Initramfs` avoids a 4085 circular dependency between the kernel recipe and the :term:`Initramfs` 4086 recipe should the :term:`Initramfs` include kernel modules. Should that be 4087 the case, the :term:`Initramfs` recipe depends on the kernel for the 4088 kernel modules, and the kernel depends on the :term:`Initramfs` recipe 4089 since the :term:`Initramfs` is bundled inside the kernel image. 4090 4091 The combined binary is deposited into the ``tmp/deploy`` directory, 4092 which is part of the :term:`Build Directory`. 4093 4094 Setting the variable to "1" in a configuration file causes the 4095 OpenEmbedded build system to generate a kernel image with the 4096 :term:`Initramfs` specified in :term:`INITRAMFS_IMAGE` bundled within:: 4097 4098 INITRAMFS_IMAGE_BUNDLE = "1" 4099 4100 By default, the :ref:`ref-classes-kernel` class sets this variable to a 4101 null string as follows:: 4102 4103 INITRAMFS_IMAGE_BUNDLE ?= "" 4104 4105 .. note:: 4106 4107 You must set the :term:`INITRAMFS_IMAGE_BUNDLE` variable in a 4108 configuration file. You cannot set the variable in a recipe file. 4109 4110 See the 4111 :yocto_git:`local.conf.sample.extended </poky/tree/meta-poky/conf/templates/default/local.conf.sample.extended>` 4112 file for additional information. Also, for information on creating an 4113 :term:`Initramfs`, see the ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" section 4114 in the Yocto Project Development Tasks Manual. 4115 4116 :term:`INITRAMFS_IMAGE_NAME` 4117 4118 This value needs to stay in sync with :term:`IMAGE_LINK_NAME`, but with 4119 :term:`INITRAMFS_IMAGE` instead of :term:`IMAGE_BASENAME`. The default value 4120 is set as follows: 4121 4122 INITRAMFS_IMAGE_NAME ?= "${@['${INITRAMFS_IMAGE}${IMAGE_MACHINE_SUFFIX}', ''][d.getVar('INITRAMFS_IMAGE') == '']}" 4123 4124 That is, if :term:`INITRAMFS_IMAGE` is set, the value of 4125 :term:`INITRAMFS_IMAGE_NAME` will be set based upon 4126 :term:`INITRAMFS_IMAGE` and :term:`IMAGE_MACHINE_SUFFIX`. 4127 4128 4129 :term:`INITRAMFS_LINK_NAME` 4130 The link name of the initial RAM filesystem image. This variable is 4131 set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as 4132 follows:: 4133 4134 INITRAMFS_LINK_NAME ?= "initramfs-${KERNEL_ARTIFACT_LINK_NAME}" 4135 4136 The value of the 4137 ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same 4138 file, has the following value:: 4139 4140 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}" 4141 4142 See the :term:`MACHINE` variable for additional 4143 information. 4144 4145 :term:`INITRAMFS_MULTICONFIG` 4146 Defines the multiconfig to create a multiconfig dependency to be used by 4147 the :ref:`ref-classes-kernel` class. 4148 4149 This allows the kernel to bundle an :term:`INITRAMFS_IMAGE` coming from 4150 a separate multiconfig, this is meant to be used in addition to :term:`INITRAMFS_DEPLOY_DIR_IMAGE`. 4151 4152 For more information on how to bundle an :term:`Initramfs` image from a separate 4153 multiconfig see the ":ref:`dev-manual/building:Bundling an Initramfs Image From a Separate Multiconfig`" 4154 section in the Yocto Project Development Tasks Manual. 4155 4156 :term:`INITRAMFS_NAME` 4157 The base name of the initial RAM filesystem image. This variable is 4158 set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as 4159 follows:: 4160 4161 INITRAMFS_NAME ?= "initramfs-${KERNEL_ARTIFACT_NAME}" 4162 4163 See :term:`KERNEL_ARTIFACT_NAME` for additional information. 4164 4165 :term:`INITRD` 4166 Indicates list of filesystem images to concatenate and use as an 4167 initial RAM disk (``initrd``). 4168 4169 The :term:`INITRD` variable is an optional variable used with the 4170 :ref:`ref-classes-image-live` class. 4171 4172 :term:`INITRD_IMAGE` 4173 When building a "live" bootable image (i.e. when 4174 :term:`IMAGE_FSTYPES` contains "live"), 4175 :term:`INITRD_IMAGE` specifies the image recipe that should be built to 4176 provide the initial RAM disk image. The default value is 4177 "core-image-minimal-initramfs". 4178 4179 See the :ref:`ref-classes-image-live` class for more information. 4180 4181 :term:`INITSCRIPT_NAME` 4182 The filename of the initialization script as installed to 4183 ``${sysconfdir}/init.d``. 4184 4185 This variable is used in recipes when using :ref:`ref-classes-update-rc.d`. 4186 The variable is mandatory. 4187 4188 :term:`INITSCRIPT_PACKAGES` 4189 A list of the packages that contain initscripts. If multiple packages 4190 are specified, you need to append the package name to the other 4191 ``INITSCRIPT_*`` as an override. 4192 4193 This variable is used in recipes when using :ref:`ref-classes-update-rc.d`. 4194 The variable is optional and defaults to the :term:`PN` 4195 variable. 4196 4197 :term:`INITSCRIPT_PARAMS` 4198 Specifies the options to pass to ``update-rc.d``. Here is an example:: 4199 4200 INITSCRIPT_PARAMS = "start 99 5 2 . stop 20 0 1 6 ." 4201 4202 In this example, the script has a runlevel of 99, starts the script 4203 in initlevels 2 and 5, and stops the script in levels 0, 1 and 6. 4204 4205 The variable's default value is "defaults", which is set in the 4206 :ref:`ref-classes-update-rc.d` class. 4207 4208 The value in :term:`INITSCRIPT_PARAMS` is passed through to the 4209 ``update-rc.d`` command. For more information on valid parameters, 4210 please see the ``update-rc.d`` manual page at 4211 https://manpages.debian.org/buster/init-system-helpers/update-rc.d.8.en.html 4212 4213 :term:`INSANE_SKIP` 4214 Specifies the QA checks to skip for a specific package within a 4215 recipe. For example, to skip the check for symbolic link ``.so`` 4216 files in the main package of a recipe, add the following to the 4217 recipe. The package name override must be used, which in this example 4218 is ``${PN}``:: 4219 4220 INSANE_SKIP:${PN} += "dev-so" 4221 4222 See the ":ref:`ref-classes-insane`" section for a 4223 list of the valid QA checks you can specify using this variable. 4224 4225 :term:`INSTALL_TIMEZONE_FILE` 4226 By default, the ``tzdata`` recipe packages an ``/etc/timezone`` file. 4227 Set the :term:`INSTALL_TIMEZONE_FILE` variable to "0" at the 4228 configuration level to disable this behavior. 4229 4230 :term:`IPK_FEED_URIS` 4231 When the IPK backend is in use and package management is enabled on 4232 the target, you can use this variable to set up ``opkg`` in the 4233 target image to point to package feeds on a nominated server. Once 4234 the feed is established, you can perform installations or upgrades 4235 using the package manager at runtime. 4236 4237 :term:`KARCH` 4238 Defines the kernel architecture used when assembling the 4239 configuration. Architectures supported for this release are: 4240 4241 - powerpc 4242 - i386 4243 - x86_64 4244 - arm 4245 - qemu 4246 - mips 4247 4248 You define the :term:`KARCH` variable in the :ref:`kernel-dev/advanced:bsp descriptions`. 4249 4250 :term:`KBRANCH` 4251 A regular expression used by the build process to explicitly identify 4252 the kernel branch that is validated, patched, and configured during a 4253 build. You must set this variable to ensure the exact kernel branch 4254 you want is being used by the build process. 4255 4256 Values for this variable are set in the kernel's recipe file and the 4257 kernel's append file. For example, if you are using the 4258 ``linux-yocto_4.12`` kernel, the kernel recipe file is the 4259 ``meta/recipes-kernel/linux/linux-yocto_4.12.bb`` file. :term:`KBRANCH` 4260 is set as follows in that kernel recipe file:: 4261 4262 KBRANCH ?= "standard/base" 4263 4264 This variable is also used from the kernel's append file to identify 4265 the kernel branch specific to a particular machine or target 4266 hardware. Continuing with the previous kernel example, the kernel's 4267 append file (i.e. ``linux-yocto_4.12.bbappend``) is located in the 4268 BSP layer for a given machine. For example, the append file for the 4269 Beaglebone, EdgeRouter, and generic versions of both 32 and 64-bit IA 4270 machines (``meta-yocto-bsp``) is named 4271 ``meta-yocto-bsp/recipes-kernel/linux/linux-yocto_4.12.bbappend``. 4272 Here are the related statements from that append file:: 4273 4274 KBRANCH:genericx86 = "standard/base" 4275 KBRANCH:genericx86-64 = "standard/base" 4276 KBRANCH:edgerouter = "standard/edgerouter" 4277 KBRANCH:beaglebone = "standard/beaglebone" 4278 4279 The :term:`KBRANCH` statements 4280 identify the kernel branch to use when building for each supported 4281 BSP. 4282 4283 :term:`KBUILD_DEFCONFIG` 4284 When used with the :ref:`ref-classes-kernel-yocto` 4285 class, specifies an "in-tree" kernel configuration file for use 4286 during a kernel build. 4287 4288 Typically, when using a ``defconfig`` to configure a kernel during a 4289 build, you place the file in your layer in the same manner as you 4290 would place patch files and configuration fragment files (i.e. 4291 "out-of-tree"). However, if you want to use a ``defconfig`` file that 4292 is part of the kernel tree (i.e. "in-tree"), you can use the 4293 :term:`KBUILD_DEFCONFIG` variable and append the 4294 :term:`KMACHINE` variable to point to the 4295 ``defconfig`` file. 4296 4297 To use the variable, set it in the append file for your kernel recipe 4298 using the following form:: 4299 4300 KBUILD_DEFCONFIG:<machine> ?= "defconfig_file" 4301 4302 Here is an example from a "raspberrypi2" :term:`MACHINE` build that uses 4303 a ``defconfig`` file named "bcm2709_defconfig":: 4304 4305 KBUILD_DEFCONFIG:raspberrypi2 = "bcm2709_defconfig" 4306 4307 As an alternative, you can use the following within your append file:: 4308 4309 KBUILD_DEFCONFIG:pn-linux-yocto ?= "defconfig_file" 4310 4311 For more 4312 information on how to use the :term:`KBUILD_DEFCONFIG` variable, see the 4313 ":ref:`kernel-dev/common:using an "in-tree" \`\`defconfig\`\` file`" 4314 section in the Yocto Project Linux Kernel Development Manual. 4315 4316 :term:`KCONFIG_MODE` 4317 When used with the :ref:`ref-classes-kernel-yocto` 4318 class, specifies the kernel configuration values to use for options 4319 not specified in the provided ``defconfig`` file. Valid options are:: 4320 4321 KCONFIG_MODE = "alldefconfig" 4322 KCONFIG_MODE = "allnoconfig" 4323 4324 In ``alldefconfig`` mode the options not explicitly specified will be 4325 assigned their Kconfig default value. In ``allnoconfig`` mode the 4326 options not explicitly specified will be disabled in the kernel 4327 config. 4328 4329 In case :term:`KCONFIG_MODE` is not set the behaviour will depend on where 4330 the ``defconfig`` file is coming from. An "in-tree" ``defconfig`` file 4331 will be handled in ``alldefconfig`` mode, a ``defconfig`` file placed 4332 in ``${WORKDIR}`` through a meta-layer will be handled in 4333 ``allnoconfig`` mode. 4334 4335 An "in-tree" ``defconfig`` file can be selected via the 4336 :term:`KBUILD_DEFCONFIG` variable. :term:`KCONFIG_MODE` does not need to 4337 be explicitly set. 4338 4339 A ``defconfig`` file compatible with ``allnoconfig`` mode can be 4340 generated by copying the ``.config`` file from a working Linux kernel 4341 build, renaming it to ``defconfig`` and placing it into the Linux 4342 kernel ``${WORKDIR}`` through your meta-layer. :term:`KCONFIG_MODE` does 4343 not need to be explicitly set. 4344 4345 A ``defconfig`` file compatible with ``alldefconfig`` mode can be 4346 generated using the 4347 :ref:`ref-tasks-savedefconfig` 4348 task and placed into the Linux kernel ``${WORKDIR}`` through your 4349 meta-layer. Explicitely set :term:`KCONFIG_MODE`:: 4350 4351 KCONFIG_MODE = "alldefconfig" 4352 4353 :term:`KERNEL_ALT_IMAGETYPE` 4354 Specifies an alternate kernel image type for creation in addition to 4355 the kernel image type specified using the :term:`KERNEL_IMAGETYPE` and 4356 :term:`KERNEL_IMAGETYPES` variables. 4357 4358 :term:`KERNEL_ARTIFACT_NAME` 4359 Specifies the name of all of the build artifacts. You can change the 4360 name of the artifacts by changing the :term:`KERNEL_ARTIFACT_NAME` 4361 variable. 4362 4363 The value of :term:`KERNEL_ARTIFACT_NAME`, which is set in the 4364 ``meta/classes-recipe/kernel-artifact-names.bbclass`` file, has the 4365 following default value:: 4366 4367 KERNEL_ARTIFACT_NAME ?= "${PKGE}-${PKGV}-${PKGR}${IMAGE_MACHINE_SUFFIX}${IMAGE_VERSION_SUFFIX}" 4368 4369 See the :term:`PKGE`, :term:`PKGV`, :term:`PKGR`, :term:`IMAGE_MACHINE_SUFFIX` 4370 and :term:`IMAGE_VERSION_SUFFIX` variables for additional information. 4371 4372 :term:`KERNEL_CLASSES` 4373 A list of classes defining kernel image types that the 4374 :ref:`ref-classes-kernel` class should inherit. You typically 4375 append this variable to enable extended image types. An example is 4376 ":ref:`ref-classes-kernel-fitimage`", which enables 4377 fitImage support and resides in ``meta/classes-recipe/kernel-fitimage.bbclass``. 4378 You can register custom kernel image types with the 4379 :ref:`ref-classes-kernel` class using this variable. 4380 4381 :term:`KERNEL_DANGLING_FEATURES_WARN_ONLY` 4382 When kernel configuration fragments are missing for some 4383 :term:`KERNEL_FEATURES` specified by layers or BSPs, 4384 building and configuring the kernel stops with an error. 4385 4386 You can turn these errors into warnings by setting the 4387 following in ``conf/local.conf``:: 4388 4389 KERNEL_DANGLING_FEATURES_WARN_ONLY = "1" 4390 4391 You will still be warned that runtime issues may occur, 4392 but at least the kernel configuration and build process will 4393 be allowed to continue. 4394 4395 :term:`KERNEL_DEBUG_TIMESTAMPS` 4396 If set to "1", enables timestamping functionality during building 4397 the kernel. The default is "0" to disable this for reproducibility 4398 reasons. 4399 4400 :term:`KERNEL_DEPLOY_DEPEND` 4401 Provides a means of controlling the dependency of an image recipe 4402 on the kernel. The default value is "virtual/kernel:do_deploy", 4403 however for a small initramfs image or other images that do not 4404 need the kernel, this can be set to "" in the image recipe. 4405 4406 :term:`KERNEL_DEVICETREE` 4407 Specifies the name of the generated Linux kernel device tree (i.e. 4408 the ``.dtb``) file. 4409 4410 .. note:: 4411 4412 There is legacy support for specifying the full path to the device 4413 tree. However, providing just the ``.dtb`` file is preferred. 4414 4415 In order to use this variable, the :ref:`ref-classes-kernel-devicetree` 4416 class must be inherited. 4417 4418 :term:`KERNEL_DTB_LINK_NAME` 4419 The link name of the kernel device tree binary (DTB). This variable 4420 is set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as 4421 follows:: 4422 4423 KERNEL_DTB_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}" 4424 4425 The 4426 value of the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in 4427 the same file, has the following value:: 4428 4429 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}" 4430 4431 See the :term:`MACHINE` variable for additional 4432 information. 4433 4434 :term:`KERNEL_DTB_NAME` 4435 The base name of the kernel device tree binary (DTB). This variable 4436 is set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as 4437 follows:: 4438 4439 KERNEL_DTB_NAME ?= "${KERNEL_ARTIFACT_NAME}" 4440 4441 See :term:`KERNEL_ARTIFACT_NAME` for additional information. 4442 4443 :term:`KERNEL_DTC_FLAGS` 4444 Specifies the ``dtc`` flags that are passed to the Linux kernel build 4445 system when generating the device trees (via ``DTC_FLAGS`` environment 4446 variable). 4447 4448 In order to use this variable, the :ref:`ref-classes-kernel-devicetree` 4449 class must be inherited. 4450 4451 :term:`KERNEL_EXTRA_ARGS` 4452 Specifies additional ``make`` command-line arguments the OpenEmbedded 4453 build system passes on when compiling the kernel. 4454 4455 :term:`KERNEL_FEATURES` 4456 Includes additional kernel metadata. In the OpenEmbedded build 4457 system, the default Board Support Packages (BSPs) 4458 :term:`Metadata` is provided through the 4459 :term:`KMACHINE` and :term:`KBRANCH` 4460 variables. You can use the :term:`KERNEL_FEATURES` variable from within 4461 the kernel recipe or kernel append file to further add metadata for 4462 all BSPs or specific BSPs. 4463 4464 The metadata you add through this variable includes config fragments 4465 and features descriptions, which usually includes patches as well as 4466 config fragments. You typically override the :term:`KERNEL_FEATURES` 4467 variable for a specific machine. In this way, you can provide 4468 validated, but optional, sets of kernel configurations and features. 4469 4470 For example, the following example from the ``linux-yocto-rt_4.12`` 4471 kernel recipe adds "netfilter" and "taskstats" features to all BSPs 4472 as well as "virtio" configurations to all QEMU machines. The last two 4473 statements add specific configurations to targeted machine types:: 4474 4475 KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc" 4476 KERNEL_FEATURES:append = " ${KERNEL_EXTRA_FEATURES}" 4477 KERNEL_FEATURES:append:qemuall = " cfg/virtio.scc" 4478 KERNEL_FEATURES:append:qemux86 = " cfg/sound.scc cfg/paravirt_kvm.scc" 4479 KERNEL_FEATURES:append:qemux86-64 = " cfg/sound.scc" 4480 4481 :term:`KERNEL_FIT_LINK_NAME` 4482 The link name of the kernel flattened image tree (FIT) image. This 4483 variable is set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` 4484 file as follows:: 4485 4486 KERNEL_FIT_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}" 4487 4488 The value of the 4489 ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same 4490 file, has the following value:: 4491 4492 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}" 4493 4494 See the :term:`MACHINE` variable for additional 4495 information. 4496 4497 :term:`KERNEL_FIT_NAME` 4498 The base name of the kernel flattened image tree (FIT) image. This 4499 variable is set in the ``meta/classes-recipe/kernel-artifact-names.bbclass`` 4500 file as follows:: 4501 4502 KERNEL_FIT_NAME ?= "${KERNEL_ARTIFACT_NAME}" 4503 4504 See :term:`KERNEL_ARTIFACT_NAME` for additional information. 4505 4506 :term:`KERNEL_IMAGE_LINK_NAME` 4507 The link name for the kernel image. This variable is set in the 4508 ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as follows:: 4509 4510 KERNEL_IMAGE_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}" 4511 4512 The value of 4513 the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the same 4514 file, has the following value:: 4515 4516 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}" 4517 4518 See the :term:`MACHINE` variable for additional 4519 information. 4520 4521 :term:`KERNEL_IMAGE_MAXSIZE` 4522 Specifies the maximum size of the kernel image file in kilobytes. If 4523 :term:`KERNEL_IMAGE_MAXSIZE` is set, the size of the kernel image file is 4524 checked against the set value during the 4525 :ref:`ref-tasks-sizecheck` task. The task fails if 4526 the kernel image file is larger than the setting. 4527 4528 :term:`KERNEL_IMAGE_MAXSIZE` is useful for target devices that have a 4529 limited amount of space in which the kernel image must be stored. 4530 4531 By default, this variable is not set, which means the size of the 4532 kernel image is not checked. 4533 4534 :term:`KERNEL_IMAGE_NAME` 4535 The base name of the kernel image. This variable is set in the 4536 ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as follows:: 4537 4538 KERNEL_IMAGE_NAME ?= "${KERNEL_ARTIFACT_NAME}" 4539 4540 See :term:`KERNEL_ARTIFACT_NAME` for additional information. 4541 4542 :term:`KERNEL_IMAGETYPE` 4543 The type of kernel to build for a device, usually set by the machine 4544 configuration files and defaults to "zImage". This variable is used 4545 when building the kernel and is passed to ``make`` as the target to 4546 build. 4547 4548 To build additional kernel image types, use :term:`KERNEL_IMAGETYPES`. 4549 4550 :term:`KERNEL_IMAGETYPES` 4551 Lists additional types of kernel images to build for a device in addition 4552 to image type specified in :term:`KERNEL_IMAGETYPE`. Usually set by the 4553 machine configuration files. 4554 4555 :term:`KERNEL_MODULE_AUTOLOAD` 4556 Lists kernel modules that need to be auto-loaded during boot. 4557 4558 .. note:: 4559 4560 This variable replaces the deprecated :term:`module_autoload` 4561 variable. 4562 4563 You can use the :term:`KERNEL_MODULE_AUTOLOAD` variable anywhere that it 4564 can be recognized by the kernel recipe or by an out-of-tree kernel 4565 module recipe (e.g. a machine configuration file, a distribution 4566 configuration file, an append file for the recipe, or the recipe 4567 itself). 4568 4569 Specify it as follows:: 4570 4571 KERNEL_MODULE_AUTOLOAD += "module_name1 module_name2 module_name3" 4572 4573 Including :term:`KERNEL_MODULE_AUTOLOAD` causes the OpenEmbedded build 4574 system to populate the ``/etc/modules-load.d/modname.conf`` file with 4575 the list of modules to be auto-loaded on boot. The modules appear 4576 one-per-line in the file. Here is an example of the most common use 4577 case:: 4578 4579 KERNEL_MODULE_AUTOLOAD += "module_name" 4580 4581 For information on how to populate the ``modname.conf`` file with 4582 ``modprobe.d`` syntax lines, see the :term:`KERNEL_MODULE_PROBECONF` variable. 4583 4584 :term:`KERNEL_MODULE_PROBECONF` 4585 Provides a list of modules for which the OpenEmbedded build system 4586 expects to find ``module_conf_``\ modname values that specify 4587 configuration for each of the modules. For information on how to 4588 provide those module configurations, see the 4589 :term:`module_conf_* <module_conf>` variable. 4590 4591 :term:`KERNEL_PATH` 4592 The location of the kernel sources. This variable is set to the value 4593 of the :term:`STAGING_KERNEL_DIR` within the :ref:`ref-classes-module` 4594 class. For information on how this variable is used, see the 4595 ":ref:`kernel-dev/common:incorporating out-of-tree modules`" 4596 section in the Yocto Project Linux Kernel Development Manual. 4597 4598 To help maximize compatibility with out-of-tree drivers used to build 4599 modules, the OpenEmbedded build system also recognizes and uses the 4600 :term:`KERNEL_SRC` variable, which is identical to 4601 the :term:`KERNEL_PATH` variable. Both variables are common variables 4602 used by external Makefiles to point to the kernel source directory. 4603 4604 :term:`KERNEL_SRC` 4605 The location of the kernel sources. This variable is set to the value 4606 of the :term:`STAGING_KERNEL_DIR` within the :ref:`ref-classes-module` 4607 class. For information on how this variable is used, see the 4608 ":ref:`kernel-dev/common:incorporating out-of-tree modules`" 4609 section in the Yocto Project Linux Kernel Development Manual. 4610 4611 To help maximize compatibility with out-of-tree drivers used to build 4612 modules, the OpenEmbedded build system also recognizes and uses the 4613 :term:`KERNEL_PATH` variable, which is identical 4614 to the :term:`KERNEL_SRC` variable. Both variables are common variables 4615 used by external Makefiles to point to the kernel source directory. 4616 4617 :term:`KERNEL_VERSION` 4618 Specifies the version of the kernel as extracted from ``version.h`` 4619 or ``utsrelease.h`` within the kernel sources. Effects of setting 4620 this variable do not take effect until the kernel has been 4621 configured. Consequently, attempting to refer to this variable in 4622 contexts prior to configuration will not work. 4623 4624 :term:`KERNELDEPMODDEPEND` 4625 Specifies whether the data referenced through 4626 :term:`PKGDATA_DIR` is needed or not. 4627 :term:`KERNELDEPMODDEPEND` does not control whether or not that data 4628 exists, but simply whether or not it is used. If you do not need to 4629 use the data, set the :term:`KERNELDEPMODDEPEND` variable in your 4630 :term:`Initramfs` recipe. Setting the variable there when the data is not 4631 needed avoids a potential dependency loop. 4632 4633 :term:`KFEATURE_DESCRIPTION` 4634 Provides a short description of a configuration fragment. You use 4635 this variable in the ``.scc`` file that describes a configuration 4636 fragment file. Here is the variable used in a file named ``smp.scc`` 4637 to describe SMP being enabled:: 4638 4639 define KFEATURE_DESCRIPTION "Enable SMP" 4640 4641 :term:`KMACHINE` 4642 The machine as known by the kernel. Sometimes the machine name used 4643 by the kernel does not match the machine name used by the 4644 OpenEmbedded build system. For example, the machine name that the 4645 OpenEmbedded build system understands as ``core2-32-intel-common`` 4646 goes by a different name in the Linux Yocto kernel. The kernel 4647 understands that machine as ``intel-core2-32``. For cases like these, 4648 the :term:`KMACHINE` variable maps the kernel machine name to the 4649 OpenEmbedded build system machine name. 4650 4651 These mappings between different names occur in the Yocto Linux 4652 Kernel's ``meta`` branch. As an example take a look in the 4653 ``common/recipes-kernel/linux/linux-yocto_3.19.bbappend`` file:: 4654 4655 LINUX_VERSION:core2-32-intel-common = "3.19.0" 4656 COMPATIBLE_MACHINE:core2-32-intel-common = "${MACHINE}" 4657 SRCREV_meta:core2-32-intel-common = "8897ef68b30e7426bc1d39895e71fb155d694974" 4658 SRCREV_machine:core2-32-intel-common = "43b9eced9ba8a57add36af07736344dcc383f711" 4659 KMACHINE:core2-32-intel-common = "intel-core2-32" 4660 KBRANCH:core2-32-intel-common = "standard/base" 4661 KERNEL_FEATURES:append:core2-32-intel-common = " ${KERNEL_FEATURES_INTEL_COMMON}" 4662 4663 The :term:`KMACHINE` statement says 4664 that the kernel understands the machine name as "intel-core2-32". 4665 However, the OpenEmbedded build system understands the machine as 4666 "core2-32-intel-common". 4667 4668 :term:`KTYPE` 4669 Defines the kernel type to be used in assembling the configuration. 4670 The linux-yocto recipes define "standard", "tiny", and "preempt-rt" 4671 kernel types. See the ":ref:`kernel-dev/advanced:kernel types`" 4672 section in the 4673 Yocto Project Linux Kernel Development Manual for more information on 4674 kernel types. 4675 4676 You define the :term:`KTYPE` variable in the 4677 :ref:`kernel-dev/advanced:bsp descriptions`. The 4678 value you use must match the value used for the 4679 :term:`LINUX_KERNEL_TYPE` value used by the 4680 kernel recipe. 4681 4682 :term:`LABELS` 4683 Provides a list of targets for automatic configuration. 4684 4685 See the :ref:`ref-classes-grub-efi` class for more 4686 information on how this variable is used. 4687 4688 :term:`LAYERDEPENDS` 4689 Lists the layers, separated by spaces, on which this recipe depends. 4690 Optionally, you can specify a specific layer version for a dependency 4691 by adding it to the end of the layer name. Here is an example:: 4692 4693 LAYERDEPENDS_mylayer = "anotherlayer (=3)" 4694 4695 In this previous example, 4696 version 3 of "anotherlayer" is compared against 4697 :term:`LAYERVERSION`\ ``_anotherlayer``. 4698 4699 An error is produced if any dependency is missing or the version 4700 numbers (if specified) do not match exactly. This variable is used in 4701 the ``conf/layer.conf`` file and must be suffixed with the name of 4702 the specific layer (e.g. ``LAYERDEPENDS_mylayer``). 4703 4704 :term:`LAYERDIR` 4705 When used inside the ``layer.conf`` configuration file, this variable 4706 provides the path of the current layer. This variable is not 4707 available outside of ``layer.conf`` and references are expanded 4708 immediately when parsing of the file completes. 4709 4710 :term:`LAYERDIR_RE` 4711 See :term:`bitbake:LAYERDIR_RE` in the BitBake manual. 4712 4713 :term:`LAYERRECOMMENDS` 4714 Lists the layers, separated by spaces, recommended for use with this 4715 layer. 4716 4717 Optionally, you can specify a specific layer version for a 4718 recommendation by adding the version to the end of the layer name. 4719 Here is an example:: 4720 4721 LAYERRECOMMENDS_mylayer = "anotherlayer (=3)" 4722 4723 In this previous example, version 3 of "anotherlayer" is compared 4724 against ``LAYERVERSION_anotherlayer``. 4725 4726 This variable is used in the ``conf/layer.conf`` file and must be 4727 suffixed with the name of the specific layer (e.g. 4728 ``LAYERRECOMMENDS_mylayer``). 4729 4730 :term:`LAYERSERIES_COMPAT` 4731 See :term:`bitbake:LAYERSERIES_COMPAT` in the BitBake manual. 4732 4733 :term:`LAYERVERSION` 4734 Optionally specifies the version of a layer as a single number. You 4735 can use this within :term:`LAYERDEPENDS` for 4736 another layer in order to depend on a specific version of the layer. 4737 This variable is used in the ``conf/layer.conf`` file and must be 4738 suffixed with the name of the specific layer (e.g. 4739 ``LAYERVERSION_mylayer``). 4740 4741 :term:`LD` 4742 The minimal command and arguments used to run the linker. 4743 4744 :term:`LDFLAGS` 4745 Specifies the flags to pass to the linker. This variable is exported 4746 to an environment variable and thus made visible to the software 4747 being built during the compilation step. 4748 4749 Default initialization for :term:`LDFLAGS` varies depending on what is 4750 being built: 4751 4752 - :term:`TARGET_LDFLAGS` when building for the 4753 target 4754 4755 - :term:`BUILD_LDFLAGS` when building for the 4756 build host (i.e. ``-native``) 4757 4758 - :term:`BUILDSDK_LDFLAGS` when building for 4759 an SDK (i.e. ``nativesdk-``) 4760 4761 :term:`LEAD_SONAME` 4762 Specifies the lead (or primary) compiled library file (i.e. ``.so``) 4763 that the :ref:`ref-classes-debian` class applies its 4764 naming policy to given a recipe that packages multiple libraries. 4765 4766 This variable works in conjunction with the :ref:`ref-classes-debian` 4767 class. 4768 4769 :term:`LIC_FILES_CHKSUM` 4770 Checksums of the license text in the recipe source code. 4771 4772 This variable tracks changes in license text of the source code 4773 files. If the license text is changed, it will trigger a build 4774 failure, which gives the developer an opportunity to review any 4775 license change. 4776 4777 This variable must be defined for all recipes (unless 4778 :term:`LICENSE` is set to "CLOSED"). 4779 4780 For more information, see the ":ref:`dev-manual/licenses:tracking license changes`" 4781 section in the Yocto Project Development Tasks Manual. 4782 4783 :term:`LICENSE` 4784 The list of source licenses for the recipe. Follow these rules: 4785 4786 - Do not use spaces within individual license names. 4787 4788 - Separate license names using \| (pipe) when there is a choice 4789 between licenses. 4790 4791 - Separate license names using & (ampersand) when there are 4792 multiple licenses for different parts of the source. 4793 4794 - You can use spaces between license names. 4795 4796 - For standard licenses, use the names of the files in 4797 ``meta/files/common-licenses/`` or the 4798 :term:`SPDXLICENSEMAP` flag names defined in 4799 ``meta/conf/licenses.conf``. 4800 4801 Here are some examples:: 4802 4803 LICENSE = "LGPL-2.1-only | GPL-3.0-only" 4804 LICENSE = "MPL-1.0 & LGPL-2.1-only" 4805 LICENSE = "GPL-2.0-or-later" 4806 4807 The first example is from the 4808 recipes for Qt, which the user may choose to distribute under either 4809 the LGPL version 2.1 or GPL version 3. The second example is from 4810 Cairo where two licenses cover different parts of the source code. 4811 The final example is from ``sysstat``, which presents a single 4812 license. 4813 4814 You can also specify licenses on a per-package basis to handle 4815 situations where components of the output have different licenses. 4816 For example, a piece of software whose code is licensed under GPLv2 4817 but has accompanying documentation licensed under the GNU Free 4818 Documentation License 1.2 could be specified as follows:: 4819 4820 LICENSE = "GFDL-1.2 & GPL-2.0-only" 4821 LICENSE:${PN} = "GPL-2.0.only" 4822 LICENSE:${PN}-doc = "GFDL-1.2" 4823 4824 :term:`LICENSE_CREATE_PACKAGE` 4825 Setting :term:`LICENSE_CREATE_PACKAGE` to "1" causes the OpenEmbedded 4826 build system to create an extra package (i.e. 4827 ``${``\ :term:`PN`\ ``}-lic``) for each recipe and to add 4828 those packages to the 4829 :term:`RRECOMMENDS`\ ``:${PN}``. 4830 4831 The ``${PN}-lic`` package installs a directory in 4832 ``/usr/share/licenses`` named ``${PN}``, which is the recipe's base 4833 name, and installs files in that directory that contain license and 4834 copyright information (i.e. copies of the appropriate license files 4835 from ``meta/common-licenses`` that match the licenses specified in 4836 the :term:`LICENSE` variable of the recipe metadata 4837 and copies of files marked in 4838 :term:`LIC_FILES_CHKSUM` as containing 4839 license text). 4840 4841 For related information on providing license text, see the 4842 :term:`COPY_LIC_DIRS` variable, the 4843 :term:`COPY_LIC_MANIFEST` variable, and the 4844 ":ref:`dev-manual/licenses:providing license text`" 4845 section in the Yocto Project Development Tasks Manual. 4846 4847 :term:`LICENSE_FLAGS` 4848 Specifies additional flags for a recipe you must allow through 4849 :term:`LICENSE_FLAGS_ACCEPTED` in 4850 order for the recipe to be built. When providing multiple flags, 4851 separate them with spaces. 4852 4853 This value is independent of :term:`LICENSE` and is 4854 typically used to mark recipes that might require additional licenses 4855 in order to be used in a commercial product. For more information, 4856 see the 4857 ":ref:`dev-manual/licenses:enabling commercially licensed recipes`" 4858 section in the Yocto Project Development Tasks Manual. 4859 4860 :term:`LICENSE_FLAGS_ACCEPTED` 4861 Lists license flags that when specified in 4862 :term:`LICENSE_FLAGS` within a recipe should not 4863 prevent that recipe from being built. For more information, see the 4864 ":ref:`dev-manual/licenses:enabling commercially licensed recipes`" 4865 section in the Yocto Project Development Tasks Manual. 4866 4867 :term:`LICENSE_PATH` 4868 Path to additional licenses used during the build. By default, the 4869 OpenEmbedded build system uses :term:`COMMON_LICENSE_DIR` to define the 4870 directory that holds common license text used during the build. The 4871 :term:`LICENSE_PATH` variable allows you to extend that location to other 4872 areas that have additional licenses:: 4873 4874 LICENSE_PATH += "path-to-additional-common-licenses" 4875 4876 :term:`LINUX_KERNEL_TYPE` 4877 Defines the kernel type to be used in assembling the configuration. 4878 The linux-yocto recipes define "standard", "tiny", and "preempt-rt" 4879 kernel types. See the ":ref:`kernel-dev/advanced:kernel types`" 4880 section in the 4881 Yocto Project Linux Kernel Development Manual for more information on 4882 kernel types. 4883 4884 If you do not specify a :term:`LINUX_KERNEL_TYPE`, it defaults to 4885 "standard". Together with :term:`KMACHINE`, the 4886 :term:`LINUX_KERNEL_TYPE` variable defines the search arguments used by 4887 the kernel tools to find the appropriate description within the 4888 kernel :term:`Metadata` with which to build out the sources 4889 and configuration. 4890 4891 :term:`LINUX_VERSION` 4892 The Linux version from ``kernel.org`` on which the Linux kernel image 4893 being built using the OpenEmbedded build system is based. You define 4894 this variable in the kernel recipe. For example, the 4895 ``linux-yocto-3.4.bb`` kernel recipe found in 4896 ``meta/recipes-kernel/linux`` defines the variables as follows:: 4897 4898 LINUX_VERSION ?= "3.4.24" 4899 4900 The :term:`LINUX_VERSION` variable is used to define :term:`PV` 4901 for the recipe:: 4902 4903 PV = "${LINUX_VERSION}+git${SRCPV}" 4904 4905 :term:`LINUX_VERSION_EXTENSION` 4906 A string extension compiled into the version string of the Linux 4907 kernel built with the OpenEmbedded build system. You define this 4908 variable in the kernel recipe. For example, the linux-yocto kernel 4909 recipes all define the variable as follows:: 4910 4911 LINUX_VERSION_EXTENSION ?= "-yocto-${LINUX_KERNEL_TYPE}" 4912 4913 Defining this variable essentially sets the Linux kernel 4914 configuration item ``CONFIG_LOCALVERSION``, which is visible through 4915 the ``uname`` command. Here is an example that shows the extension 4916 assuming it was set as previously shown:: 4917 4918 $ uname -r 4919 3.7.0-rc8-custom 4920 4921 :term:`LOG_DIR` 4922 Specifies the directory to which the OpenEmbedded build system writes 4923 overall log files. The default directory is ``${TMPDIR}/log``. 4924 4925 For the directory containing logs specific to each task, see the 4926 :term:`T` variable. 4927 4928 :term:`MACHINE` 4929 Specifies the target device for which the image is built. You define 4930 :term:`MACHINE` in the ``local.conf`` file found in the 4931 :term:`Build Directory`. By default, :term:`MACHINE` is set to 4932 "qemux86", which is an x86-based architecture machine to be emulated 4933 using QEMU:: 4934 4935 MACHINE ?= "qemux86" 4936 4937 The variable corresponds to a machine configuration file of the same 4938 name, through which machine-specific configurations are set. Thus, 4939 when :term:`MACHINE` is set to "qemux86", the corresponding 4940 ``qemux86.conf`` machine configuration file can be found in 4941 the :term:`Source Directory` in 4942 ``meta/conf/machine``. 4943 4944 The list of machines supported by the Yocto Project as shipped 4945 include the following:: 4946 4947 MACHINE ?= "qemuarm" 4948 MACHINE ?= "qemuarm64" 4949 MACHINE ?= "qemumips" 4950 MACHINE ?= "qemumips64" 4951 MACHINE ?= "qemuppc" 4952 MACHINE ?= "qemux86" 4953 MACHINE ?= "qemux86-64" 4954 MACHINE ?= "genericx86" 4955 MACHINE ?= "genericx86-64" 4956 MACHINE ?= "beaglebone" 4957 MACHINE ?= "edgerouter" 4958 4959 The last five are Yocto Project reference hardware 4960 boards, which are provided in the ``meta-yocto-bsp`` layer. 4961 4962 .. note:: 4963 4964 Adding additional Board Support Package (BSP) layers to your 4965 configuration adds new possible settings for :term:`MACHINE`. 4966 4967 :term:`MACHINE_ARCH` 4968 Specifies the name of the machine-specific architecture. This 4969 variable is set automatically from :term:`MACHINE` or 4970 :term:`TUNE_PKGARCH`. You should not hand-edit 4971 the :term:`MACHINE_ARCH` variable. 4972 4973 :term:`MACHINE_ESSENTIAL_EXTRA_RDEPENDS` 4974 A list of required machine-specific packages to install as part of 4975 the image being built. The build process depends on these packages 4976 being present. Furthermore, because this is a "machine-essential" 4977 variable, the list of packages are essential for the machine to boot. 4978 The impact of this variable affects images based on 4979 ``packagegroup-core-boot``, including the ``core-image-minimal`` 4980 image. 4981 4982 This variable is similar to the 4983 :term:`MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS` variable with the exception 4984 that the image being built has a build dependency on the variable's 4985 list of packages. In other words, the image will not build if a file 4986 in this list is not found. 4987 4988 As an example, suppose the machine for which you are building 4989 requires ``example-init`` to be run during boot to initialize the 4990 hardware. In this case, you would use the following in the machine's 4991 ``.conf`` configuration file:: 4992 4993 MACHINE_ESSENTIAL_EXTRA_RDEPENDS += "example-init" 4994 4995 :term:`MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS` 4996 A list of recommended machine-specific packages to install as part of 4997 the image being built. The build process does not depend on these 4998 packages being present. However, because this is a 4999 "machine-essential" variable, the list of packages are essential for 5000 the machine to boot. The impact of this variable affects images based 5001 on ``packagegroup-core-boot``, including the ``core-image-minimal`` 5002 image. 5003 5004 This variable is similar to the :term:`MACHINE_ESSENTIAL_EXTRA_RDEPENDS` 5005 variable with the exception that the image being built does not have 5006 a build dependency on the variable's list of packages. In other 5007 words, the image will still build if a package in this list is not 5008 found. Typically, this variable is used to handle essential kernel 5009 modules, whose functionality may be selected to be built into the 5010 kernel rather than as a module, in which case a package will not be 5011 produced. 5012 5013 Consider an example where you have a custom kernel where a specific 5014 touchscreen driver is required for the machine to be usable. However, 5015 the driver can be built as a module or into the kernel depending on 5016 the kernel configuration. If the driver is built as a module, you 5017 want it to be installed. But, when the driver is built into the 5018 kernel, you still want the build to succeed. This variable sets up a 5019 "recommends" relationship so that in the latter case, the build will 5020 not fail due to the missing package. To accomplish this, assuming the 5021 package for the module was called ``kernel-module-ab123``, you would 5022 use the following in the machine's ``.conf`` configuration file:: 5023 5024 MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS += "kernel-module-ab123" 5025 5026 .. note:: 5027 5028 In this example, the ``kernel-module-ab123`` recipe needs to 5029 explicitly set its :term:`PACKAGES` variable to ensure that BitBake 5030 does not use the kernel recipe's :term:`PACKAGES_DYNAMIC` variable to 5031 satisfy the dependency. 5032 5033 Some examples of these machine essentials are flash, screen, 5034 keyboard, mouse, or touchscreen drivers (depending on the machine). 5035 5036 :term:`MACHINE_EXTRA_RDEPENDS` 5037 A list of machine-specific packages to install as part of the image 5038 being built that are not essential for the machine to boot. However, 5039 the build process for more fully-featured images depends on the 5040 packages being present. 5041 5042 This variable affects all images based on ``packagegroup-base``, 5043 which does not include the ``core-image-minimal`` or 5044 ``core-image-full-cmdline`` images. 5045 5046 The variable is similar to the :term:`MACHINE_EXTRA_RRECOMMENDS` variable 5047 with the exception that the image being built has a build dependency 5048 on the variable's list of packages. In other words, the image will 5049 not build if a file in this list is not found. 5050 5051 An example is a machine that has WiFi capability but is not essential 5052 for the machine to boot the image. However, if you are building a 5053 more fully-featured image, you want to enable the WiFi. The package 5054 containing the firmware for the WiFi hardware is always expected to 5055 exist, so it is acceptable for the build process to depend upon 5056 finding the package. In this case, assuming the package for the 5057 firmware was called ``wifidriver-firmware``, you would use the 5058 following in the ``.conf`` file for the machine:: 5059 5060 MACHINE_EXTRA_RDEPENDS += "wifidriver-firmware" 5061 5062 :term:`MACHINE_EXTRA_RRECOMMENDS` 5063 A list of machine-specific packages to install as part of the image 5064 being built that are not essential for booting the machine. The image 5065 being built has no build dependency on this list of packages. 5066 5067 This variable affects only images based on ``packagegroup-base``, 5068 which does not include the ``core-image-minimal`` or 5069 ``core-image-full-cmdline`` images. 5070 5071 This variable is similar to the :term:`MACHINE_EXTRA_RDEPENDS` variable 5072 with the exception that the image being built does not have a build 5073 dependency on the variable's list of packages. In other words, the 5074 image will build if a file in this list is not found. 5075 5076 An example is a machine that has WiFi capability but is not essential 5077 For the machine to boot the image. However, if you are building a 5078 more fully-featured image, you want to enable WiFi. In this case, the 5079 package containing the WiFi kernel module will not be produced if the 5080 WiFi driver is built into the kernel, in which case you still want 5081 the build to succeed instead of failing as a result of the package 5082 not being found. To accomplish this, assuming the package for the 5083 module was called ``kernel-module-examplewifi``, you would use the 5084 following in the ``.conf`` file for the machine:: 5085 5086 MACHINE_EXTRA_RRECOMMENDS += "kernel-module-examplewifi" 5087 5088 :term:`MACHINE_FEATURES` 5089 Specifies the list of hardware features the 5090 :term:`MACHINE` is capable of supporting. For related 5091 information on enabling features, see the 5092 :term:`DISTRO_FEATURES`, 5093 :term:`COMBINED_FEATURES`, and 5094 :term:`IMAGE_FEATURES` variables. 5095 5096 For a list of hardware features supported by the Yocto Project as 5097 shipped, see the ":ref:`ref-features-machine`" section. 5098 5099 :term:`MACHINE_FEATURES_BACKFILL` 5100 A list of space-separated features to be added to 5101 :term:`MACHINE_FEATURES` if not also present in 5102 :term:`MACHINE_FEATURES_BACKFILL_CONSIDERED`. 5103 5104 This variable is set in the ``meta/conf/bitbake.conf`` file. It is not 5105 intended to be user-configurable. It is best to just reference the 5106 variable to see which machine features are being 5107 :ref:`backfilled <ref-features-backfill>` for all machine configurations. 5108 5109 :term:`MACHINE_FEATURES_BACKFILL_CONSIDERED` 5110 A list of space-separated features from :term:`MACHINE_FEATURES_BACKFILL` 5111 that should not be :ref:`backfilled <ref-features-backfill>` (i.e. added 5112 to :term:`MACHINE_FEATURES`) during the build. 5113 5114 This corresponds to an opt-out mechanism. When new default machine 5115 features are introduced, machine definition maintainers can review 5116 (`consider`) them and decide to exclude them from the 5117 :ref:`backfilled <ref-features-backfill>` features. Therefore, the 5118 combination of :term:`MACHINE_FEATURES_BACKFILL` and 5119 :term:`MACHINE_FEATURES_BACKFILL_CONSIDERED` makes it possible to 5120 add new default features without breaking existing machine definitions. 5121 5122 :term:`MACHINEOVERRIDES` 5123 A colon-separated list of overrides that apply to the current 5124 machine. By default, this list includes the value of 5125 :term:`MACHINE`. 5126 5127 You can extend :term:`MACHINEOVERRIDES` to add extra overrides that 5128 should apply to a machine. For example, all machines emulated in QEMU 5129 (e.g. ``qemuarm``, ``qemux86``, and so forth) include a file named 5130 ``meta/conf/machine/include/qemu.inc`` that prepends the following 5131 override to :term:`MACHINEOVERRIDES`:: 5132 5133 MACHINEOVERRIDES =. "qemuall:" 5134 5135 This 5136 override allows variables to be overridden for all machines emulated 5137 in QEMU, like in the following example from the ``connman-conf`` 5138 recipe:: 5139 5140 SRC_URI:append:qemuall = " file://wired.config \ 5141 file://wired-setup \ 5142 " 5143 5144 The underlying mechanism behind 5145 :term:`MACHINEOVERRIDES` is simply that it is included in the default 5146 value of :term:`OVERRIDES`. 5147 5148 :term:`MAINTAINER` 5149 The email address of the distribution maintainer. 5150 5151 :term:`MESON_BUILDTYPE` 5152 Value of the Meson ``--buildtype`` argument used by the 5153 :ref:`ref-classes-meson` class. It defaults to ``debug`` if 5154 :term:`DEBUG_BUILD` is set to "1", and ``plain`` otherwise. 5155 5156 See `Meson build options <https://mesonbuild.com/Builtin-options.html>`__ 5157 for the values you could set in a recipe. Values such as ``plain``, 5158 ``debug``, ``debugoptimized``, ``release`` and ``minsize`` allow 5159 you to specify the inclusion of debugging symbols and the compiler 5160 optimizations (none, performance or size). 5161 5162 :term:`METADATA_BRANCH` 5163 The branch currently checked out for the OpenEmbedded-Core layer (path 5164 determined by :term:`COREBASE`). 5165 5166 :term:`METADATA_REVISION` 5167 The revision currently checked out for the OpenEmbedded-Core layer (path 5168 determined by :term:`COREBASE`). 5169 5170 :term:`MIME_XDG_PACKAGES` 5171 The current implementation of the :ref:`ref-classes-mime-xdg` 5172 class cannot detect ``.desktop`` files installed through absolute 5173 symbolic links. Use this setting to make the class create post-install 5174 and post-remove scripts for these packages anyway, to invoke the 5175 ``update-destop-database`` command. 5176 5177 :term:`MIRRORS` 5178 Specifies additional paths from which the OpenEmbedded build system 5179 gets source code. When the build system searches for source code, it 5180 first tries the local download directory. If that location fails, the 5181 build system tries locations defined by 5182 :term:`PREMIRRORS`, the upstream source, and then 5183 locations specified by :term:`MIRRORS` in that order. 5184 5185 Assuming your distribution (:term:`DISTRO`) is "poky", 5186 the default value for :term:`MIRRORS` is defined in the 5187 ``conf/distro/poky.conf`` file in the ``meta-poky`` Git repository. 5188 5189 :term:`MLPREFIX` 5190 Specifies a prefix has been added to :term:`PN` to create a 5191 special version of a recipe or package (i.e. a Multilib version). The 5192 variable is used in places where the prefix needs to be added to or 5193 removed from a name (e.g. the :term:`BPN` variable). 5194 :term:`MLPREFIX` gets set when a prefix has been added to :term:`PN`. 5195 5196 .. note:: 5197 5198 The "ML" in :term:`MLPREFIX` stands for "MultiLib". This representation 5199 is historical and comes from a time when ":ref:`ref-classes-nativesdk`" 5200 was a suffix rather than a prefix on the recipe name. When 5201 ":ref:`ref-classes-nativesdk`" was turned into a prefix, it made sense 5202 to set :term:`MLPREFIX` for it as well. 5203 5204 To help understand when :term:`MLPREFIX` might be needed, consider when 5205 :term:`BBCLASSEXTEND` is used to provide a :ref:`ref-classes-nativesdk` 5206 version of a recipe in addition to the target version. If that recipe 5207 declares build-time dependencies on tasks in other recipes by using 5208 :term:`DEPENDS`, then a dependency on "foo" will automatically get 5209 rewritten to a dependency on "nativesdk-foo". However, dependencies like 5210 the following will not get rewritten automatically:: 5211 5212 do_foo[depends] += "recipe:do_foo" 5213 5214 If you want such a dependency to also get transformed, you can do the 5215 following:: 5216 5217 do_foo[depends] += "${MLPREFIX}recipe:do_foo" 5218 5219 :term:`module_autoload` 5220 This variable has been replaced by the :term:`KERNEL_MODULE_AUTOLOAD` 5221 variable. You should replace all occurrences of :term:`module_autoload` 5222 with additions to :term:`KERNEL_MODULE_AUTOLOAD`, for example:: 5223 5224 module_autoload_rfcomm = "rfcomm" 5225 5226 should now be replaced with:: 5227 5228 KERNEL_MODULE_AUTOLOAD += "rfcomm" 5229 5230 See the :term:`KERNEL_MODULE_AUTOLOAD` variable for more information. 5231 5232 :term:`module_conf` 5233 Specifies `modprobe.d <https://linux.die.net/man/5/modprobe.d>`__ 5234 syntax lines for inclusion in the ``/etc/modprobe.d/modname.conf`` 5235 file. 5236 5237 You can use this variable anywhere that it can be recognized by the 5238 kernel recipe or out-of-tree kernel module recipe (e.g. a machine 5239 configuration file, a distribution configuration file, an append file 5240 for the recipe, or the recipe itself). If you use this variable, you 5241 must also be sure to list the module name in the 5242 :term:`KERNEL_MODULE_PROBECONF` 5243 variable. 5244 5245 Here is the general syntax:: 5246 5247 module_conf_module_name = "modprobe.d-syntax" 5248 5249 You must use the kernel module name override. 5250 5251 Run ``man modprobe.d`` in the shell to find out more information on 5252 the exact syntax you want to provide with :term:`module_conf`. 5253 5254 Including :term:`module_conf` causes the OpenEmbedded build system to 5255 populate the ``/etc/modprobe.d/modname.conf`` file with 5256 ``modprobe.d`` syntax lines. Here is an example that adds the options 5257 ``arg1`` and ``arg2`` to a module named ``mymodule``:: 5258 5259 module_conf_mymodule = "options mymodule arg1=val1 arg2=val2" 5260 5261 For information on how to specify kernel modules to auto-load on 5262 boot, see the :term:`KERNEL_MODULE_AUTOLOAD` variable. 5263 5264 :term:`MODULE_TARBALL_DEPLOY` 5265 Controls creation of the ``modules-*.tgz`` file. Set this variable to 5266 "0" to disable creation of this file, which contains all of the 5267 kernel modules resulting from a kernel build. 5268 5269 :term:`MODULE_TARBALL_LINK_NAME` 5270 The link name of the kernel module tarball. This variable is set in 5271 the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as follows:: 5272 5273 MODULE_TARBALL_LINK_NAME ?= "${KERNEL_ARTIFACT_LINK_NAME}" 5274 5275 The value 5276 of the ``KERNEL_ARTIFACT_LINK_NAME`` variable, which is set in the 5277 same file, has the following value:: 5278 5279 KERNEL_ARTIFACT_LINK_NAME ?= "${MACHINE}" 5280 5281 See the :term:`MACHINE` variable for additional information. 5282 5283 :term:`MODULE_TARBALL_NAME` 5284 The base name of the kernel module tarball. This variable is set in 5285 the ``meta/classes-recipe/kernel-artifact-names.bbclass`` file as follows:: 5286 5287 MODULE_TARBALL_NAME ?= "${KERNEL_ARTIFACT_NAME}" 5288 5289 See :term:`KERNEL_ARTIFACT_NAME` for additional information. 5290 5291 :term:`MOUNT_BASE` 5292 On non-systemd systems (where ``udev-extraconf`` is being used), 5293 specifies the base directory for auto-mounting filesystems. The 5294 default value is "/run/media". 5295 5296 :term:`MULTIMACH_TARGET_SYS` 5297 Uniquely identifies the type of the target system for which packages 5298 are being built. This variable allows output for different types of 5299 target systems to be put into different subdirectories of the same 5300 output directory. 5301 5302 The default value of this variable is:: 5303 5304 ${PACKAGE_ARCH}${TARGET_VENDOR}-${TARGET_OS} 5305 5306 Some classes (e.g. :ref:`ref-classes-cross-canadian`) modify the 5307 :term:`MULTIMACH_TARGET_SYS` value. 5308 5309 See the :term:`STAMP` variable for an example. See the 5310 :term:`STAGING_DIR_TARGET` variable for more information. 5311 5312 :term:`NATIVELSBSTRING` 5313 A string identifying the host distribution. Strings consist of the 5314 host distributor ID followed by the release, as reported by the 5315 ``lsb_release`` tool or as read from ``/etc/lsb-release``. For 5316 example, when running a build on Ubuntu 12.10, the value is 5317 "Ubuntu-12.10". If this information is unable to be determined, the 5318 value resolves to "Unknown". 5319 5320 This variable is used by default to isolate native shared state 5321 packages for different distributions (e.g. to avoid problems with 5322 ``glibc`` version incompatibilities). Additionally, the variable is 5323 checked against 5324 :term:`SANITY_TESTED_DISTROS` if that 5325 variable is set. 5326 5327 :term:`NM` 5328 The minimal command and arguments to run ``nm``. 5329 5330 :term:`NO_GENERIC_LICENSE` 5331 Avoids QA errors when you use a non-common, non-CLOSED license in a 5332 recipe. There are packages, such as the linux-firmware package, with many 5333 licenses that are not in any way common. Also, new licenses are added 5334 occasionally to avoid introducing a lot of common license files, 5335 which are only applicable to a specific package. 5336 :term:`NO_GENERIC_LICENSE` is used to allow copying a license that does 5337 not exist in common licenses. 5338 5339 The following example shows how to add :term:`NO_GENERIC_LICENSE` to a 5340 recipe:: 5341 5342 NO_GENERIC_LICENSE[license_name] = "license_file_in_fetched_source" 5343 5344 Here is an example that 5345 uses the ``LICENSE.Abilis.txt`` file as the license from the fetched 5346 source:: 5347 5348 NO_GENERIC_LICENSE[Firmware-Abilis] = "LICENSE.Abilis.txt" 5349 5350 :term:`NO_RECOMMENDATIONS` 5351 Prevents installation of all "recommended-only" packages. 5352 Recommended-only packages are packages installed only through the 5353 :term:`RRECOMMENDS` variable). Setting the 5354 :term:`NO_RECOMMENDATIONS` variable to "1" turns this feature on:: 5355 5356 NO_RECOMMENDATIONS = "1" 5357 5358 You can set this variable globally in your ``local.conf`` file or you 5359 can attach it to a specific image recipe by using the recipe name 5360 override:: 5361 5362 NO_RECOMMENDATIONS:pn-target_image = "1" 5363 5364 It is important to realize that if you choose to not install packages 5365 using this variable and some other packages are dependent on them 5366 (i.e. listed in a recipe's :term:`RDEPENDS` 5367 variable), the OpenEmbedded build system ignores your request and 5368 will install the packages to avoid dependency errors. 5369 5370 .. note:: 5371 5372 Some recommended packages might be required for certain system 5373 functionality, such as kernel modules. It is up to you to add 5374 packages with the :term:`IMAGE_INSTALL` variable. 5375 5376 This variable is only supported when using the IPK and RPM 5377 packaging backends. DEB is not supported. 5378 5379 See the :term:`BAD_RECOMMENDATIONS` and 5380 the :term:`PACKAGE_EXCLUDE` variables for 5381 related information. 5382 5383 :term:`NOAUTOPACKAGEDEBUG` 5384 Disables auto package from splitting ``.debug`` files. If a recipe 5385 requires ``FILES:${PN}-dbg`` to be set manually, the 5386 :term:`NOAUTOPACKAGEDEBUG` can be defined allowing you to define the 5387 content of the debug package. For example:: 5388 5389 NOAUTOPACKAGEDEBUG = "1" 5390 FILES:${PN}-dev = "${includedir}/${QT_DIR_NAME}/Qt/*" 5391 FILES:${PN}-dbg = "/usr/src/debug/" 5392 FILES:${QT_BASE_NAME}-demos-doc = "${docdir}/${QT_DIR_NAME}/qch/qt.qch" 5393 5394 :term:`NON_MULTILIB_RECIPES` 5395 A list of recipes that should not be built for multilib. OE-Core's 5396 ``multilib.conf`` file defines a reasonable starting point for this 5397 list with:: 5398 5399 NON_MULTILIB_RECIPES = "grub grub-efi make-mod-scripts ovmf u-boot" 5400 5401 :term:`OBJCOPY` 5402 The minimal command and arguments to run ``objcopy``. 5403 5404 :term:`OBJDUMP` 5405 The minimal command and arguments to run ``objdump``. 5406 5407 :term:`OE_BINCONFIG_EXTRA_MANGLE` 5408 When inheriting the :ref:`ref-classes-binconfig` class, 5409 this variable specifies additional arguments passed to the "sed" 5410 command. The sed command alters any paths in configuration scripts 5411 that have been set up during compilation. Inheriting this class 5412 results in all paths in these scripts being changed to point into the 5413 ``sysroots/`` directory so that all builds that use the script will 5414 use the correct directories for the cross compiling layout. 5415 5416 See the ``meta/classes-recipe/binconfig.bbclass`` in the 5417 :term:`Source Directory` for details on how this class 5418 applies these additional sed command arguments. 5419 5420 :term:`OECMAKE_GENERATOR` 5421 A variable for the :ref:`ref-classes-cmake` class, allowing to choose 5422 which back-end will be generated by CMake to build an application. 5423 5424 By default, this variable is set to ``Ninja``, which is faster than GNU 5425 make, but if building is broken with Ninja, a recipe can use this 5426 variable to use GNU make instead:: 5427 5428 OECMAKE_GENERATOR = "Unix Makefiles" 5429 5430 :term:`OE_IMPORTS` 5431 An internal variable used to tell the OpenEmbedded build system what 5432 Python modules to import for every Python function run by the system. 5433 5434 .. note:: 5435 5436 Do not set this variable. It is for internal use only. 5437 5438 :term:`OE_INIT_ENV_SCRIPT` 5439 The name of the build environment setup script for the purposes of 5440 setting up the environment within the extensible SDK. The default 5441 value is "oe-init-build-env". 5442 5443 If you use a custom script to set up your build environment, set the 5444 :term:`OE_INIT_ENV_SCRIPT` variable to its name. 5445 5446 :term:`OE_TERMINAL` 5447 Controls how the OpenEmbedded build system spawns interactive 5448 terminals on the host development system (e.g. using the BitBake 5449 command with the ``-c devshell`` command-line option). For more 5450 information, see the ":ref:`dev-manual/development-shell:using a development shell`" section in 5451 the Yocto Project Development Tasks Manual. 5452 5453 You can use the following values for the :term:`OE_TERMINAL` variable: 5454 5455 - auto 5456 - gnome 5457 - xfce 5458 - rxvt 5459 - screen 5460 - konsole 5461 - none 5462 5463 :term:`OEROOT` 5464 The directory from which the top-level build environment setup script 5465 is sourced. The Yocto Project provides a top-level build environment 5466 setup script: :ref:`structure-core-script`. When you run this 5467 script, the :term:`OEROOT` variable resolves to the directory that 5468 contains the script. 5469 5470 For additional information on how this variable is used, see the 5471 initialization script. 5472 5473 :term:`OLDEST_KERNEL` 5474 Declares the oldest version of the Linux kernel that the produced 5475 binaries must support. This variable is passed into the build of the 5476 Embedded GNU C Library (``glibc``). 5477 5478 The default for this variable comes from the 5479 ``meta/conf/bitbake.conf`` configuration file. You can override this 5480 default by setting the variable in a custom distribution 5481 configuration file. 5482 5483 :term:`OVERLAYFS_ETC_DEVICE` 5484 When the :ref:`ref-classes-overlayfs-etc` class is 5485 inherited, specifies the device to be mounted for the read/write 5486 layer of ``/etc``. There is no default, so you must set this if you 5487 wish to enable :ref:`ref-classes-overlayfs-etc`, for 5488 example, assuming ``/dev/mmcblk0p2`` was the desired device:: 5489 5490 OVERLAYFS_ETC_DEVICE = "/dev/mmcblk0p2" 5491 5492 :term:`OVERLAYFS_ETC_EXPOSE_LOWER` 5493 When the :ref:`ref-classes-overlayfs-etc` class is 5494 inherited, if set to "1" then a read-only access to the original 5495 ``/etc`` content will be provided as a ``lower/`` subdirectory of 5496 :term:`OVERLAYFS_ETC_MOUNT_POINT`. The default value is "0". 5497 5498 :term:`OVERLAYFS_ETC_FSTYPE` 5499 When the :ref:`ref-classes-overlayfs-etc` class is 5500 inherited, specifies the file system type for the read/write 5501 layer of ``/etc``. There is no default, so you must set this if you 5502 wish to enable :ref:`ref-classes-overlayfs-etc`, 5503 for example, assuming the file system is ext4:: 5504 5505 OVERLAYFS_ETC_FSTYPE = "ext4" 5506 5507 :term:`OVERLAYFS_ETC_MOUNT_OPTIONS` 5508 When the :ref:`ref-classes-overlayfs-etc` class is 5509 inherited, specifies the mount options for the read-write layer. 5510 The default value is "defaults". 5511 5512 :term:`OVERLAYFS_ETC_MOUNT_POINT` 5513 When the :ref:`ref-classes-overlayfs-etc` class is 5514 inherited, specifies the parent mount path for the filesystem layers. 5515 There is no default, so you must set this if you wish to enable 5516 :ref:`ref-classes-overlayfs-etc`, for example if the desired path is 5517 "/data":: 5518 5519 OVERLAYFS_ETC_MOUNT_POINT = "/data" 5520 5521 :term:`OVERLAYFS_ETC_USE_ORIG_INIT_NAME` 5522 When the :ref:`ref-classes-overlayfs-etc` class is inherited, controls 5523 how the generated init will be named. For more information, see the 5524 :ref:`ref-classes-overlayfs-etc` class documentation. The default value 5525 is "1". 5526 5527 :term:`OVERLAYFS_MOUNT_POINT` 5528 When inheriting the :ref:`ref-classes-overlayfs` class, 5529 specifies mount point(s) to be used. For example:: 5530 5531 OVERLAYFS_MOUNT_POINT[data] = "/data" 5532 5533 The assumes you have a ``data.mount`` systemd unit defined elsewhere in 5534 your BSP (e.g. in ``systemd-machine-units`` recipe) and it is installed 5535 into the image. For more information see :ref:`ref-classes-overlayfs`. 5536 5537 .. note:: 5538 5539 Although the :ref:`ref-classes-overlayfs` class is 5540 inherited by individual recipes, :term:`OVERLAYFS_MOUNT_POINT` 5541 should be set in your machine configuration. 5542 5543 :term:`OVERLAYFS_QA_SKIP` 5544 When inheriting the :ref:`ref-classes-overlayfs` class, 5545 provides the ability to disable QA checks for particular overlayfs 5546 mounts. For example:: 5547 5548 OVERLAYFS_QA_SKIP[data] = "mount-configured" 5549 5550 .. note:: 5551 5552 Although the :ref:`ref-classes-overlayfs` class is 5553 inherited by individual recipes, :term:`OVERLAYFS_QA_SKIP` 5554 should be set in your machine configuration. 5555 5556 :term:`OVERLAYFS_WRITABLE_PATHS` 5557 When inheriting the :ref:`ref-classes-overlayfs` class, 5558 specifies writable paths used at runtime for the recipe. For 5559 example:: 5560 5561 OVERLAYFS_WRITABLE_PATHS[data] = "/usr/share/my-custom-application" 5562 5563 :term:`OVERRIDES` 5564 A colon-separated list of overrides that currently apply. Overrides 5565 are a BitBake mechanism that allows variables to be selectively 5566 overridden at the end of parsing. The set of overrides in 5567 :term:`OVERRIDES` represents the "state" during building, which includes 5568 the current recipe being built, the machine for which it is being 5569 built, and so forth. 5570 5571 As an example, if the string "an-override" appears as an element in 5572 the colon-separated list in :term:`OVERRIDES`, then the following 5573 assignment will override ``FOO`` with the value "overridden" at the 5574 end of parsing:: 5575 5576 FOO:an-override = "overridden" 5577 5578 See the 5579 ":ref:`bitbake-user-manual/bitbake-user-manual-metadata:conditional syntax (overrides)`" 5580 section in the BitBake User Manual for more information on the 5581 overrides mechanism. 5582 5583 The default value of :term:`OVERRIDES` includes the values of the 5584 :term:`CLASSOVERRIDE`, 5585 :term:`MACHINEOVERRIDES`, and 5586 :term:`DISTROOVERRIDES` variables. Another 5587 important override included by default is ``pn-${PN}``. This override 5588 allows variables to be set for a single recipe within configuration 5589 (``.conf``) files. Here is an example:: 5590 5591 FOO:pn-myrecipe = "myrecipe-specific value" 5592 5593 .. note:: 5594 5595 An easy way to see what overrides apply is to search for :term:`OVERRIDES` 5596 in the output of the ``bitbake -e`` command. See the 5597 ":ref:`dev-manual/debugging:viewing variable values`" section in the Yocto 5598 Project Development Tasks Manual for more information. 5599 5600 :term:`P` 5601 The recipe name and version. :term:`P` is comprised of the following:: 5602 5603 ${PN}-${PV} 5604 5605 :term:`P4DIR` 5606 See :term:`bitbake:P4DIR` in the BitBake manual. 5607 5608 :term:`PACKAGE_ADD_METADATA` 5609 This variable defines additional metadata to add to packages. 5610 5611 You may find you need to inject additional metadata into packages. 5612 This variable allows you to do that by setting the injected data as 5613 the value. Multiple fields can be added by splitting the content with 5614 the literal separator "\n". 5615 5616 The suffixes '_IPK', '_DEB', or '_RPM' can be applied to the variable 5617 to do package type specific settings. It can also be made package 5618 specific by using the package name as a suffix. 5619 5620 You can find out more about applying this variable in the 5621 ":ref:`dev-manual/packages:adding custom metadata to packages`" 5622 section in the Yocto Project Development Tasks Manual. 5623 5624 :term:`PACKAGE_ARCH` 5625 The architecture of the resulting package or packages. 5626 5627 By default, the value of this variable is set to 5628 :term:`TUNE_PKGARCH` when building for the 5629 target, :term:`BUILD_ARCH` when building for the 5630 build host, and "${SDK_ARCH}-${SDKPKGSUFFIX}" when building for the 5631 SDK. 5632 5633 .. note:: 5634 5635 See :term:`SDK_ARCH` for more information. 5636 5637 However, if your recipe's output packages are built specific to the 5638 target machine rather than generally for the architecture of the 5639 machine, you should set :term:`PACKAGE_ARCH` to the value of 5640 :term:`MACHINE_ARCH` in the recipe as follows:: 5641 5642 PACKAGE_ARCH = "${MACHINE_ARCH}" 5643 5644 :term:`PACKAGE_ARCHS` 5645 Specifies a list of architectures compatible with the target machine. 5646 This variable is set automatically and should not normally be 5647 hand-edited. Entries are separated using spaces and listed in order 5648 of priority. The default value for :term:`PACKAGE_ARCHS` is "all any 5649 noarch ${PACKAGE_EXTRA_ARCHS} ${MACHINE_ARCH}". 5650 5651 :term:`PACKAGE_BEFORE_PN` 5652 Enables easily adding packages to :term:`PACKAGES` before ``${PN}`` so 5653 that those added packages can pick up files that would normally be 5654 included in the default package. 5655 5656 :term:`PACKAGE_CLASSES` 5657 This variable, which is set in the ``local.conf`` configuration file 5658 found in the ``conf`` folder of the 5659 :term:`Build Directory`, specifies the package manager the 5660 OpenEmbedded build system uses when packaging data. 5661 5662 You can provide one or more of the following arguments for the 5663 variable:: 5664 5665 PACKAGE_CLASSES ?= "package_rpm package_deb package_ipk" 5666 5667 The build system uses only the first argument in the list as the 5668 package manager when creating your image or SDK. However, packages 5669 will be created using any additional packaging classes you specify. 5670 For example, if you use the following in your ``local.conf`` file:: 5671 5672 PACKAGE_CLASSES ?= "package_ipk" 5673 5674 The OpenEmbedded build system uses 5675 the IPK package manager to create your image or SDK. 5676 5677 For information on packaging and build performance effects as a 5678 result of the package manager in use, see the 5679 ":ref:`ref-classes-package`" section. 5680 5681 :term:`PACKAGE_DEBUG_SPLIT_STYLE` 5682 Determines how to split up and package debug and source information 5683 when creating debugging packages to be used with the GNU Project 5684 Debugger (GDB). In general, based on the value of this variable, 5685 you can combine the source and debug info in a single package, 5686 you can break out the source into a separate package that can be 5687 installed independently, or you can choose to not have the source 5688 packaged at all. 5689 5690 The possible values of :term:`PACKAGE_DEBUG_SPLIT_STYLE` variable: 5691 5692 - "``.debug``": All debugging and source info is placed in a single 5693 ``*-dbg`` package; debug symbol files are placed next to the 5694 binary in a ``.debug`` directory so that, if a binary is installed 5695 into ``/bin``, the corresponding debug symbol file is installed 5696 in ``/bin/.debug``. Source files are installed in the same ``*-dbg`` 5697 package under ``/usr/src/debug``. 5698 5699 - "``debug-file-directory``": As above, all debugging and source info 5700 is placed in a single ``*-dbg`` package; debug symbol files are 5701 placed entirely under the directory ``/usr/lib/debug`` and separated 5702 by the path from where the binary is installed, so that if a binary 5703 is installed in ``/bin``, the corresponding debug symbols are installed 5704 in ``/usr/lib/debug/bin``, and so on. As above, source is installed 5705 in the same package under ``/usr/src/debug``. 5706 5707 - "``debug-with-srcpkg``": Debugging info is placed in the standard 5708 ``*-dbg`` package as with the ``.debug`` value, while source is 5709 placed in a separate ``*-src`` package, which can be installed 5710 independently. This is the default setting for this variable, 5711 as defined in Poky's ``bitbake.conf`` file. 5712 5713 - "``debug-without-src``": The same behavior as with the ``.debug`` 5714 setting, but no source is packaged at all. 5715 5716 .. note:: 5717 5718 Much of the above package splitting can be overridden via 5719 use of the :term:`INHIBIT_PACKAGE_DEBUG_SPLIT` variable. 5720 5721 You can find out more about debugging using GDB by reading the 5722 ":ref:`dev-manual/debugging:debugging with the gnu project debugger (gdb) remotely`" section 5723 in the Yocto Project Development Tasks Manual. 5724 5725 :term:`PACKAGE_EXCLUDE` 5726 Lists packages that should not be installed into an image. For 5727 example:: 5728 5729 PACKAGE_EXCLUDE = "package_name package_name package_name ..." 5730 5731 You can set this variable globally in your ``local.conf`` file or you 5732 can attach it to a specific image recipe by using the recipe name 5733 override:: 5734 5735 PACKAGE_EXCLUDE:pn-target_image = "package_name" 5736 5737 If you choose to not install a package using this variable and some 5738 other package is dependent on it (i.e. listed in a recipe's 5739 :term:`RDEPENDS` variable), the OpenEmbedded build 5740 system generates a fatal installation error. Because the build system 5741 halts the process with a fatal error, you can use the variable with 5742 an iterative development process to remove specific components from a 5743 system. 5744 5745 This variable is supported only when using the IPK and RPM 5746 packaging backends. DEB is not supported. 5747 5748 See the :term:`NO_RECOMMENDATIONS` and the 5749 :term:`BAD_RECOMMENDATIONS` variables for 5750 related information. 5751 5752 :term:`PACKAGE_EXCLUDE_COMPLEMENTARY` 5753 Prevents specific packages from being installed when you are 5754 installing complementary packages. 5755 5756 You might find that you want to prevent installing certain packages 5757 when you are installing complementary packages. For example, if you 5758 are using :term:`IMAGE_FEATURES` to install 5759 ``dev-pkgs``, you might not want to install all packages from a 5760 particular multilib. If you find yourself in this situation, you can 5761 use the :term:`PACKAGE_EXCLUDE_COMPLEMENTARY` variable to specify regular 5762 expressions to match the packages you want to exclude. 5763 5764 :term:`PACKAGE_EXTRA_ARCHS` 5765 Specifies the list of architectures compatible with the device CPU. 5766 This variable is useful when you build for several different devices 5767 that use miscellaneous processors such as XScale and ARM926-EJS. 5768 5769 :term:`PACKAGE_FEED_ARCHS` 5770 Optionally specifies the package architectures used as part of the 5771 package feed URIs during the build. When used, the 5772 :term:`PACKAGE_FEED_ARCHS` variable is appended to the final package feed 5773 URI, which is constructed using the 5774 :term:`PACKAGE_FEED_URIS` and 5775 :term:`PACKAGE_FEED_BASE_PATHS` 5776 variables. 5777 5778 .. note:: 5779 5780 You can use the :term:`PACKAGE_FEED_ARCHS` 5781 variable to allow specific package architectures. If you do 5782 not need to allow specific architectures, which is a common 5783 case, you can omit this variable. Omitting the variable results in 5784 all available architectures for the current machine being included 5785 into remote package feeds. 5786 5787 Consider the following example where the :term:`PACKAGE_FEED_URIS`, 5788 :term:`PACKAGE_FEED_BASE_PATHS`, and :term:`PACKAGE_FEED_ARCHS` variables are 5789 defined in your ``local.conf`` file:: 5790 5791 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \ 5792 https://example.com/packagerepos/updates" 5793 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev" 5794 PACKAGE_FEED_ARCHS = "all core2-64" 5795 5796 Given these settings, the resulting package feeds are as follows: 5797 5798 .. code-block:: none 5799 5800 https://example.com/packagerepos/release/rpm/all 5801 https://example.com/packagerepos/release/rpm/core2-64 5802 https://example.com/packagerepos/release/rpm-dev/all 5803 https://example.com/packagerepos/release/rpm-dev/core2-64 5804 https://example.com/packagerepos/updates/rpm/all 5805 https://example.com/packagerepos/updates/rpm/core2-64 5806 https://example.com/packagerepos/updates/rpm-dev/all 5807 https://example.com/packagerepos/updates/rpm-dev/core2-64 5808 5809 :term:`PACKAGE_FEED_BASE_PATHS` 5810 Specifies the base path used when constructing package feed URIs. The 5811 :term:`PACKAGE_FEED_BASE_PATHS` variable makes up the middle portion of a 5812 package feed URI used by the OpenEmbedded build system. The base path 5813 lies between the :term:`PACKAGE_FEED_URIS` 5814 and :term:`PACKAGE_FEED_ARCHS` variables. 5815 5816 Consider the following example where the :term:`PACKAGE_FEED_URIS`, 5817 :term:`PACKAGE_FEED_BASE_PATHS`, and :term:`PACKAGE_FEED_ARCHS` variables are 5818 defined in your ``local.conf`` file:: 5819 5820 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \ 5821 https://example.com/packagerepos/updates" 5822 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev" 5823 PACKAGE_FEED_ARCHS = "all core2-64" 5824 5825 Given these settings, the resulting package feeds are as follows: 5826 5827 .. code-block:: none 5828 5829 https://example.com/packagerepos/release/rpm/all 5830 https://example.com/packagerepos/release/rpm/core2-64 5831 https://example.com/packagerepos/release/rpm-dev/all 5832 https://example.com/packagerepos/release/rpm-dev/core2-64 5833 https://example.com/packagerepos/updates/rpm/all 5834 https://example.com/packagerepos/updates/rpm/core2-64 5835 https://example.com/packagerepos/updates/rpm-dev/all 5836 https://example.com/packagerepos/updates/rpm-dev/core2-64 5837 5838 :term:`PACKAGE_FEED_URIS` 5839 Specifies the front portion of the package feed URI used by the 5840 OpenEmbedded build system. Each final package feed URI is comprised 5841 of :term:`PACKAGE_FEED_URIS`, 5842 :term:`PACKAGE_FEED_BASE_PATHS`, and 5843 :term:`PACKAGE_FEED_ARCHS` variables. 5844 5845 Consider the following example where the :term:`PACKAGE_FEED_URIS`, 5846 :term:`PACKAGE_FEED_BASE_PATHS`, and :term:`PACKAGE_FEED_ARCHS` variables are 5847 defined in your ``local.conf`` file:: 5848 5849 PACKAGE_FEED_URIS = "https://example.com/packagerepos/release \ 5850 https://example.com/packagerepos/updates" 5851 PACKAGE_FEED_BASE_PATHS = "rpm rpm-dev" 5852 PACKAGE_FEED_ARCHS = "all core2-64" 5853 5854 Given these settings, the resulting package feeds are as follows: 5855 5856 .. code-block:: none 5857 5858 https://example.com/packagerepos/release/rpm/all 5859 https://example.com/packagerepos/release/rpm/core2-64 5860 https://example.com/packagerepos/release/rpm-dev/all 5861 https://example.com/packagerepos/release/rpm-dev/core2-64 5862 https://example.com/packagerepos/updates/rpm/all 5863 https://example.com/packagerepos/updates/rpm/core2-64 5864 https://example.com/packagerepos/updates/rpm-dev/all 5865 https://example.com/packagerepos/updates/rpm-dev/core2-64 5866 5867 :term:`PACKAGE_INSTALL` 5868 The final list of packages passed to the package manager for 5869 installation into the image. 5870 5871 Because the package manager controls actual installation of all 5872 packages, the list of packages passed using :term:`PACKAGE_INSTALL` is 5873 not the final list of packages that are actually installed. This 5874 variable is internal to the image construction code. Consequently, in 5875 general, you should use the 5876 :term:`IMAGE_INSTALL` variable to specify 5877 packages for installation. The exception to this is when working with 5878 the :ref:`core-image-minimal-initramfs <ref-manual/images:images>` 5879 image. When working with an initial RAM filesystem (:term:`Initramfs`) image, 5880 use the :term:`PACKAGE_INSTALL` variable. For information on creating an 5881 :term:`Initramfs`, see the ":ref:`dev-manual/building:building an initial ram filesystem (Initramfs) image`" section 5882 in the Yocto Project Development Tasks Manual. 5883 5884 :term:`PACKAGE_INSTALL_ATTEMPTONLY` 5885 Specifies a list of packages the OpenEmbedded build system attempts 5886 to install when creating an image. If a listed package fails to 5887 install, the build system does not generate an error. This variable 5888 is generally not user-defined. 5889 5890 :term:`PACKAGE_PREPROCESS_FUNCS` 5891 Specifies a list of functions run to pre-process the 5892 :term:`PKGD` directory prior to splitting the files out 5893 to individual packages. 5894 5895 :term:`PACKAGE_WRITE_DEPS` 5896 Specifies a list of dependencies for post-installation and 5897 pre-installation scripts on native/cross tools. If your 5898 post-installation or pre-installation script can execute at root filesystem 5899 creation time rather than on the target but depends on a native tool 5900 in order to execute, you need to list the tools in 5901 :term:`PACKAGE_WRITE_DEPS`. 5902 5903 For information on running post-installation scripts, see the 5904 ":ref:`dev-manual/new-recipe:post-installation scripts`" 5905 section in the Yocto Project Development Tasks Manual. 5906 5907 :term:`PACKAGECONFIG` 5908 This variable provides a means of enabling or disabling features of a 5909 recipe on a per-recipe basis. :term:`PACKAGECONFIG` blocks are defined in 5910 recipes when you specify features and then arguments that define 5911 feature behaviors. Here is the basic block structure (broken over 5912 multiple lines for readability):: 5913 5914 PACKAGECONFIG ??= "f1 f2 f3 ..." 5915 PACKAGECONFIG[f1] = "\ 5916 --with-f1, \ 5917 --without-f1, \ 5918 build-deps-for-f1, \ 5919 runtime-deps-for-f1, \ 5920 runtime-recommends-for-f1, \ 5921 packageconfig-conflicts-for-f1" 5922 PACKAGECONFIG[f2] = "\ 5923 ... and so on and so on ... 5924 5925 The :term:`PACKAGECONFIG` variable itself specifies a space-separated 5926 list of the features to enable. Following the features, you can 5927 determine the behavior of each feature by providing up to six 5928 order-dependent arguments, which are separated by commas. You can 5929 omit any argument you like but must retain the separating commas. The 5930 order is important and specifies the following: 5931 5932 #. Extra arguments that should be added to the configure script 5933 argument list (:term:`EXTRA_OECONF` or 5934 :term:`PACKAGECONFIG_CONFARGS`) if 5935 the feature is enabled. 5936 5937 #. Extra arguments that should be added to :term:`EXTRA_OECONF` or 5938 :term:`PACKAGECONFIG_CONFARGS` if the feature is disabled. 5939 5940 #. Additional build dependencies (:term:`DEPENDS`) 5941 that should be added if the feature is enabled. 5942 5943 #. Additional runtime dependencies (:term:`RDEPENDS`) 5944 that should be added if the feature is enabled. 5945 5946 #. Additional runtime recommendations 5947 (:term:`RRECOMMENDS`) that should be added if 5948 the feature is enabled. 5949 5950 #. Any conflicting (that is, mutually exclusive) :term:`PACKAGECONFIG` 5951 settings for this feature. 5952 5953 Consider the following :term:`PACKAGECONFIG` block taken from the 5954 ``librsvg`` recipe. In this example the feature is ``gtk``, which has 5955 three arguments that determine the feature's behavior:: 5956 5957 PACKAGECONFIG[gtk] = "--with-gtk3,--without-gtk3,gtk+3" 5958 5959 The 5960 ``--with-gtk3`` and ``gtk+3`` arguments apply only if the feature is 5961 enabled. In this case, ``--with-gtk3`` is added to the configure 5962 script argument list and ``gtk+3`` is added to :term:`DEPENDS`. On the 5963 other hand, if the feature is disabled say through a ``.bbappend`` 5964 file in another layer, then the second argument ``--without-gtk3`` is 5965 added to the configure script instead. 5966 5967 The basic :term:`PACKAGECONFIG` structure previously described holds true 5968 regardless of whether you are creating a block or changing a block. 5969 When creating a block, use the structure inside your recipe. 5970 5971 If you want to change an existing :term:`PACKAGECONFIG` block, you can do 5972 so one of two ways: 5973 5974 - *Append file:* Create an append file named 5975 ``recipename.bbappend`` in your layer and override the value of 5976 :term:`PACKAGECONFIG`. You can either completely override the 5977 variable:: 5978 5979 PACKAGECONFIG = "f4 f5" 5980 5981 Or, you can just append the variable:: 5982 5983 PACKAGECONFIG:append = " f4" 5984 5985 - *Configuration file:* This method is identical to changing the 5986 block through an append file except you edit your ``local.conf`` 5987 or ``mydistro.conf`` file. As with append files previously 5988 described, you can either completely override the variable:: 5989 5990 PACKAGECONFIG:pn-recipename = "f4 f5" 5991 5992 Or, you can just amend the variable:: 5993 5994 PACKAGECONFIG:append:pn-recipename = " f4" 5995 5996 :term:`PACKAGECONFIG_CONFARGS` 5997 A space-separated list of configuration options generated from the 5998 :term:`PACKAGECONFIG` setting. 5999 6000 Classes such as :ref:`ref-classes-autotools` and :ref:`ref-classes-cmake` 6001 use :term:`PACKAGECONFIG_CONFARGS` to pass :term:`PACKAGECONFIG` options 6002 to ``configure`` and ``cmake``, respectively. If you are using 6003 :term:`PACKAGECONFIG` but not a class that handles the 6004 :ref:`ref-tasks-configure` task, then you need to use 6005 :term:`PACKAGECONFIG_CONFARGS` appropriately. 6006 6007 :term:`PACKAGEGROUP_DISABLE_COMPLEMENTARY` 6008 For recipes inheriting the :ref:`ref-classes-packagegroup` class, setting 6009 :term:`PACKAGEGROUP_DISABLE_COMPLEMENTARY` to "1" specifies that the 6010 normal complementary packages (i.e. ``-dev``, ``-dbg``, and so forth) 6011 should not be automatically created by the ``packagegroup`` recipe, 6012 which is the default behavior. 6013 6014 :term:`PACKAGES` 6015 The list of packages the recipe creates. The default value is the 6016 following:: 6017 6018 ${PN}-src ${PN}-dbg ${PN}-staticdev ${PN}-dev ${PN}-doc ${PN}-locale ${PACKAGE_BEFORE_PN} ${PN} 6019 6020 During packaging, the :ref:`ref-tasks-package` task 6021 goes through :term:`PACKAGES` and uses the :term:`FILES` 6022 variable corresponding to each package to assign files to the 6023 package. If a file matches the :term:`FILES` variable for more than one 6024 package in :term:`PACKAGES`, it will be assigned to the earliest 6025 (leftmost) package. 6026 6027 Packages in the variable's list that are empty (i.e. where none of 6028 the patterns in ``FILES:``\ pkg match any files installed by the 6029 :ref:`ref-tasks-install` task) are not generated, 6030 unless generation is forced through the 6031 :term:`ALLOW_EMPTY` variable. 6032 6033 :term:`PACKAGES_DYNAMIC` 6034 A promise that your recipe satisfies runtime dependencies for 6035 optional modules that are found in other recipes. 6036 :term:`PACKAGES_DYNAMIC` does not actually satisfy the dependencies, it 6037 only states that they should be satisfied. For example, if a hard, 6038 runtime dependency (:term:`RDEPENDS`) of another 6039 package is satisfied at build time through the :term:`PACKAGES_DYNAMIC` 6040 variable, but a package with the module name is never actually 6041 produced, then the other package will be broken. Thus, if you attempt 6042 to include that package in an image, you will get a dependency 6043 failure from the packaging system during the 6044 :ref:`ref-tasks-rootfs` task. 6045 6046 Typically, if there is a chance that such a situation can occur and 6047 the package that is not created is valid without the dependency being 6048 satisfied, then you should use :term:`RRECOMMENDS` 6049 (a soft runtime dependency) instead of :term:`RDEPENDS`. 6050 6051 For an example of how to use the :term:`PACKAGES_DYNAMIC` variable when 6052 you are splitting packages, see the 6053 ":ref:`dev-manual/packages:handling optional module packaging`" 6054 section in the Yocto Project Development Tasks Manual. 6055 6056 :term:`PACKAGESPLITFUNCS` 6057 Specifies a list of functions run to perform additional splitting of 6058 files into individual packages. Recipes can either prepend to this 6059 variable or prepend to the ``populate_packages`` function in order to 6060 perform additional package splitting. In either case, the function 6061 should set :term:`PACKAGES`, 6062 :term:`FILES`, :term:`RDEPENDS` and 6063 other packaging variables appropriately in order to perform the 6064 desired splitting. 6065 6066 :term:`PARALLEL_MAKE` 6067 6068 Extra options passed to the build tool command (``make``, 6069 ``ninja`` or more specific build engines, like the Go language one) 6070 during the :ref:`ref-tasks-compile` task, to specify parallel compilation 6071 on the local build host. This variable is usually in the form "-j x", 6072 where x represents the maximum number of parallel threads such engines 6073 can run. 6074 6075 .. note:: 6076 6077 For software compiled by ``make``, in order for :term:`PARALLEL_MAKE` 6078 to be effective, ``make`` must be called with 6079 ``${``\ :term:`EXTRA_OEMAKE`\ ``}``. An easy 6080 way to ensure this is to use the ``oe_runmake`` function. 6081 6082 By default, the OpenEmbedded build system automatically sets this 6083 variable to be equal to the number of cores the build system uses. 6084 6085 .. note:: 6086 6087 If the software being built experiences dependency issues during 6088 the :ref:`ref-tasks-compile` task that result in race conditions, you can clear 6089 the :term:`PARALLEL_MAKE` variable within the recipe as a workaround. For 6090 information on addressing race conditions, see the 6091 ":ref:`dev-manual/debugging:debugging parallel make races`" 6092 section in the Yocto Project Development Tasks Manual. 6093 6094 For single socket systems (i.e. one CPU), you should not have to 6095 override this variable to gain optimal parallelism during builds. 6096 However, if you have very large systems that employ multiple physical 6097 CPUs, you might want to make sure the :term:`PARALLEL_MAKE` variable is 6098 not set higher than "-j 20". 6099 6100 For more information on speeding up builds, see the 6101 ":ref:`dev-manual/speeding-up-build:speeding up a build`" 6102 section in the Yocto Project Development Tasks Manual. 6103 6104 :term:`PARALLEL_MAKEINST` 6105 Extra options passed to the build tool install command 6106 (``make install``, ``ninja install`` or more specific ones) 6107 during the :ref:`ref-tasks-install` task in order to specify 6108 parallel installation. This variable defaults to the value of 6109 :term:`PARALLEL_MAKE`. 6110 6111 .. note:: 6112 6113 For software compiled by ``make``, in order for :term:`PARALLEL_MAKEINST` 6114 to be effective, ``make`` must be called with 6115 ``${``\ :term:`EXTRA_OEMAKE`\ ``}``. An easy 6116 way to ensure this is to use the ``oe_runmake`` function. 6117 6118 If the software being built experiences dependency issues during 6119 the :ref:`ref-tasks-install` task that result in race conditions, you can 6120 clear the :term:`PARALLEL_MAKEINST` variable within the recipe as a 6121 workaround. For information on addressing race conditions, see the 6122 ":ref:`dev-manual/debugging:debugging parallel make races`" 6123 section in the Yocto Project Development Tasks Manual. 6124 6125 :term:`PATCHRESOLVE` 6126 Determines the action to take when a patch fails. You can set this 6127 variable to one of two values: "noop" and "user". 6128 6129 The default value of "noop" causes the build to simply fail when the 6130 OpenEmbedded build system cannot successfully apply a patch. Setting 6131 the value to "user" causes the build system to launch a shell and 6132 places you in the right location so that you can manually resolve the 6133 conflicts. 6134 6135 Set this variable in your ``local.conf`` file. 6136 6137 :term:`PATCHTOOL` 6138 Specifies the utility used to apply patches for a recipe during the 6139 :ref:`ref-tasks-patch` task. You can specify one of 6140 three utilities: "patch", "quilt", or "git". The default utility used 6141 is "quilt" except for the quilt-native recipe itself. Because the 6142 quilt tool is not available at the time quilt-native is being 6143 patched, it uses "patch". 6144 6145 If you wish to use an alternative patching tool, set the variable in 6146 the recipe using one of the following:: 6147 6148 PATCHTOOL = "patch" 6149 PATCHTOOL = "quilt" 6150 PATCHTOOL = "git" 6151 6152 :term:`PE` 6153 The epoch of the recipe. By default, this variable is unset. The 6154 variable is used to make upgrades possible when the versioning scheme 6155 changes in some backwards incompatible way. 6156 6157 :term:`PE` is the default value of the :term:`PKGE` variable. 6158 6159 :term:`PEP517_WHEEL_PATH` 6160 When used by recipes that inherit the :ref:`ref-classes-python_pep517` 6161 class, denotes the path to ``dist/`` (short for distribution) where the 6162 binary archive ``wheel`` is built. 6163 6164 :term:`PERSISTENT_DIR` 6165 See :term:`bitbake:PERSISTENT_DIR` in the BitBake manual. 6166 6167 :term:`PF` 6168 Specifies the recipe or package name and includes all version and 6169 revision numbers (i.e. ``glibc-2.13-r20+svnr15508/`` and 6170 ``bash-4.2-r1/``). This variable is comprised of the following: 6171 ${:term:`PN`}-${:term:`EXTENDPE`}${:term:`PV`}-${:term:`PR`} 6172 6173 :term:`PIXBUF_PACKAGES` 6174 When inheriting the :ref:`ref-classes-pixbufcache` 6175 class, this variable identifies packages that contain the pixbuf 6176 loaders used with ``gdk-pixbuf``. By default, the 6177 :ref:`ref-classes-pixbufcache` class assumes that 6178 the loaders are in the recipe's main package (i.e. 6179 ``${``\ :term:`PN`\ ``}``). Use this variable if the 6180 loaders you need are in a package other than that main package. 6181 6182 :term:`PKG` 6183 The name of the resulting package created by the OpenEmbedded build 6184 system. 6185 6186 .. note:: 6187 6188 When using the :term:`PKG` variable, you must use a package name override. 6189 6190 For example, when the :ref:`ref-classes-debian` class renames the output 6191 package, it does so by setting ``PKG:packagename``. 6192 6193 :term:`PKG_CONFIG_PATH` 6194 The path to ``pkg-config`` files for the current build context. 6195 ``pkg-config`` reads this variable from the environment. 6196 6197 :term:`PKGD` 6198 Points to the destination directory for files to be packaged before 6199 they are split into individual packages. This directory defaults to 6200 the following:: 6201 6202 ${WORKDIR}/package 6203 6204 Do not change this default. 6205 6206 :term:`PKGDATA_DIR` 6207 Points to a shared, global-state directory that holds data generated 6208 during the packaging process. During the packaging process, the 6209 :ref:`ref-tasks-packagedata` task packages data 6210 for each recipe and installs it into this temporary, shared area. 6211 This directory defaults to the following, which you should not 6212 change:: 6213 6214 ${STAGING_DIR_HOST}/pkgdata 6215 6216 For examples of how this data is used, see the 6217 ":ref:`overview-manual/concepts:automatically added runtime dependencies`" 6218 section in the Yocto Project Overview and Concepts Manual and the 6219 ":ref:`dev-manual/debugging:viewing package information with \`\`oe-pkgdata-util\`\``" 6220 section in the Yocto Project Development Tasks Manual. For more 6221 information on the shared, global-state directory, see 6222 :term:`STAGING_DIR_HOST`. 6223 6224 :term:`PKGDEST` 6225 Points to the parent directory for files to be packaged after they 6226 have been split into individual packages. This directory defaults to 6227 the following:: 6228 6229 ${WORKDIR}/packages-split 6230 6231 Under this directory, the build system creates directories for each 6232 package specified in :term:`PACKAGES`. Do not change 6233 this default. 6234 6235 :term:`PKGDESTWORK` 6236 Points to a temporary work area where the 6237 :ref:`ref-tasks-package` task saves package metadata. 6238 The :term:`PKGDESTWORK` location defaults to the following:: 6239 6240 ${WORKDIR}/pkgdata 6241 6242 Do not change this default. 6243 6244 The :ref:`ref-tasks-packagedata` task copies the 6245 package metadata from :term:`PKGDESTWORK` to 6246 :term:`PKGDATA_DIR` to make it available globally. 6247 6248 :term:`PKGE` 6249 The epoch of the package(s) built by the recipe. By default, :term:`PKGE` 6250 is set to :term:`PE`. 6251 6252 :term:`PKGR` 6253 The revision of the package(s) built by the recipe. By default, 6254 :term:`PKGR` is set to :term:`PR`. 6255 6256 :term:`PKGV` 6257 The version of the package(s) built by the recipe. By default, 6258 :term:`PKGV` is set to :term:`PV`. 6259 6260 :term:`PN` 6261 This variable can have two separate functions depending on the 6262 context: a recipe name or a resulting package name. 6263 6264 :term:`PN` refers to a recipe name in the context of a file used by the 6265 OpenEmbedded build system as input to create a package. The name is 6266 normally extracted from the recipe file name. For example, if the 6267 recipe is named ``expat_2.0.1.bb``, then the default value of :term:`PN` 6268 will be "expat". 6269 6270 The variable refers to a package name in the context of a file 6271 created or produced by the OpenEmbedded build system. 6272 6273 If applicable, the :term:`PN` variable also contains any special suffix 6274 or prefix. For example, using ``bash`` to build packages for the 6275 native machine, :term:`PN` is ``bash-native``. Using ``bash`` to build 6276 packages for the target and for Multilib, :term:`PN` would be ``bash`` 6277 and ``lib64-bash``, respectively. 6278 6279 :term:`POPULATE_SDK_POST_HOST_COMMAND` 6280 Specifies a list of functions to call once the OpenEmbedded build 6281 system has created the host part of the SDK. You can specify 6282 functions separated by semicolons:: 6283 6284 POPULATE_SDK_POST_HOST_COMMAND += "function; ... " 6285 6286 If you need to pass the SDK path to a command within a function, you 6287 can use ``${SDK_DIR}``, which points to the parent directory used by 6288 the OpenEmbedded build system when creating SDK output. See the 6289 :term:`SDK_DIR` variable for more information. 6290 6291 :term:`POPULATE_SDK_POST_TARGET_COMMAND` 6292 Specifies a list of functions to call once the OpenEmbedded build 6293 system has created the target part of the SDK. You can specify 6294 functions separated by semicolons:: 6295 6296 POPULATE_SDK_POST_TARGET_COMMAND += "function; ... " 6297 6298 If you need to pass the SDK path to a command within a function, you 6299 can use ``${SDK_DIR}``, which points to the parent directory used by 6300 the OpenEmbedded build system when creating SDK output. See the 6301 :term:`SDK_DIR` variable for more information. 6302 6303 :term:`PR` 6304 The revision of the recipe. The default value for this variable is 6305 "r0". Subsequent revisions of the recipe conventionally have the 6306 values "r1", "r2", and so forth. When :term:`PV` increases, 6307 :term:`PR` is conventionally reset to "r0". 6308 6309 .. note:: 6310 6311 The OpenEmbedded build system does not need the aid of :term:`PR` 6312 to know when to rebuild a recipe. The build system uses the task 6313 :ref:`input checksums <overview-manual/concepts:checksums (signatures)>` along with the 6314 :ref:`stamp <structure-build-tmp-stamps>` and 6315 :ref:`overview-manual/concepts:shared state cache` 6316 mechanisms. 6317 6318 The :term:`PR` variable primarily becomes significant when a package 6319 manager dynamically installs packages on an already built image. In 6320 this case, :term:`PR`, which is the default value of 6321 :term:`PKGR`, helps the package manager distinguish which 6322 package is the most recent one in cases where many packages have the 6323 same :term:`PV` (i.e. :term:`PKGV`). A component having many packages with 6324 the same :term:`PV` usually means that the packages all install the same 6325 upstream version, but with later (:term:`PR`) version packages including 6326 packaging fixes. 6327 6328 .. note:: 6329 6330 :term:`PR` does not need to be increased for changes that do not change the 6331 package contents or metadata. 6332 6333 Because manually managing :term:`PR` can be cumbersome and error-prone, 6334 an automated solution exists. See the 6335 ":ref:`dev-manual/packages:working with a pr service`" section 6336 in the Yocto Project Development Tasks Manual for more information. 6337 6338 :term:`PREFERRED_PROVIDER` 6339 If multiple recipes provide the same item, this variable determines 6340 which recipe is preferred and thus provides the item (i.e. the 6341 preferred provider). You should always suffix this variable with the 6342 name of the provided item. And, you should define the variable using 6343 the preferred recipe's name (:term:`PN`). Here is a common 6344 example:: 6345 6346 PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto" 6347 6348 In the previous example, multiple recipes are providing "virtual/kernel". 6349 The :term:`PREFERRED_PROVIDER` variable is set with the name (:term:`PN`) of 6350 the recipe you prefer to provide "virtual/kernel". 6351 6352 Following are more examples:: 6353 6354 PREFERRED_PROVIDER_virtual/xserver = "xserver-xf86" 6355 PREFERRED_PROVIDER_virtual/libgl ?= "mesa" 6356 6357 For more 6358 information, see the ":ref:`dev-manual/new-recipe:using virtual providers`" 6359 section in the Yocto Project Development Tasks Manual. 6360 6361 .. note:: 6362 6363 If you use a ``virtual/\*`` item with :term:`PREFERRED_PROVIDER`, then any 6364 recipe that :term:`PROVIDES` that item but is not selected (defined) 6365 by :term:`PREFERRED_PROVIDER` is prevented from building, which is usually 6366 desirable since this mechanism is designed to select between mutually 6367 exclusive alternative providers. 6368 6369 :term:`PREFERRED_PROVIDERS` 6370 See :term:`bitbake:PREFERRED_PROVIDERS` in the BitBake manual. 6371 6372 :term:`PREFERRED_VERSION` 6373 If there are multiple versions of a recipe available, this variable 6374 determines which version should be given preference. You must always 6375 suffix the variable with the :term:`PN` you want to select (`python` in 6376 the first example below), and you should specify the :term:`PV` 6377 accordingly (`3.4.0` in the example). 6378 6379 The :term:`PREFERRED_VERSION` variable supports limited wildcard use 6380 through the "``%``" character. You can use the character to match any 6381 number of characters, which can be useful when specifying versions 6382 that contain long revision numbers that potentially change. Here are 6383 two examples:: 6384 6385 PREFERRED_VERSION_python = "3.4.0" 6386 PREFERRED_VERSION_linux-yocto = "5.0%" 6387 6388 .. note:: 6389 6390 The use of the "%" character is limited in that it only works at the end of the 6391 string. You cannot use the wildcard character in any other 6392 location of the string. 6393 6394 The specified version is matched against :term:`PV`, which 6395 does not necessarily match the version part of the recipe's filename. 6396 For example, consider two recipes ``foo_1.2.bb`` and ``foo_git.bb`` 6397 where ``foo_git.bb`` contains the following assignment:: 6398 6399 PV = "1.1+git${SRCPV}" 6400 6401 In this case, the correct way to select 6402 ``foo_git.bb`` is by using an assignment such as the following:: 6403 6404 PREFERRED_VERSION_foo = "1.1+git%" 6405 6406 Compare that previous example 6407 against the following incorrect example, which does not work:: 6408 6409 PREFERRED_VERSION_foo = "git" 6410 6411 Sometimes the :term:`PREFERRED_VERSION` variable can be set by 6412 configuration files in a way that is hard to change. You can use 6413 :term:`OVERRIDES` to set a machine-specific 6414 override. Here is an example:: 6415 6416 PREFERRED_VERSION_linux-yocto:qemux86 = "5.0%" 6417 6418 Although not recommended, worst case, you can also use the 6419 "forcevariable" override, which is the strongest override possible. 6420 Here is an example:: 6421 6422 PREFERRED_VERSION_linux-yocto:forcevariable = "5.0%" 6423 6424 .. note:: 6425 6426 The ``:forcevariable`` override is not handled specially. This override 6427 only works because the default value of :term:`OVERRIDES` includes "forcevariable". 6428 6429 If a recipe with the specified version is not available, a warning 6430 message will be shown. See :term:`REQUIRED_VERSION` if you want this 6431 to be an error instead. 6432 6433 :term:`PREMIRRORS` 6434 Specifies additional paths from which the OpenEmbedded build system 6435 gets source code. When the build system searches for source code, it 6436 first tries the local download directory. If that location fails, the 6437 build system tries locations defined by :term:`PREMIRRORS`, the upstream 6438 source, and then locations specified by 6439 :term:`MIRRORS` in that order. 6440 6441 Assuming your distribution (:term:`DISTRO`) is "poky", 6442 the default value for :term:`PREMIRRORS` is defined in the 6443 ``conf/distro/poky.conf`` file in the ``meta-poky`` Git repository. 6444 6445 Typically, you could add a specific server for the build system to 6446 attempt before any others by adding something like the following to 6447 the ``local.conf`` configuration file in the 6448 :term:`Build Directory`:: 6449 6450 PREMIRRORS:prepend = "\ 6451 git://.*/.* &YOCTO_DL_URL;/mirror/sources/ \ 6452 ftp://.*/.* &YOCTO_DL_URL;/mirror/sources/ \ 6453 http://.*/.* &YOCTO_DL_URL;/mirror/sources/ \ 6454 https://.*/.* &YOCTO_DL_URL;/mirror/sources/" 6455 6456 These changes cause the 6457 build system to intercept Git, FTP, HTTP, and HTTPS requests and 6458 direct them to the ``http://`` sources mirror. You can use 6459 ``file://`` URLs to point to local directories or network shares as 6460 well. 6461 6462 :term:`PRIORITY` 6463 Indicates the importance of a package. 6464 6465 :term:`PRIORITY` is considered to be part of the distribution policy 6466 because the importance of any given recipe depends on the purpose for 6467 which the distribution is being produced. Thus, :term:`PRIORITY` is not 6468 normally set within recipes. 6469 6470 You can set :term:`PRIORITY` to "required", "standard", "extra", and 6471 "optional", which is the default. 6472 6473 :term:`PRIVATE_LIBS` 6474 Specifies libraries installed within a recipe that should be ignored 6475 by the OpenEmbedded build system's shared library resolver. This 6476 variable is typically used when software being built by a recipe has 6477 its own private versions of a library normally provided by another 6478 recipe. In this case, you would not want the package containing the 6479 private libraries to be set as a dependency on other unrelated 6480 packages that should instead depend on the package providing the 6481 standard version of the library. 6482 6483 Libraries specified in this variable should be specified by their 6484 file name. For example, from the Firefox recipe in meta-browser:: 6485 6486 PRIVATE_LIBS = "libmozjs.so \ 6487 libxpcom.so \ 6488 libnspr4.so \ 6489 libxul.so \ 6490 libmozalloc.so \ 6491 libplc4.so \ 6492 libplds4.so" 6493 6494 For more information, see the 6495 ":ref:`overview-manual/concepts:automatically added runtime dependencies`" 6496 section in the Yocto Project Overview and Concepts Manual. 6497 6498 :term:`PROVIDES` 6499 A list of aliases by which a particular recipe can be known. By 6500 default, a recipe's own :term:`PN` is implicitly already in its 6501 :term:`PROVIDES` list and therefore does not need to mention that it 6502 provides itself. If a recipe uses :term:`PROVIDES`, the additional 6503 aliases are synonyms for the recipe and can be useful for satisfying 6504 dependencies of other recipes during the build as specified by 6505 :term:`DEPENDS`. 6506 6507 Consider the following example :term:`PROVIDES` statement from the recipe 6508 file ``eudev_3.2.9.bb``:: 6509 6510 PROVIDES += "udev" 6511 6512 The :term:`PROVIDES` statement 6513 results in the "eudev" recipe also being available as simply "udev". 6514 6515 .. note:: 6516 6517 A recipe's own recipe name (:term:`PN`) is always implicitly prepended 6518 to :term:`PROVIDES`, so while using "+=" in the above example may not be 6519 strictly necessary it is recommended to avoid confusion. 6520 6521 In addition to providing recipes under alternate names, the 6522 :term:`PROVIDES` mechanism is also used to implement virtual targets. A 6523 virtual target is a name that corresponds to some particular 6524 functionality (e.g. a Linux kernel). Recipes that provide the 6525 functionality in question list the virtual target in :term:`PROVIDES`. 6526 Recipes that depend on the functionality in question can include the 6527 virtual target in :term:`DEPENDS` to leave the choice of provider open. 6528 6529 Conventionally, virtual targets have names on the form 6530 "virtual/function" (e.g. "virtual/kernel"). The slash is simply part 6531 of the name and has no syntactical significance. 6532 6533 The :term:`PREFERRED_PROVIDER` variable is 6534 used to select which particular recipe provides a virtual target. 6535 6536 .. note:: 6537 6538 A corresponding mechanism for virtual runtime dependencies 6539 (packages) exists. However, the mechanism does not depend on any 6540 special functionality beyond ordinary variable assignments. For 6541 example, ``VIRTUAL-RUNTIME_dev_manager`` refers to the package of 6542 the component that manages the ``/dev`` directory. 6543 6544 Setting the "preferred provider" for runtime dependencies is as 6545 simple as using the following assignment in a configuration file:: 6546 6547 VIRTUAL-RUNTIME_dev_manager = "udev" 6548 6549 6550 :term:`PRSERV_HOST` 6551 The network based :term:`PR` service host and port. 6552 6553 The ``conf/templates/default/local.conf.sample.extended`` configuration 6554 file in the :term:`Source Directory` shows how the :term:`PRSERV_HOST` 6555 variable is set:: 6556 6557 PRSERV_HOST = "localhost:0" 6558 6559 You must 6560 set the variable if you want to automatically start a local :ref:`PR 6561 service <dev-manual/packages:working with a pr service>`. You can 6562 set :term:`PRSERV_HOST` to other values to use a remote PR service. 6563 6564 6565 :term:`PSEUDO_IGNORE_PATHS` 6566 A comma-separated (without spaces) list of path prefixes that should be ignored 6567 by pseudo when monitoring and recording file operations, in order to avoid 6568 problems with files being written to outside of the pseudo context and 6569 reduce pseudo's overhead. A path is ignored if it matches any prefix in the list 6570 and can include partial directory (or file) names. 6571 6572 6573 :term:`PTEST_ENABLED` 6574 Specifies whether or not :ref:`Package 6575 Test <dev-manual/packages:testing packages with ptest>` (ptest) 6576 functionality is enabled when building a recipe. You should not set 6577 this variable directly. Enabling and disabling building Package Tests 6578 at build time should be done by adding "ptest" to (or removing it 6579 from) :term:`DISTRO_FEATURES`. 6580 6581 :term:`PV` 6582 The version of the recipe. The version is normally extracted from the 6583 recipe filename. For example, if the recipe is named 6584 ``expat_2.0.1.bb``, then the default value of :term:`PV` will be "2.0.1". 6585 :term:`PV` is generally not overridden within a recipe unless it is 6586 building an unstable (i.e. development) version from a source code 6587 repository (e.g. Git or Subversion). 6588 6589 :term:`PV` is the default value of the :term:`PKGV` variable. 6590 6591 :term:`PYPI_PACKAGE` 6592 When inheriting the :ref:`ref-classes-pypi` class, specifies the 6593 `PyPI <https://pypi.org/>`__ package name to be built. The default value 6594 is set based upon :term:`BPN` (stripping any "python-" or "python3-" 6595 prefix off if present), however for some packages it will need to be set 6596 explicitly if that will not match the package name (e.g. where the 6597 package name has a prefix, underscores, uppercase letters etc.) 6598 6599 :term:`PYTHON_ABI` 6600 When used by recipes that inherit the :ref:`ref-classes-setuptools3` 6601 class, denotes the Application Binary Interface (ABI) currently in use 6602 for Python. By default, the ABI is "m". You do not have to set this 6603 variable as the OpenEmbedded build system sets it for you. 6604 6605 The OpenEmbedded build system uses the ABI to construct directory 6606 names used when installing the Python headers and libraries in 6607 sysroot (e.g. ``.../python3.3m/...``). 6608 6609 :term:`PYTHON_PN` 6610 When used by recipes that inherit the :ref:`ref-classes-setuptools3` 6611 class, specifies the major Python version being built. For Python 3.x, 6612 :term:`PYTHON_PN` would be "python3". You do not have to set this 6613 variable as the OpenEmbedded build system automatically sets it for you. 6614 6615 The variable allows recipes to use common infrastructure such as the 6616 following:: 6617 6618 DEPENDS += "${PYTHON_PN}-native" 6619 6620 In the previous example, 6621 the version of the dependency is :term:`PYTHON_PN`. 6622 6623 :term:`QA_EMPTY_DIRS` 6624 Specifies a list of directories that are expected to be empty when 6625 packaging; if ``empty-dirs`` appears in :term:`ERROR_QA` or 6626 :term:`WARN_QA` these will be checked and an error or warning 6627 (respectively) will be produced. 6628 6629 The default :term:`QA_EMPTY_DIRS` value is set in 6630 :ref:`insane.bbclass <ref-classes-insane>`. 6631 6632 :term:`QA_EMPTY_DIRS_RECOMMENDATION` 6633 Specifies a recommendation for why a directory must be empty, 6634 which will be included in the error message if a specific directory 6635 is found to contain files. Must be overridden with the directory 6636 path to match on. 6637 6638 If no recommendation is specified for a directory, then the default 6639 "but it is expected to be empty" will be used. 6640 6641 An example message shows if files were present in '/dev':: 6642 6643 QA_EMPTY_DIRS_RECOMMENDATION:/dev = "but all devices must be created at runtime" 6644 6645 :term:`RANLIB` 6646 The minimal command and arguments to run ``ranlib``. 6647 6648 :term:`RCONFLICTS` 6649 The list of packages that conflict with packages. Note that packages 6650 will not be installed if conflicting packages are not first removed. 6651 6652 Like all package-controlling variables, you must always use them in 6653 conjunction with a package name override. Here is an example:: 6654 6655 RCONFLICTS:${PN} = "another_conflicting_package_name" 6656 6657 BitBake, which the OpenEmbedded build system uses, supports 6658 specifying versioned dependencies. Although the syntax varies 6659 depending on the packaging format, BitBake hides these differences 6660 from you. Here is the general syntax to specify versions with the 6661 :term:`RCONFLICTS` variable:: 6662 6663 RCONFLICTS:${PN} = "package (operator version)" 6664 6665 For ``operator``, you can specify the following: 6666 6667 - = 6668 - < 6669 - > 6670 - <= 6671 - >= 6672 6673 For example, the following sets up a dependency on version 1.2 or 6674 greater of the package ``foo``:: 6675 6676 RCONFLICTS:${PN} = "foo (>= 1.2)" 6677 6678 :term:`RDEPENDS` 6679 Lists runtime dependencies of a package. These dependencies are other 6680 packages that must be installed in order for the package to function 6681 correctly. As an example, the following assignment declares that the 6682 package ``foo`` needs the packages ``bar`` and ``baz`` to be 6683 installed:: 6684 6685 RDEPENDS:foo = "bar baz" 6686 6687 The most common types of package 6688 runtime dependencies are automatically detected and added. Therefore, 6689 most recipes do not need to set :term:`RDEPENDS`. For more information, 6690 see the 6691 ":ref:`overview-manual/concepts:automatically added runtime dependencies`" 6692 section in the Yocto Project Overview and Concepts Manual. 6693 6694 The practical effect of the above :term:`RDEPENDS` assignment is that 6695 ``bar`` and ``baz`` will be declared as dependencies inside the 6696 package ``foo`` when it is written out by one of the 6697 :ref:`do_package_write_* <ref-tasks-package_write_deb>` tasks. 6698 Exactly how this is done depends on which package format is used, 6699 which is determined by 6700 :term:`PACKAGE_CLASSES`. When the 6701 corresponding package manager installs the package, it will know to 6702 also install the packages on which it depends. 6703 6704 To ensure that the packages ``bar`` and ``baz`` get built, the 6705 previous :term:`RDEPENDS` assignment also causes a task dependency to be 6706 added. This dependency is from the recipe's 6707 :ref:`ref-tasks-build` (not to be confused with 6708 :ref:`ref-tasks-compile`) task to the 6709 :ref:`do_package_write_* <ref-tasks-package_write_deb>` task of the recipes that build ``bar`` and 6710 ``baz``. 6711 6712 The names of the packages you list within :term:`RDEPENDS` must be the 6713 names of other packages --- they cannot be recipe names. Although 6714 package names and recipe names usually match, the important point 6715 here is that you are providing package names within the :term:`RDEPENDS` 6716 variable. For an example of the default list of packages created from 6717 a recipe, see the :term:`PACKAGES` variable. 6718 6719 Because the :term:`RDEPENDS` variable applies to packages being built, 6720 you should always use the variable in a form with an attached package 6721 name (remember that a single recipe can build multiple packages). For 6722 example, suppose you are building a development package that depends 6723 on the ``perl`` package. In this case, you would use the following 6724 :term:`RDEPENDS` statement:: 6725 6726 RDEPENDS:${PN}-dev += "perl" 6727 6728 In the example, 6729 the development package depends on the ``perl`` package. Thus, the 6730 :term:`RDEPENDS` variable has the ``${PN}-dev`` package name as part of 6731 the variable. 6732 6733 .. note:: 6734 6735 ``RDEPENDS:${PN}-dev`` includes ``${``\ :term:`PN`\ ``}`` 6736 by default. This default is set in the BitBake configuration file 6737 (``meta/conf/bitbake.conf``). Be careful not to accidentally remove 6738 ``${PN}`` when modifying ``RDEPENDS:${PN}-dev``. Use the "+=" operator 6739 rather than the "=" operator. 6740 6741 The package names you use with :term:`RDEPENDS` must appear as they would 6742 in the :term:`PACKAGES` variable. The :term:`PKG` variable 6743 allows a different name to be used for the final package (e.g. the 6744 :ref:`ref-classes-debian` class uses this to rename 6745 packages), but this final package name cannot be used with 6746 :term:`RDEPENDS`, which makes sense as :term:`RDEPENDS` is meant to be 6747 independent of the package format used. 6748 6749 BitBake, which the OpenEmbedded build system uses, supports 6750 specifying versioned dependencies. Although the syntax varies 6751 depending on the packaging format, BitBake hides these differences 6752 from you. Here is the general syntax to specify versions with the 6753 :term:`RDEPENDS` variable:: 6754 6755 RDEPENDS:${PN} = "package (operator version)" 6756 6757 For ``operator``, you can specify the following: 6758 6759 - = 6760 - < 6761 - > 6762 - <= 6763 - >= 6764 6765 For version, provide the version number. 6766 6767 .. note:: 6768 6769 You can use :term:`EXTENDPKGV` to provide a full package version 6770 specification. 6771 6772 For example, the following sets up a dependency on version 1.2 or 6773 greater of the package ``foo``:: 6774 6775 RDEPENDS:${PN} = "foo (>= 1.2)" 6776 6777 For information on build-time dependencies, see the :term:`DEPENDS` 6778 variable. You can also see the 6779 ":ref:`bitbake-user-manual/bitbake-user-manual-metadata:tasks`" and 6780 ":ref:`bitbake-user-manual/bitbake-user-manual-execution:dependencies`" sections in the 6781 BitBake User Manual for additional information on tasks and dependencies. 6782 6783 :term:`RECIPE_NO_UPDATE_REASON` 6784 If a recipe should not be replaced by a more recent upstream version, 6785 putting the reason why in this variable in a recipe allows 6786 ``devtool check-upgrade-status`` command to display it, as explained 6787 in the ":ref:`ref-manual/devtool-reference:checking on the upgrade status of a recipe`" 6788 section. 6789 6790 :term:`REPODIR` 6791 See :term:`bitbake:REPODIR` in the BitBake manual. 6792 6793 :term:`REQUIRED_DISTRO_FEATURES` 6794 When inheriting the :ref:`ref-classes-features_check` 6795 class, this variable identifies distribution features that must exist 6796 in the current configuration in order for the OpenEmbedded build 6797 system to build the recipe. In other words, if the 6798 :term:`REQUIRED_DISTRO_FEATURES` variable lists a feature that does not 6799 appear in :term:`DISTRO_FEATURES` within the current configuration, then 6800 the recipe will be skipped, and if the build system attempts to build 6801 the recipe then an error will be triggered. 6802 6803 :term:`REQUIRED_VERSION` 6804 If there are multiple versions of a recipe available, this variable 6805 determines which version should be given preference. 6806 :term:`REQUIRED_VERSION` works in exactly the same manner as 6807 :term:`PREFERRED_VERSION`, except that if the specified version is not 6808 available then an error message is shown and the build fails 6809 immediately. 6810 6811 If both :term:`REQUIRED_VERSION` and :term:`PREFERRED_VERSION` are set 6812 for the same recipe, the :term:`REQUIRED_VERSION` value applies. 6813 6814 :term:`RM_WORK_EXCLUDE` 6815 With :ref:`ref-classes-rm-work` enabled, this variable 6816 specifies a list of recipes whose work directories should not be removed. 6817 See the ":ref:`ref-classes-rm-work`" section for more details. 6818 6819 :term:`ROOT_HOME` 6820 Defines the root home directory. By default, this directory is set as 6821 follows in the BitBake configuration file:: 6822 6823 ROOT_HOME ??= "/home/root" 6824 6825 .. note:: 6826 6827 This default value is likely used because some embedded solutions 6828 prefer to have a read-only root filesystem and prefer to keep 6829 writeable data in one place. 6830 6831 You can override the default by setting the variable in any layer or 6832 in the ``local.conf`` file. Because the default is set using a "weak" 6833 assignment (i.e. "??="), you can use either of the following forms to 6834 define your override:: 6835 6836 ROOT_HOME = "/root" 6837 ROOT_HOME ?= "/root" 6838 6839 These 6840 override examples use ``/root``, which is probably the most commonly 6841 used override. 6842 6843 :term:`ROOTFS` 6844 Indicates a filesystem image to include as the root filesystem. 6845 6846 The :term:`ROOTFS` variable is an optional variable used with the 6847 :ref:`ref-classes-image-live` class. 6848 6849 :term:`ROOTFS_POSTINSTALL_COMMAND` 6850 Specifies a list of functions to call after the OpenEmbedded build 6851 system has installed packages. You can specify functions separated by 6852 semicolons:: 6853 6854 ROOTFS_POSTINSTALL_COMMAND += "function; ... " 6855 6856 If you need to pass the root filesystem path to a command within a 6857 function, you can use ``${IMAGE_ROOTFS}``, which points to the 6858 directory that becomes the root filesystem image. See the 6859 :term:`IMAGE_ROOTFS` variable for more 6860 information. 6861 6862 :term:`ROOTFS_POSTPROCESS_COMMAND` 6863 Specifies a list of functions to call once the OpenEmbedded build 6864 system has created the root filesystem. You can specify functions 6865 separated by semicolons:: 6866 6867 ROOTFS_POSTPROCESS_COMMAND += "function; ... " 6868 6869 If you need to pass the root filesystem path to a command within a 6870 function, you can use ``${IMAGE_ROOTFS}``, which points to the 6871 directory that becomes the root filesystem image. See the 6872 :term:`IMAGE_ROOTFS` variable for more 6873 information. 6874 6875 :term:`ROOTFS_POSTUNINSTALL_COMMAND` 6876 Specifies a list of functions to call after the OpenEmbedded build 6877 system has removed unnecessary packages. When runtime package 6878 management is disabled in the image, several packages are removed 6879 including ``base-passwd``, ``shadow``, and ``update-alternatives``. 6880 You can specify functions separated by semicolons:: 6881 6882 ROOTFS_POSTUNINSTALL_COMMAND += "function; ... " 6883 6884 If you need to pass the root filesystem path to a command within a 6885 function, you can use ``${IMAGE_ROOTFS}``, which points to the 6886 directory that becomes the root filesystem image. See the 6887 :term:`IMAGE_ROOTFS` variable for more 6888 information. 6889 6890 :term:`ROOTFS_PREPROCESS_COMMAND` 6891 Specifies a list of functions to call before the OpenEmbedded build 6892 system has created the root filesystem. You can specify functions 6893 separated by semicolons:: 6894 6895 ROOTFS_PREPROCESS_COMMAND += "function; ... " 6896 6897 If you need to pass the root filesystem path to a command within a 6898 function, you can use ``${IMAGE_ROOTFS}``, which points to the 6899 directory that becomes the root filesystem image. See the 6900 :term:`IMAGE_ROOTFS` variable for more 6901 information. 6902 6903 :term:`RPROVIDES` 6904 A list of package name aliases that a package also provides. These 6905 aliases are useful for satisfying runtime dependencies of other 6906 packages both during the build and on the target (as specified by 6907 :term:`RDEPENDS`). 6908 6909 .. note:: 6910 6911 A package's own name is implicitly already in its :term:`RPROVIDES` list. 6912 6913 As with all package-controlling variables, you must always use the 6914 variable in conjunction with a package name override. Here is an 6915 example:: 6916 6917 RPROVIDES:${PN} = "widget-abi-2" 6918 6919 :term:`RRECOMMENDS` 6920 A list of packages that extends the usability of a package being 6921 built. The package being built does not depend on this list of 6922 packages in order to successfully build, but rather uses them for 6923 extended usability. To specify runtime dependencies for packages, see 6924 the :term:`RDEPENDS` variable. 6925 6926 The package manager will automatically install the :term:`RRECOMMENDS` 6927 list of packages when installing the built package. However, you can 6928 prevent listed packages from being installed by using the 6929 :term:`BAD_RECOMMENDATIONS`, 6930 :term:`NO_RECOMMENDATIONS`, and 6931 :term:`PACKAGE_EXCLUDE` variables. 6932 6933 Packages specified in :term:`RRECOMMENDS` need not actually be produced. 6934 However, there must be a recipe providing each package, either 6935 through the :term:`PACKAGES` or 6936 :term:`PACKAGES_DYNAMIC` variables or the 6937 :term:`RPROVIDES` variable, or an error will occur 6938 during the build. If such a recipe does exist and the package is not 6939 produced, the build continues without error. 6940 6941 Because the :term:`RRECOMMENDS` variable applies to packages being built, 6942 you should always attach an override to the variable to specify the 6943 particular package whose usability is being extended. For example, 6944 suppose you are building a development package that is extended to 6945 support wireless functionality. In this case, you would use the 6946 following:: 6947 6948 RRECOMMENDS:${PN}-dev += "wireless_package_name" 6949 6950 In the 6951 example, the package name (``${PN}-dev``) must appear as it would in 6952 the :term:`PACKAGES` namespace before any renaming of the output package 6953 by classes such as :ref:`ref-classes-debian`. 6954 6955 BitBake, which the OpenEmbedded build system uses, supports 6956 specifying versioned recommends. Although the syntax varies depending 6957 on the packaging format, BitBake hides these differences from you. 6958 Here is the general syntax to specify versions with the 6959 :term:`RRECOMMENDS` variable:: 6960 6961 RRECOMMENDS:${PN} = "package (operator version)" 6962 6963 For ``operator``, you can specify the following: 6964 6965 - = 6966 - < 6967 - > 6968 - <= 6969 - >= 6970 6971 For example, the following sets up a recommend on version 1.2 or 6972 greater of the package ``foo``:: 6973 6974 RRECOMMENDS:${PN} = "foo (>= 1.2)" 6975 6976 :term:`RREPLACES` 6977 A list of packages replaced by a package. The package manager uses 6978 this variable to determine which package should be installed to 6979 replace other package(s) during an upgrade. In order to also have the 6980 other package(s) removed at the same time, you must add the name of 6981 the other package to the :term:`RCONFLICTS` variable. 6982 6983 As with all package-controlling variables, you must use this variable 6984 in conjunction with a package name override. Here is an example:: 6985 6986 RREPLACES:${PN} = "other_package_being_replaced" 6987 6988 BitBake, which the OpenEmbedded build system uses, supports 6989 specifying versioned replacements. Although the syntax varies 6990 depending on the packaging format, BitBake hides these differences 6991 from you. Here is the general syntax to specify versions with the 6992 :term:`RREPLACES` variable:: 6993 6994 RREPLACES:${PN} = "package (operator version)" 6995 6996 For ``operator``, you can specify the following: 6997 6998 - = 6999 - < 7000 - > 7001 - <= 7002 - >= 7003 7004 For example, the following sets up a replacement using version 1.2 7005 or greater of the package ``foo``:: 7006 7007 RREPLACES:${PN} = "foo (>= 1.2)" 7008 7009 :term:`RSUGGESTS` 7010 A list of additional packages that you can suggest for installation 7011 by the package manager at the time a package is installed. Not all 7012 package managers support this functionality. 7013 7014 As with all package-controlling variables, you must always use this 7015 variable in conjunction with a package name override. Here is an 7016 example:: 7017 7018 RSUGGESTS:${PN} = "useful_package another_package" 7019 7020 :term:`RUST_CHANNEL` 7021 Specifies which version of Rust to build - "stable", "beta" or "nightly". 7022 The default value is "stable". Set this at your own risk, as values other 7023 than "stable" are not guaranteed to work at a given time. 7024 7025 :term:`S` 7026 The location in the :term:`Build Directory` where 7027 unpacked recipe source code resides. By default, this directory is 7028 ``${``\ :term:`WORKDIR`\ ``}/${``\ :term:`BPN`\ ``}-${``\ :term:`PV`\ ``}``, 7029 where ``${BPN}`` is the base recipe name and ``${PV}`` is the recipe 7030 version. If the source tarball extracts the code to a directory named 7031 anything other than ``${BPN}-${PV}``, or if the source code is 7032 fetched from an SCM such as Git or Subversion, then you must set 7033 :term:`S` in the recipe so that the OpenEmbedded build system knows where 7034 to find the unpacked source. 7035 7036 As an example, assume a :term:`Source Directory` 7037 top-level folder named ``poky`` and a default :term:`Build Directory` at 7038 ``poky/build``. In this case, the work directory the build system 7039 uses to keep the unpacked recipe for ``db`` is the following:: 7040 7041 poky/build/tmp/work/qemux86-poky-linux/db/5.1.19-r3/db-5.1.19 7042 7043 The unpacked source code resides in the ``db-5.1.19`` folder. 7044 7045 This next example assumes a Git repository. By default, Git 7046 repositories are cloned to ``${WORKDIR}/git`` during 7047 :ref:`ref-tasks-fetch`. Since this path is different 7048 from the default value of :term:`S`, you must set it specifically so the 7049 source can be located:: 7050 7051 SRC_URI = "git://path/to/repo.git;branch=main" 7052 S = "${WORKDIR}/git" 7053 7054 :term:`SANITY_REQUIRED_UTILITIES` 7055 Specifies a list of command-line utilities that should be checked for 7056 during the initial sanity checking process when running BitBake. If 7057 any of the utilities are not installed on the build host, then 7058 BitBake immediately exits with an error. 7059 7060 :term:`SANITY_TESTED_DISTROS` 7061 A list of the host distribution identifiers that the build system has 7062 been tested against. Identifiers consist of the host distributor ID 7063 followed by the release, as reported by the ``lsb_release`` tool or 7064 as read from ``/etc/lsb-release``. Separate the list items with 7065 explicit newline characters (``\n``). If :term:`SANITY_TESTED_DISTROS` is 7066 not empty and the current value of 7067 :term:`NATIVELSBSTRING` does not appear in the 7068 list, then the build system reports a warning that indicates the 7069 current host distribution has not been tested as a build host. 7070 7071 :term:`SDK_ARCH` 7072 The target architecture for the SDK. Typically, you do not directly 7073 set this variable. Instead, use :term:`SDKMACHINE`. 7074 7075 :term:`SDK_ARCHIVE_TYPE` 7076 Specifies the type of archive to create for the SDK. Valid values: 7077 7078 - ``tar.xz`` (default) 7079 - ``zip`` 7080 7081 Only one archive type can be specified. 7082 7083 :term:`SDK_BUILDINFO_FILE` 7084 When using the :ref:`ref-classes-image-buildinfo` class, 7085 specifies the file in the SDK to write the build information into. The 7086 default value is "``/buildinfo``". 7087 7088 :term:`SDK_CUSTOM_TEMPLATECONF` 7089 When building the extensible SDK, if :term:`SDK_CUSTOM_TEMPLATECONF` is set to 7090 "1" and a ``conf/templateconf.cfg`` file exists in the :term:`Build Directory` 7091 (:term:`TOPDIR`) then this will be copied into the SDK. 7092 7093 :term:`SDK_DEPLOY` 7094 The directory set up and used by the 7095 :ref:`populate_sdk_base <ref-classes-populate-sdk>` class to which the 7096 SDK is deployed. The :ref:`populate_sdk_base <ref-classes-populate-sdk>` 7097 class defines :term:`SDK_DEPLOY` as follows:: 7098 7099 SDK_DEPLOY = "${TMPDIR}/deploy/sdk" 7100 7101 :term:`SDK_DIR` 7102 The parent directory used by the OpenEmbedded build system when 7103 creating SDK output. The 7104 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class defines 7105 the variable as follows:: 7106 7107 SDK_DIR = "${WORKDIR}/sdk" 7108 7109 .. note:: 7110 7111 The :term:`SDK_DIR` directory is a temporary directory as it is part of 7112 :term:`WORKDIR`. The final output directory is :term:`SDK_DEPLOY`. 7113 7114 :term:`SDK_EXT_TYPE` 7115 Controls whether or not shared state artifacts are copied into the 7116 extensible SDK. The default value of "full" copies all of the 7117 required shared state artifacts into the extensible SDK. The value 7118 "minimal" leaves these artifacts out of the SDK. 7119 7120 .. note:: 7121 7122 If you set the variable to "minimal", you need to ensure 7123 :term:`SSTATE_MIRRORS` is set in the SDK's configuration to enable the 7124 artifacts to be fetched as needed. 7125 7126 :term:`SDK_HOST_MANIFEST` 7127 The manifest file for the host part of the SDK. This file lists all 7128 the installed packages that make up the host part of the SDK. The 7129 file contains package information on a line-per-package basis as 7130 follows:: 7131 7132 packagename packagearch version 7133 7134 The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class 7135 defines the manifest file as follows:: 7136 7137 SDK_HOST_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.host.manifest" 7138 7139 The location is derived using the :term:`SDK_DEPLOY` and 7140 :term:`TOOLCHAIN_OUTPUTNAME` variables. 7141 7142 :term:`SDK_INCLUDE_PKGDATA` 7143 When set to "1", specifies to include the packagedata for all recipes 7144 in the "world" target in the extensible SDK. Including this data 7145 allows the ``devtool search`` command to find these recipes in search 7146 results, as well as allows the ``devtool add`` command to map 7147 dependencies more effectively. 7148 7149 .. note:: 7150 7151 Enabling the :term:`SDK_INCLUDE_PKGDATA` 7152 variable significantly increases build time because all of world 7153 needs to be built. Enabling the variable also slightly increases 7154 the size of the extensible SDK. 7155 7156 :term:`SDK_INCLUDE_TOOLCHAIN` 7157 When set to "1", specifies to include the toolchain in the extensible 7158 SDK. Including the toolchain is useful particularly when 7159 :term:`SDK_EXT_TYPE` is set to "minimal" to keep 7160 the SDK reasonably small but you still want to provide a usable 7161 toolchain. For example, suppose you want to use the toolchain from an 7162 IDE or from other tools and you do not want to perform additional 7163 steps to install the toolchain. 7164 7165 The :term:`SDK_INCLUDE_TOOLCHAIN` variable defaults to "0" if 7166 :term:`SDK_EXT_TYPE` is set to "minimal", and defaults to "1" if 7167 :term:`SDK_EXT_TYPE` is set to "full". 7168 7169 :term:`SDK_NAME` 7170 The base name for SDK output files. The name is derived from the 7171 :term:`DISTRO`, :term:`TCLIBC`, 7172 :term:`SDK_ARCH`, 7173 :term:`IMAGE_BASENAME`, and 7174 :term:`TUNE_PKGARCH` variables:: 7175 7176 SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}" 7177 7178 :term:`SDK_OS` 7179 Specifies the operating system for which the SDK will be built. The 7180 default value is the value of :term:`BUILD_OS`. 7181 7182 :term:`SDK_OUTPUT` 7183 The location used by the OpenEmbedded build system when creating SDK 7184 output. The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` 7185 class defines the variable as follows:: 7186 7187 SDK_DIR = "${WORKDIR}/sdk" 7188 SDK_OUTPUT = "${SDK_DIR}/image" 7189 SDK_DEPLOY = "${DEPLOY_DIR}/sdk" 7190 7191 .. note:: 7192 7193 The :term:`SDK_OUTPUT` directory is a temporary directory as it is part of 7194 :term:`WORKDIR` by way of :term:`SDK_DIR`. The final output directory is 7195 :term:`SDK_DEPLOY`. 7196 7197 :term:`SDK_PACKAGE_ARCHS` 7198 Specifies a list of architectures compatible with the SDK machine. 7199 This variable is set automatically and should not normally be 7200 hand-edited. Entries are separated using spaces and listed in order 7201 of priority. The default value for :term:`SDK_PACKAGE_ARCHS` is "all any 7202 noarch ${SDK_ARCH}-${SDKPKGSUFFIX}". 7203 7204 :term:`SDK_POSTPROCESS_COMMAND` 7205 Specifies a list of functions to call once the OpenEmbedded build 7206 system creates the SDK. You can specify functions separated by 7207 semicolons: SDK_POSTPROCESS_COMMAND += "function; ... " 7208 7209 If you need to pass an SDK path to a command within a function, you 7210 can use ``${SDK_DIR}``, which points to the parent directory used by 7211 the OpenEmbedded build system when creating SDK output. See the 7212 :term:`SDK_DIR` variable for more information. 7213 7214 :term:`SDK_PREFIX` 7215 The toolchain binary prefix used for 7216 :ref:`ref-classes-nativesdk` recipes. The 7217 OpenEmbedded build system uses the :term:`SDK_PREFIX` value to set the 7218 :term:`TARGET_PREFIX` when building 7219 ``nativesdk`` recipes. The default value is "${SDK_SYS}-". 7220 7221 :term:`SDK_RECRDEP_TASKS` 7222 A list of shared state tasks added to the extensible SDK. By default, 7223 the following tasks are added: 7224 7225 - :ref:`ref-tasks-populate_lic` 7226 - :ref:`ref-tasks-package_qa` 7227 - :ref:`ref-tasks-populate_sysroot` 7228 - :ref:`ref-tasks-deploy` 7229 7230 Despite the default value of "" for the 7231 :term:`SDK_RECRDEP_TASKS` variable, the above four tasks are always added 7232 to the SDK. To specify tasks beyond these four, you need to use the 7233 :term:`SDK_RECRDEP_TASKS` variable (e.g. you are defining additional 7234 tasks that are needed in order to build 7235 :term:`SDK_TARGETS`). 7236 7237 :term:`SDK_SYS` 7238 Specifies the system, including the architecture and the operating 7239 system, for which the SDK will be built. 7240 7241 The OpenEmbedded build system automatically sets this variable based 7242 on :term:`SDK_ARCH`, 7243 :term:`SDK_VENDOR`, and 7244 :term:`SDK_OS`. You do not need to set the :term:`SDK_SYS` 7245 variable yourself. 7246 7247 :term:`SDK_TARGET_MANIFEST` 7248 The manifest file for the target part of the SDK. This file lists all 7249 the installed packages that make up the target part of the SDK. The 7250 file contains package information on a line-per-package basis as 7251 follows:: 7252 7253 packagename packagearch version 7254 7255 The :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class 7256 defines the manifest file as follows:: 7257 7258 SDK_TARGET_MANIFEST = "${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.target.manifest" 7259 7260 The location is derived using the :term:`SDK_DEPLOY` and 7261 :term:`TOOLCHAIN_OUTPUTNAME` variables. 7262 7263 :term:`SDK_TARGETS` 7264 A list of targets to install from shared state as part of the 7265 standard or extensible SDK installation. The default value is "${PN}" 7266 (i.e. the image from which the SDK is built). 7267 7268 The :term:`SDK_TARGETS` variable is an internal variable and typically 7269 would not be changed. 7270 7271 :term:`SDK_TITLE` 7272 The title to be printed when running the SDK installer. By default, 7273 this title is based on the :term:`DISTRO_NAME` or 7274 :term:`DISTRO` variable and is set in the 7275 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class as 7276 follows:: 7277 7278 SDK_TITLE ??= "${@d.getVar('DISTRO_NAME') or d.getVar('DISTRO')} SDK" 7279 7280 For the default distribution "poky", 7281 :term:`SDK_TITLE` is set to "Poky (Yocto Project Reference Distro)". 7282 7283 For information on how to change this default title, see the 7284 ":ref:`sdk-manual/appendix-customizing:changing the extensible sdk installer title`" 7285 section in the Yocto Project Application Development and the 7286 Extensible Software Development Kit (eSDK) manual. 7287 7288 :term:`SDK_TOOLCHAIN_LANGS` 7289 Specifies programming languages to support in the SDK, as a 7290 space-separated list. Currently supported items are ``rust`` and ``go``. 7291 7292 :term:`SDK_UPDATE_URL` 7293 An optional URL for an update server for the extensible SDK. If set, 7294 the value is used as the default update server when running 7295 ``devtool sdk-update`` within the extensible SDK. 7296 7297 :term:`SDK_VENDOR` 7298 Specifies the name of the SDK vendor. 7299 7300 :term:`SDK_VERSION` 7301 Specifies the version of the SDK. The Poky distribution configuration file 7302 (``/meta-poky/conf/distro/poky.conf``) sets the default 7303 :term:`SDK_VERSION` as follows:: 7304 7305 SDK_VERSION = "${@d.getVar('DISTRO_VERSION').replace('snapshot-${METADATA_REVISION}', 'snapshot')}" 7306 7307 For additional information, see the 7308 :term:`DISTRO_VERSION` and 7309 :term:`METADATA_REVISION` variables. 7310 7311 :term:`SDK_ZIP_OPTIONS` 7312 Specifies extra options to pass to the ``zip`` command when zipping the SDK 7313 (i.e. when :term:`SDK_ARCHIVE_TYPE` is set to "zip"). The default value is 7314 "-y". 7315 7316 :term:`SDKEXTPATH` 7317 The default installation directory for the Extensible SDK. By 7318 default, this directory is based on the :term:`DISTRO` 7319 variable and is set in the 7320 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class as 7321 follows:: 7322 7323 SDKEXTPATH ??= "~/${@d.getVar('DISTRO')}_sdk" 7324 7325 For the 7326 default distribution "poky", the :term:`SDKEXTPATH` is set to "poky_sdk". 7327 7328 For information on how to change this default directory, see the 7329 ":ref:`sdk-manual/appendix-customizing:changing the default sdk installation directory`" 7330 section in the Yocto Project Application Development and the 7331 Extensible Software Development Kit (eSDK) manual. 7332 7333 :term:`SDKIMAGE_FEATURES` 7334 Equivalent to :term:`IMAGE_FEATURES`. However, this variable applies to 7335 the SDK generated from an image using the following command:: 7336 7337 $ bitbake -c populate_sdk imagename 7338 7339 :term:`SDKMACHINE` 7340 The machine for which the SDK is built. In other words, the SDK is built 7341 such that it runs on the target you specify with the :term:`SDKMACHINE` 7342 value. The value points to a corresponding ``.conf`` file under 7343 ``conf/machine-sdk/`` in the enabled layers, for example ``aarch64``, 7344 ``i586``, ``i686``, ``ppc64``, ``ppc64le``, and ``x86_64`` are 7345 :oe_git:`available in OpenEmbedded-Core </openembedded-core/tree/meta/conf/machine-sdk>`. 7346 7347 The variable defaults to :term:`BUILD_ARCH` so that SDKs are built for the 7348 architecture of the build machine. 7349 7350 .. note:: 7351 7352 You cannot set the :term:`SDKMACHINE` 7353 variable in your distribution configuration file. If you do, the 7354 configuration will not take effect. 7355 7356 :term:`SDKPATH` 7357 Defines the path offered to the user for installation of the SDK that 7358 is generated by the OpenEmbedded build system. The path appears as 7359 the default location for installing the SDK when you run the SDK's 7360 installation script. You can override the offered path when you run 7361 the script. 7362 7363 :term:`SDKTARGETSYSROOT` 7364 The full path to the sysroot used for cross-compilation within an SDK 7365 as it will be when installed into the default 7366 :term:`SDKPATH`. 7367 7368 :term:`SECTION` 7369 The section in which packages should be categorized. Package 7370 management utilities can make use of this variable. 7371 7372 :term:`SELECTED_OPTIMIZATION` 7373 Specifies the optimization flags passed to the C compiler when 7374 building for the target. The flags are passed through the default 7375 value of the :term:`TARGET_CFLAGS` variable. 7376 7377 The :term:`SELECTED_OPTIMIZATION` variable takes the value of 7378 :term:`FULL_OPTIMIZATION` unless :term:`DEBUG_BUILD` = "1", in which 7379 case the value of :term:`DEBUG_OPTIMIZATION` is used. 7380 7381 :term:`SERIAL_CONSOLES` 7382 Defines a serial console (TTY) to enable using 7383 :wikipedia:`getty <Getty_(Unix)>`. Provide a value that specifies the 7384 baud rate followed by the TTY device name separated by a semicolon. 7385 Use spaces to separate multiple devices:: 7386 7387 SERIAL_CONSOLES = "115200;ttyS0 115200;ttyS1" 7388 7389 :term:`SERIAL_CONSOLES_CHECK` 7390 Specifies serial consoles, which must be listed in 7391 :term:`SERIAL_CONSOLES`, to check against 7392 ``/proc/console`` before enabling them using getty. This variable 7393 allows aliasing in the format: <device>:<alias>. If a device was 7394 listed as "sclp_line0" in ``/dev/`` and "ttyS0" was listed in 7395 ``/proc/console``, you would do the following:: 7396 7397 SERIAL_CONSOLES_CHECK = "slcp_line0:ttyS0" 7398 7399 This variable is currently only supported with SysVinit (i.e. not 7400 with systemd). Note that :term:`SERIAL_CONSOLES_CHECK` also requires 7401 ``/etc/inittab`` to be writable when used with SysVinit. This makes it 7402 incompatible with customizations such as the following:: 7403 7404 EXTRA_IMAGE_FEATURES += "read-only-rootfs" 7405 7406 :term:`SETUPTOOLS_BUILD_ARGS` 7407 When used by recipes that inherit the :ref:`ref-classes-setuptools3` 7408 class, this variable can be used to specify additional arguments to be 7409 passed to ``setup.py build`` in the ``setuptools3_do_compile()`` task. 7410 7411 :term:`SETUPTOOLS_INSTALL_ARGS` 7412 When used by recipes that inherit the :ref:`ref-classes-setuptools3` 7413 class, this variable can be used to specify additional arguments to be 7414 passed to ``setup.py install`` in the ``setuptools3_do_install()`` task. 7415 7416 :term:`SETUPTOOLS_SETUP_PATH` 7417 When used by recipes that inherit the :ref:`ref-classes-setuptools3` 7418 class, this variable should be used to specify the directory in which 7419 the ``setup.py`` file is located if it is not at the root of the source 7420 tree (as specified by :term:`S`). For example, in a recipe where the 7421 sources are fetched from a Git repository and ``setup.py`` is in a 7422 ``python/pythonmodule`` subdirectory, you would have this:: 7423 7424 S = "${WORKDIR}/git" 7425 SETUPTOOLS_SETUP_PATH = "${S}/python/pythonmodule" 7426 7427 :term:`SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS` 7428 A list of recipe dependencies that should not be used to determine 7429 signatures of tasks from one recipe when they depend on tasks from 7430 another recipe. For example:: 7431 7432 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += "intone->mplayer2" 7433 7434 In the previous example, ``intone`` depends on ``mplayer2``. 7435 7436 You can use the special token ``"*"`` on the left-hand side of the 7437 dependency to match all recipes except the one on the right-hand 7438 side. Here is an example:: 7439 7440 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS += "*->quilt-native" 7441 7442 In the previous example, all recipes except ``quilt-native`` ignore 7443 task signatures from the ``quilt-native`` recipe when determining 7444 their task signatures. 7445 7446 Use of this variable is one mechanism to remove dependencies that 7447 affect task signatures and thus force rebuilds when a recipe changes. 7448 7449 .. note:: 7450 7451 If you add an inappropriate dependency for a recipe relationship, 7452 the software might break during runtime if the interface of the 7453 second recipe was changed after the first recipe had been built. 7454 7455 :term:`SIGGEN_EXCLUDERECIPES_ABISAFE` 7456 A list of recipes that are completely stable and will never change. 7457 The ABI for the recipes in the list are presented by output from the 7458 tasks run to build the recipe. Use of this variable is one way to 7459 remove dependencies from one recipe on another that affect task 7460 signatures and thus force rebuilds when the recipe changes. 7461 7462 .. note:: 7463 7464 If you add an inappropriate variable to this list, the software 7465 might break at runtime if the interface of the recipe was changed 7466 after the other had been built. 7467 7468 :term:`SITEINFO_BITS` 7469 Specifies the number of bits for the target system CPU. The value 7470 should be either "32" or "64". 7471 7472 :term:`SITEINFO_ENDIANNESS` 7473 Specifies the endian byte order of the target system. The value 7474 should be either "le" for little-endian or "be" for big-endian. 7475 7476 :term:`SKIP_FILEDEPS` 7477 Enables removal of all files from the "Provides" section of an RPM 7478 package. Removal of these files is required for packages containing 7479 prebuilt binaries and libraries such as ``libstdc++`` and ``glibc``. 7480 7481 To enable file removal, set the variable to "1" in your 7482 ``conf/local.conf`` configuration file in your: 7483 :term:`Build Directory`:: 7484 7485 SKIP_FILEDEPS = "1" 7486 7487 :term:`SKIP_RECIPE` 7488 Used to prevent the OpenEmbedded build system from building a given 7489 recipe. Specify the :term:`PN` value as a variable flag (``varflag``) 7490 and provide a reason, which will be reported when attempting to 7491 build the recipe. 7492 7493 To prevent a recipe from being built, use the :term:`SKIP_RECIPE` 7494 variable in your ``local.conf`` file or distribution configuration. 7495 Here is an example which prevents ``myrecipe`` from being built:: 7496 7497 SKIP_RECIPE[myrecipe] = "Not supported by our organization." 7498 7499 :term:`SOC_FAMILY` 7500 Groups together machines based upon the same family of SOC (System On 7501 Chip). You typically set this variable in a common ``.inc`` file that 7502 you include in the configuration files of all the machines. 7503 7504 .. note:: 7505 7506 You must include ``conf/machine/include/soc-family.inc`` for this 7507 variable to appear in :term:`MACHINEOVERRIDES`. 7508 7509 :term:`SOLIBS` 7510 Defines the suffix for shared libraries used on the target platform. 7511 By default, this suffix is ".so.*" for all Linux-based systems and is 7512 defined in the ``meta/conf/bitbake.conf`` configuration file. 7513 7514 You will see this variable referenced in the default values of 7515 ``FILES:${PN}``. 7516 7517 :term:`SOLIBSDEV` 7518 Defines the suffix for the development symbolic link (symlink) for 7519 shared libraries on the target platform. By default, this suffix is 7520 ".so" for Linux-based systems and is defined in the 7521 ``meta/conf/bitbake.conf`` configuration file. 7522 7523 You will see this variable referenced in the default values of 7524 ``FILES:${PN}-dev``. 7525 7526 :term:`SOURCE_DATE_EPOCH` 7527 This defines a date expressed in number of seconds since 7528 the UNIX EPOCH (01 Jan 1970 00:00:00 UTC), which is used by 7529 multiple build systems to force a timestamp in built binaries. 7530 Many upstream projects already support this variable. 7531 7532 You will find more details in the `official specifications 7533 <https://reproducible-builds.org/specs/source-date-epoch/>`__. 7534 7535 A value for each recipe is computed from the sources by 7536 :oe_git:`meta/lib/oe/reproducible.py </openembedded-core/tree/meta/lib/oe/reproducible.py>`. 7537 7538 If a recipe wishes to override the default behavior, it should set its 7539 own :term:`SOURCE_DATE_EPOCH` value:: 7540 7541 SOURCE_DATE_EPOCH = "1613559011" 7542 7543 :term:`SOURCE_MIRROR_FETCH` 7544 When you are fetching files to create a mirror of sources (i.e. 7545 creating a source mirror), setting :term:`SOURCE_MIRROR_FETCH` to "1" in 7546 your ``local.conf`` configuration file ensures the source for all 7547 recipes are fetched regardless of whether or not a recipe is 7548 compatible with the configuration. A recipe is considered 7549 incompatible with the currently configured machine when either or 7550 both the :term:`COMPATIBLE_MACHINE` 7551 variable and :term:`COMPATIBLE_HOST` variables 7552 specify compatibility with a machine other than that of the current 7553 machine or host. 7554 7555 .. note:: 7556 7557 Do not set the :term:`SOURCE_MIRROR_FETCH` 7558 variable unless you are creating a source mirror. In other words, 7559 do not set the variable during a normal build. 7560 7561 :term:`SOURCE_MIRROR_URL` 7562 Defines your own :term:`PREMIRRORS` from which to 7563 first fetch source before attempting to fetch from the upstream 7564 specified in :term:`SRC_URI`. 7565 7566 To use this variable, you must globally inherit the 7567 :ref:`ref-classes-own-mirrors` class and then provide 7568 the URL to your mirrors. Here is the general syntax:: 7569 7570 INHERIT += "own-mirrors" 7571 SOURCE_MIRROR_URL = "http://example.com/my_source_mirror" 7572 7573 .. note:: 7574 7575 You can specify only a single URL in :term:`SOURCE_MIRROR_URL`. 7576 7577 :term:`SPDX_ARCHIVE_PACKAGED` 7578 This option allows to add to :term:`SPDX` output compressed archives 7579 of the files in the generated target packages. 7580 7581 Such archives are available in 7582 ``tmp/deploy/spdx/MACHINE/packages/packagename.tar.zst`` 7583 under the :term:`Build Directory`. 7584 7585 Enable this option as follows:: 7586 7587 SPDX_ARCHIVE_PACKAGED = "1" 7588 7589 According to our tests on release 4.1 "langdale", building 7590 ``core-image-minimal`` for the ``qemux86-64`` machine, enabling this 7591 option multiplied the size of the ``tmp/deploy/spdx`` directory by a 7592 factor of 13 (+1.6 GiB for this image), compared to just using the 7593 :ref:`ref-classes-create-spdx` class with no option. 7594 7595 Note that this option doesn't increase the size of :term:`SPDX` 7596 files in ``tmp/deploy/images/MACHINE``. 7597 7598 :term:`SPDX_ARCHIVE_SOURCES` 7599 This option allows to add to :term:`SPDX` output compressed archives 7600 of the sources for packages installed on the target. It currently 7601 only works when :term:`SPDX_INCLUDE_SOURCES` is set. 7602 7603 This is one way of fulfilling "source code access" license 7604 requirements. 7605 7606 Such source archives are available in 7607 ``tmp/deploy/spdx/MACHINE/recipes/recipe-packagename.tar.zst`` 7608 under the :term:`Build Directory`. 7609 7610 Enable this option as follows:: 7611 7612 SPDX_INCLUDE_SOURCES = "1" 7613 SPDX_ARCHIVE_SOURCES = "1" 7614 7615 According to our tests on release 4.1 "langdale", building 7616 ``core-image-minimal`` for the ``qemux86-64`` machine, enabling 7617 these options multiplied the size of the ``tmp/deploy/spdx`` 7618 directory by a factor of 11 (+1.4 GiB for this image), 7619 compared to just using the :ref:`ref-classes-create-spdx` 7620 class with no option. 7621 7622 Note that using this option only marginally increases the size 7623 of the :term:`SPDX` output in ``tmp/deploy/images/MACHINE/`` 7624 (+ 0.07\% with the tested image), compared to just enabling 7625 :term:`SPDX_INCLUDE_SOURCES`. 7626 7627 :term:`SPDX_CUSTOM_ANNOTATION_VARS` 7628 This option allows to associate `SPDX annotations 7629 <https://spdx.github.io/spdx-spec/v2.3/annotations/>`__ to a recipe, 7630 using the values of variables in the recipe:: 7631 7632 ANNOTATION1 = "First annotation for recipe" 7633 ANNOTATION2 = "Second annotation for recipe" 7634 SPDX_CUSTOM_ANNOTATION_VARS = "ANNOTATION1 ANNOTATION2" 7635 7636 This will add a new block to the recipe ``.sdpx.json`` output:: 7637 7638 "annotations": [ 7639 { 7640 "annotationDate": "2023-04-18T08:32:12Z", 7641 "annotationType": "OTHER", 7642 "annotator": "Tool: oe-spdx-creator - 1.0", 7643 "comment": "ANNOTATION1=First annotation for recipe" 7644 }, 7645 { 7646 "annotationDate": "2023-04-18T08:32:12Z", 7647 "annotationType": "OTHER", 7648 "annotator": "Tool: oe-spdx-creator - 1.0", 7649 "comment": "ANNOTATION2=Second annotation for recipe" 7650 } 7651 ], 7652 7653 :term:`SPDX_INCLUDE_SOURCES` 7654 This option allows to add a description of the source files used to build 7655 the host tools and the target packages, to the ``spdx.json`` files in 7656 ``tmp/deploy/spdx/MACHINE/recipes/`` under the :term:`Build Directory`. 7657 As a consequence, the ``spdx.json`` files under the ``by-namespace`` and 7658 ``packages`` subdirectories in ``tmp/deploy/spdx/MACHINE`` are also 7659 modified to include references to such source file descriptions. 7660 7661 Enable this option as follows:: 7662 7663 SPDX_INCLUDE_SOURCES = "1" 7664 7665 According to our tests on release 4.1 "langdale", building 7666 ``core-image-minimal`` for the ``qemux86-64`` machine, enabling 7667 this option multiplied the total size of the ``tmp/deploy/spdx`` 7668 directory by a factor of 3 (+291 MiB for this image), 7669 and the size of the ``IMAGE-MACHINE.spdx.tar.zst`` in 7670 ``tmp/deploy/images/MACHINE`` by a factor of 130 (+15 MiB for this 7671 image), compared to just using the :ref:`ref-classes-create-spdx` class 7672 with no option. 7673 7674 :term:`SPDX_PRETTY` 7675 This option makes the SPDX output more human-readable, using 7676 identation and newlines, instead of the default output in a 7677 single line:: 7678 7679 SPDX_PRETTY = "1" 7680 7681 The generated SPDX files are approximately 20% bigger, but 7682 this option is recommended if you want to inspect the SPDX 7683 output files with a text editor. 7684 7685 :term:`SPDXLICENSEMAP` 7686 Maps commonly used license names to their SPDX counterparts found in 7687 ``meta/files/common-licenses/``. For the default :term:`SPDXLICENSEMAP` 7688 mappings, see the ``meta/conf/licenses.conf`` file. 7689 7690 For additional information, see the :term:`LICENSE` 7691 variable. 7692 7693 :term:`SPECIAL_PKGSUFFIX` 7694 A list of prefixes for :term:`PN` used by the OpenEmbedded 7695 build system to create variants of recipes or packages. The list 7696 specifies the prefixes to strip off during certain circumstances such 7697 as the generation of the :term:`BPN` variable. 7698 7699 :term:`SPL_BINARY` 7700 The file type for the Secondary Program Loader (SPL). Some devices 7701 use an SPL from which to boot (e.g. the BeagleBone development 7702 board). For such cases, you can declare the file type of the SPL 7703 binary in the ``u-boot.inc`` include file, which is used in the 7704 U-Boot recipe. 7705 7706 The SPL file type is set to "null" by default in the ``u-boot.inc`` 7707 file as follows:: 7708 7709 # Some versions of u-boot build an SPL (Second Program Loader) image that 7710 # should be packaged along with the u-boot binary as well as placed in the 7711 # deploy directory. For those versions they can set the following variables 7712 # to allow packaging the SPL. 7713 SPL_BINARY ?= "" 7714 SPL_BINARYNAME ?= "${@os.path.basename(d.getVar("SPL_BINARY"))}" 7715 SPL_IMAGE ?= "${SPL_BINARYNAME}-${MACHINE}-${PV}-${PR}" 7716 SPL_SYMLINK ?= "${SPL_BINARYNAME}-${MACHINE}" 7717 7718 The :term:`SPL_BINARY` variable helps form 7719 various ``SPL_*`` variables used by the OpenEmbedded build system. 7720 7721 See the BeagleBone machine configuration example in the 7722 ":ref:`dev-manual/layers:adding a layer using the \`\`bitbake-layers\`\` script`" 7723 section in the Yocto Project Board Support Package Developer's Guide 7724 for additional information. 7725 7726 :term:`SRCREV_FORMAT` 7727 See :term:`bitbake:SRCREV_FORMAT` in the BitBake manual. 7728 7729 :term:`SRC_URI` 7730 7731 See the BitBake manual for the initial description for this variable: 7732 :term:`bitbake:SRC_URI`. 7733 7734 The following features are added by OpenEmbedded and the Yocto Project. 7735 7736 There are standard and recipe-specific options. Here are standard ones: 7737 7738 - ``apply`` --- whether to apply the patch or not. The default 7739 action is to apply the patch. 7740 7741 - ``striplevel`` --- which striplevel to use when applying the 7742 patch. The default level is 1. 7743 7744 - ``patchdir`` --- specifies the directory in which the patch should 7745 be applied. The default is ``${``\ :term:`S`\ ``}``. 7746 7747 Here are options specific to recipes building code from a revision 7748 control system: 7749 7750 - ``mindate`` --- apply the patch only if 7751 :term:`SRCDATE` is equal to or greater than 7752 ``mindate``. 7753 7754 - ``maxdate`` --- apply the patch only if :term:`SRCDATE` is not later 7755 than ``maxdate``. 7756 7757 - ``minrev`` --- apply the patch only if :term:`SRCREV` is equal to or 7758 greater than ``minrev``. 7759 7760 - ``maxrev`` --- apply the patch only if :term:`SRCREV` is not later 7761 than ``maxrev``. 7762 7763 - ``rev`` --- apply the patch only if :term:`SRCREV` is equal to 7764 ``rev``. 7765 7766 - ``notrev`` --- apply the patch only if :term:`SRCREV` is not equal to 7767 ``rev``. 7768 7769 .. note:: 7770 7771 If you want the build system to pick up files specified through 7772 a :term:`SRC_URI` statement from your append file, you need to be 7773 sure to extend the :term:`FILESPATH` variable by also using the 7774 :term:`FILESEXTRAPATHS` variable from within your append file. 7775 7776 :term:`SRC_URI_OVERRIDES_PACKAGE_ARCH` 7777 By default, the OpenEmbedded build system automatically detects 7778 whether :term:`SRC_URI` contains files that are machine-specific. If so, 7779 the build system automatically changes :term:`PACKAGE_ARCH`. Setting this 7780 variable to "0" disables this behavior. 7781 7782 :term:`SRCDATE` 7783 The date of the source code used to build the package. This variable 7784 applies only if the source was fetched from a Source Code Manager 7785 (SCM). 7786 7787 :term:`SRCPV` 7788 Returns the version string of the current package. This string is 7789 used to help define the value of :term:`PV`. 7790 7791 The :term:`SRCPV` variable is defined in the ``meta/conf/bitbake.conf`` 7792 configuration file in the :term:`Source Directory` as 7793 follows:: 7794 7795 SRCPV = "${@bb.fetch2.get_srcrev(d)}" 7796 7797 Recipes that need to define :term:`PV` do so with the help of the 7798 :term:`SRCPV`. For example, the ``ofono`` recipe (``ofono_git.bb``) 7799 located in ``meta/recipes-connectivity`` in the Source Directory 7800 defines :term:`PV` as follows:: 7801 7802 PV = "0.12-git${SRCPV}" 7803 7804 :term:`SRCREV` 7805 The revision of the source code used to build the package. This 7806 variable applies to Subversion, Git, Mercurial, and Bazaar only. Note 7807 that if you want to build a fixed revision and you want to avoid 7808 performing a query on the remote repository every time BitBake parses 7809 your recipe, you should specify a :term:`SRCREV` that is a full revision 7810 identifier and not just a tag. 7811 7812 .. note:: 7813 7814 For information on limitations when inheriting the latest revision 7815 of software using :term:`SRCREV`, see the :term:`AUTOREV` variable 7816 description and the 7817 ":ref:`dev-manual/packages:automatically incrementing a package version number`" 7818 section, which is in the Yocto Project Development Tasks Manual. 7819 7820 :term:`SRCTREECOVEREDTASKS` 7821 A list of tasks that are typically not relevant (and therefore skipped) 7822 when building using the :ref:`ref-classes-externalsrc` 7823 class. The default value as set in that class file is the set of tasks 7824 that are rarely needed when using external source:: 7825 7826 SRCTREECOVEREDTASKS ?= "do_patch do_unpack do_fetch" 7827 7828 The notable exception is when processing external kernel source as 7829 defined in the :ref:`ref-classes-kernel-yocto` class file (formatted for 7830 aesthetics):: 7831 7832 SRCTREECOVEREDTASKS += "\ 7833 do_validate_branches \ 7834 do_kernel_configcheck \ 7835 do_kernel_checkout \ 7836 do_fetch \ 7837 do_unpack \ 7838 do_patch \ 7839 " 7840 7841 See the associated :term:`EXTERNALSRC` and :term:`EXTERNALSRC_BUILD` 7842 variables for more information. 7843 7844 :term:`SSTATE_DIR` 7845 The directory for the shared state cache. 7846 7847 :term:`SSTATE_EXCLUDEDEPS_SYSROOT` 7848 This variable allows to specify indirect dependencies to exclude 7849 from sysroots, for example to avoid the situations when a dependency on 7850 any ``-native`` recipe will pull in all dependencies of that recipe 7851 in the recipe sysroot. This behaviour might not always be wanted, 7852 for example when that ``-native`` recipe depends on build tools 7853 that are not relevant for the current recipe. 7854 7855 This way, irrelevant dependencies are ignored, which could have 7856 prevented the reuse of prebuilt artifacts stored in the Shared 7857 State Cache. 7858 7859 :term:`SSTATE_EXCLUDEDEPS_SYSROOT` is evaluated as two regular 7860 expressions of recipe and dependency to ignore. An example 7861 is the rule in :oe_git:`meta/conf/layer.conf </openembedded-core/tree/meta/conf/layer.conf>`:: 7862 7863 # Nothing needs to depend on libc-initial 7864 # base-passwd/shadow-sysroot don't need their dependencies 7865 SSTATE_EXCLUDEDEPS_SYSROOT += "\ 7866 .*->.*-initial.* \ 7867 .*(base-passwd|shadow-sysroot)->.* \ 7868 " 7869 7870 The ``->`` substring represents the dependency between 7871 the two regular expressions. 7872 7873 :term:`SSTATE_MIRROR_ALLOW_NETWORK` 7874 If set to "1", allows fetches from mirrors that are specified in 7875 :term:`SSTATE_MIRRORS` to work even when 7876 fetching from the network is disabled by setting :term:`BB_NO_NETWORK` to 7877 "1". Using the :term:`SSTATE_MIRROR_ALLOW_NETWORK` variable is useful if 7878 you have set :term:`SSTATE_MIRRORS` to point to an internal server for 7879 your shared state cache, but you want to disable any other fetching 7880 from the network. 7881 7882 :term:`SSTATE_MIRRORS` 7883 Configures the OpenEmbedded build system to search other mirror 7884 locations for prebuilt cache data objects before building out the 7885 data. This variable works like fetcher :term:`MIRRORS` 7886 and :term:`PREMIRRORS` and points to the cache 7887 locations to check for the shared state (sstate) objects. 7888 7889 You can specify a filesystem directory or a remote URL such as HTTP 7890 or FTP. The locations you specify need to contain the shared state 7891 cache (sstate-cache) results from previous builds. The sstate-cache 7892 you point to can also be from builds on other machines. 7893 7894 When pointing to sstate build artifacts on another machine that uses 7895 a different GCC version for native builds, you must configure 7896 :term:`SSTATE_MIRRORS` with a regular expression that maps local search 7897 paths to server paths. The paths need to take into account 7898 :term:`NATIVELSBSTRING` set by the :ref:`ref-classes-uninative` class. 7899 For example, the following maps the local search path ``universal-4.9`` 7900 to the server-provided path server_url_sstate_path:: 7901 7902 SSTATE_MIRRORS ?= "file://universal-4.9/(.*) https://server_url_sstate_path/universal-4.8/\1" 7903 7904 If a mirror uses the same structure as 7905 :term:`SSTATE_DIR`, you need to add "PATH" at the 7906 end as shown in the examples below. The build system substitutes the 7907 correct path within the directory structure:: 7908 7909 SSTATE_MIRRORS ?= "\ 7910 file://.* https://someserver.tld/share/sstate/PATH;downloadfilename=PATH \ 7911 file://.* file:///some-local-dir/sstate/PATH" 7912 7913 :term:`SSTATE_SCAN_FILES` 7914 Controls the list of files the OpenEmbedded build system scans for 7915 hardcoded installation paths. The variable uses a space-separated 7916 list of filenames (not paths) with standard wildcard characters 7917 allowed. 7918 7919 During a build, the OpenEmbedded build system creates a shared state 7920 (sstate) object during the first stage of preparing the sysroots. 7921 That object is scanned for hardcoded paths for original installation 7922 locations. The list of files that are scanned for paths is controlled 7923 by the :term:`SSTATE_SCAN_FILES` variable. Typically, recipes add files 7924 they want to be scanned to the value of :term:`SSTATE_SCAN_FILES` rather 7925 than the variable being comprehensively set. The 7926 :ref:`ref-classes-sstate` class specifies the default list of files. 7927 7928 For details on the process, see the :ref:`ref-classes-staging` class. 7929 7930 :term:`STAGING_BASE_LIBDIR_NATIVE` 7931 Specifies the path to the ``/lib`` subdirectory of the sysroot 7932 directory for the build host. 7933 7934 :term:`STAGING_BASELIBDIR` 7935 Specifies the path to the ``/lib`` subdirectory of the sysroot 7936 directory for the target for which the current recipe is being built 7937 (:term:`STAGING_DIR_HOST`). 7938 7939 :term:`STAGING_BINDIR` 7940 Specifies the path to the ``/usr/bin`` subdirectory of the sysroot 7941 directory for the target for which the current recipe is being built 7942 (:term:`STAGING_DIR_HOST`). 7943 7944 :term:`STAGING_BINDIR_CROSS` 7945 Specifies the path to the directory containing binary configuration 7946 scripts. These scripts provide configuration information for other 7947 software that wants to make use of libraries or include files 7948 provided by the software associated with the script. 7949 7950 .. note:: 7951 7952 This style of build configuration has been largely replaced by 7953 ``pkg-config``. Consequently, if ``pkg-config`` is supported by the 7954 library to which you are linking, it is recommended you use 7955 ``pkg-config`` instead of a provided configuration script. 7956 7957 :term:`STAGING_BINDIR_NATIVE` 7958 Specifies the path to the ``/usr/bin`` subdirectory of the sysroot 7959 directory for the build host. 7960 7961 :term:`STAGING_DATADIR` 7962 Specifies the path to the ``/usr/share`` subdirectory of the sysroot 7963 directory for the target for which the current recipe is being built 7964 (:term:`STAGING_DIR_HOST`). 7965 7966 :term:`STAGING_DATADIR_NATIVE` 7967 Specifies the path to the ``/usr/share`` subdirectory of the sysroot 7968 directory for the build host. 7969 7970 :term:`STAGING_DIR` 7971 Helps construct the ``recipe-sysroots`` directory, which is used 7972 during packaging. 7973 7974 For information on how staging for recipe-specific sysroots occurs, 7975 see the :ref:`ref-tasks-populate_sysroot` 7976 task, the ":ref:`sdk-manual/extensible:sharing files between recipes`" 7977 section in the Yocto Project Development Tasks Manual, the 7978 ":ref:`overview-manual/concepts:configuration, compilation, and staging`" 7979 section in the Yocto Project Overview and Concepts Manual, and the 7980 :term:`SYSROOT_DIRS` variable. 7981 7982 .. note:: 7983 7984 Recipes should never write files directly under the :term:`STAGING_DIR` 7985 directory because the OpenEmbedded build system manages the 7986 directory automatically. Instead, files should be installed to 7987 ``${``\ :term:`D`\ ``}`` within your recipe's :ref:`ref-tasks-install` 7988 task and then the OpenEmbedded build system will stage a subset of 7989 those files into the sysroot. 7990 7991 :term:`STAGING_DIR_HOST` 7992 Specifies the path to the sysroot directory for the system on which 7993 the component is built to run (the system that hosts the component). 7994 For most recipes, this sysroot is the one in which that recipe's 7995 :ref:`ref-tasks-populate_sysroot` task copies 7996 files. Exceptions include ``-native`` recipes, where the 7997 :ref:`ref-tasks-populate_sysroot` task instead uses 7998 :term:`STAGING_DIR_NATIVE`. Depending on 7999 the type of recipe and the build target, :term:`STAGING_DIR_HOST` can 8000 have the following values: 8001 8002 - For recipes building for the target machine, the value is 8003 "${:term:`STAGING_DIR`}/${:term:`MACHINE`}". 8004 8005 - For native recipes building for the build host, the value is empty 8006 given the assumption that when building for the build host, the 8007 build host's own directories should be used. 8008 8009 .. note:: 8010 8011 ``-native`` recipes are not installed into host paths like such 8012 as ``/usr``. Rather, these recipes are installed into 8013 :term:`STAGING_DIR_NATIVE`. When compiling ``-native`` recipes, 8014 standard build environment variables such as 8015 :term:`CPPFLAGS` and 8016 :term:`CFLAGS` are set up so that both host paths 8017 and :term:`STAGING_DIR_NATIVE` are searched for libraries and 8018 headers using, for example, GCC's ``-isystem`` option. 8019 8020 Thus, the emphasis is that the ``STAGING_DIR*`` variables 8021 should be viewed as input variables by tasks such as 8022 :ref:`ref-tasks-configure`, 8023 :ref:`ref-tasks-compile`, and 8024 :ref:`ref-tasks-install`. Having the real system 8025 root correspond to :term:`STAGING_DIR_HOST` makes conceptual sense 8026 for ``-native`` recipes, as they make use of host headers and 8027 libraries. 8028 8029 :term:`STAGING_DIR_NATIVE` 8030 Specifies the path to the sysroot directory used when building 8031 components that run on the build host itself. 8032 8033 :term:`STAGING_DIR_TARGET` 8034 Specifies the path to the sysroot used for the system for which the 8035 component generates code. For components that do not generate code, 8036 which is the majority, :term:`STAGING_DIR_TARGET` is set to match 8037 :term:`STAGING_DIR_HOST`. 8038 8039 Some recipes build binaries that can run on the target system but those 8040 binaries in turn generate code for another different system (e.g. 8041 :ref:`ref-classes-cross-canadian` recipes). Using terminology from GNU, 8042 the primary system is referred to as the "HOST" and the secondary, or 8043 different, system is referred to as the "TARGET". Thus, the binaries 8044 run on the "HOST" system and generate binaries for the "TARGET" 8045 system. The :term:`STAGING_DIR_HOST` variable points to the sysroot used 8046 for the "HOST" system, while :term:`STAGING_DIR_TARGET` points to the 8047 sysroot used for the "TARGET" system. 8048 8049 :term:`STAGING_ETCDIR_NATIVE` 8050 Specifies the path to the ``/etc`` subdirectory of the sysroot 8051 directory for the build host. 8052 8053 :term:`STAGING_EXECPREFIXDIR` 8054 Specifies the path to the ``/usr`` subdirectory of the sysroot 8055 directory for the target for which the current recipe is being built 8056 (:term:`STAGING_DIR_HOST`). 8057 8058 :term:`STAGING_INCDIR` 8059 Specifies the path to the ``/usr/include`` subdirectory of the 8060 sysroot directory for the target for which the current recipe being 8061 built (:term:`STAGING_DIR_HOST`). 8062 8063 :term:`STAGING_INCDIR_NATIVE` 8064 Specifies the path to the ``/usr/include`` subdirectory of the 8065 sysroot directory for the build host. 8066 8067 :term:`STAGING_KERNEL_BUILDDIR` 8068 Points to the directory containing the kernel build artifacts. 8069 Recipes building software that needs to access kernel build artifacts 8070 (e.g. ``systemtap-uprobes``) can look in the directory specified with 8071 the :term:`STAGING_KERNEL_BUILDDIR` variable to find these artifacts 8072 after the kernel has been built. 8073 8074 :term:`STAGING_KERNEL_DIR` 8075 The directory with kernel headers that are required to build 8076 out-of-tree modules. 8077 8078 :term:`STAGING_LIBDIR` 8079 Specifies the path to the ``/usr/lib`` subdirectory of the sysroot 8080 directory for the target for which the current recipe is being built 8081 (:term:`STAGING_DIR_HOST`). 8082 8083 :term:`STAGING_LIBDIR_NATIVE` 8084 Specifies the path to the ``/usr/lib`` subdirectory of the sysroot 8085 directory for the build host. 8086 8087 :term:`STAMP` 8088 Specifies the base path used to create recipe stamp files. The path 8089 to an actual stamp file is constructed by evaluating this string and 8090 then appending additional information. Currently, the default 8091 assignment for :term:`STAMP` as set in the ``meta/conf/bitbake.conf`` 8092 file is:: 8093 8094 STAMP = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}" 8095 8096 For information on how BitBake uses stamp files to determine if a 8097 task should be rerun, see the 8098 ":ref:`overview-manual/concepts:stamp files and the rerunning of tasks`" 8099 section in the Yocto Project Overview and Concepts Manual. 8100 8101 See :term:`STAMPS_DIR`, 8102 :term:`MULTIMACH_TARGET_SYS`, 8103 :term:`PN`, :term:`EXTENDPE`, 8104 :term:`PV`, and :term:`PR` for related variable 8105 information. 8106 8107 :term:`STAMPCLEAN` 8108 See :term:`bitbake:STAMPCLEAN` in the BitBake manual. 8109 8110 :term:`STAMPS_DIR` 8111 Specifies the base directory in which the OpenEmbedded build system 8112 places stamps. The default directory is ``${TMPDIR}/stamps``. 8113 8114 :term:`STRIP` 8115 The minimal command and arguments to run ``strip``, which is used to 8116 strip symbols. 8117 8118 :term:`SUMMARY` 8119 The short (72 characters or less) summary of the binary package for 8120 packaging systems such as ``opkg``, ``rpm``, or ``dpkg``. By default, 8121 :term:`SUMMARY` is used to define the 8122 :term:`DESCRIPTION` variable if :term:`DESCRIPTION` is 8123 not set in the recipe. 8124 8125 :term:`SVNDIR` 8126 The directory in which files checked out of a Subversion system are 8127 stored. 8128 8129 :term:`SYSLINUX_DEFAULT_CONSOLE` 8130 Specifies the kernel boot default console. If you want to use a 8131 console other than the default, set this variable in your recipe as 8132 follows where "X" is the console number you want to use:: 8133 8134 SYSLINUX_DEFAULT_CONSOLE = "console=ttyX" 8135 8136 The :ref:`ref-classes-syslinux` class initially sets 8137 this variable to null but then checks for a value later. 8138 8139 :term:`SYSLINUX_OPTS` 8140 Lists additional options to add to the syslinux file. You need to set 8141 this variable in your recipe. If you want to list multiple options, 8142 separate the options with a semicolon character (``;``). 8143 8144 The :ref:`ref-classes-syslinux` class uses this variable 8145 to create a set of options. 8146 8147 :term:`SYSLINUX_SERIAL` 8148 Specifies the alternate serial port or turns it off. To turn off 8149 serial, set this variable to an empty string in your recipe. The 8150 variable's default value is set in the 8151 :ref:`ref-classes-syslinux` class as follows:: 8152 8153 SYSLINUX_SERIAL ?= "0 115200" 8154 8155 The class checks for and uses the variable as needed. 8156 8157 :term:`SYSLINUX_SERIAL_TTY` 8158 Specifies the alternate console=tty... kernel boot argument. The 8159 variable's default value is set in the :ref:`ref-classes-syslinux` 8160 class as follows:: 8161 8162 SYSLINUX_SERIAL_TTY ?= "console=ttyS0,115200" 8163 8164 The class checks for and uses the variable as needed. 8165 8166 :term:`SYSLINUX_SPLASH` 8167 An ``.LSS`` file used as the background for the VGA boot menu when 8168 you use the boot menu. You need to set this variable in your recipe. 8169 8170 The :ref:`ref-classes-syslinux` class checks for this 8171 variable and if found, the OpenEmbedded build system installs the 8172 splash screen. 8173 8174 :term:`SYSROOT_DESTDIR` 8175 Points to the temporary directory under the work directory (default 8176 "``${``\ :term:`WORKDIR`\ ``}/sysroot-destdir``") 8177 where the files populated into the sysroot are assembled during the 8178 :ref:`ref-tasks-populate_sysroot` task. 8179 8180 :term:`SYSROOT_DIRS` 8181 Directories that are staged into the sysroot by the 8182 :ref:`ref-tasks-populate_sysroot` task. By 8183 default, the following directories are staged:: 8184 8185 SYSROOT_DIRS = " \ 8186 ${includedir} \ 8187 ${libdir} \ 8188 ${base_libdir} \ 8189 ${nonarch_base_libdir} \ 8190 ${datadir} \ 8191 /sysroot-only \ 8192 " 8193 8194 :term:`SYSROOT_DIRS_IGNORE` 8195 Directories that are not staged into the sysroot by the 8196 :ref:`ref-tasks-populate_sysroot` task. You 8197 can use this variable to exclude certain subdirectories of 8198 directories listed in :term:`SYSROOT_DIRS` from 8199 staging. By default, the following directories are not staged:: 8200 8201 SYSROOT_DIRS_IGNORE = " \ 8202 ${mandir} \ 8203 ${docdir} \ 8204 ${infodir} \ 8205 ${datadir}/X11/locale \ 8206 ${datadir}/applications \ 8207 ${datadir}/bash-completion \ 8208 ${datadir}/fonts \ 8209 ${datadir}/gtk-doc/html \ 8210 ${datadir}/installed-tests \ 8211 ${datadir}/locale \ 8212 ${datadir}/pixmaps \ 8213 ${datadir}/terminfo \ 8214 ${libdir}/${BPN}/ptest \ 8215 " 8216 8217 :term:`SYSROOT_DIRS_NATIVE` 8218 Extra directories staged into the sysroot by the 8219 :ref:`ref-tasks-populate_sysroot` task for 8220 ``-native`` recipes, in addition to those specified in 8221 :term:`SYSROOT_DIRS`. By default, the following 8222 extra directories are staged:: 8223 8224 SYSROOT_DIRS_NATIVE = " \ 8225 ${bindir} \ 8226 ${sbindir} \ 8227 ${base_bindir} \ 8228 ${base_sbindir} \ 8229 ${libexecdir} \ 8230 ${sysconfdir} \ 8231 ${localstatedir} \ 8232 " 8233 8234 .. note:: 8235 8236 Programs built by ``-native`` recipes run directly from the sysroot 8237 (:term:`STAGING_DIR_NATIVE`), which is why additional directories 8238 containing program executables and supporting files need to be staged. 8239 8240 :term:`SYSROOT_PREPROCESS_FUNCS` 8241 A list of functions to execute after files are staged into the 8242 sysroot. These functions are usually used to apply additional 8243 processing on the staged files, or to stage additional files. 8244 8245 :term:`SYSTEMD_AUTO_ENABLE` 8246 When inheriting the :ref:`ref-classes-systemd` class, 8247 this variable specifies whether the specified service in 8248 :term:`SYSTEMD_SERVICE` should start 8249 automatically or not. By default, the service is enabled to 8250 automatically start at boot time. The default setting is in the 8251 :ref:`ref-classes-systemd` class as follows:: 8252 8253 SYSTEMD_AUTO_ENABLE ??= "enable" 8254 8255 You can disable the service by setting the variable to "disable". 8256 8257 :term:`SYSTEMD_BOOT_CFG` 8258 When :term:`EFI_PROVIDER` is set to 8259 "systemd-boot", the :term:`SYSTEMD_BOOT_CFG` variable specifies the 8260 configuration file that should be used. By default, the 8261 :ref:`ref-classes-systemd-boot` class sets the 8262 :term:`SYSTEMD_BOOT_CFG` as follows:: 8263 8264 SYSTEMD_BOOT_CFG ?= "${S}/loader.conf" 8265 8266 For information on Systemd-boot, see the `Systemd-boot 8267 documentation <https://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__. 8268 8269 :term:`SYSTEMD_BOOT_ENTRIES` 8270 When :term:`EFI_PROVIDER` is set to 8271 "systemd-boot", the :term:`SYSTEMD_BOOT_ENTRIES` variable specifies a 8272 list of entry files (``*.conf``) to install that contain one boot 8273 entry per file. By default, the :ref:`ref-classes-systemd-boot` class 8274 sets the :term:`SYSTEMD_BOOT_ENTRIES` as follows:: 8275 8276 SYSTEMD_BOOT_ENTRIES ?= "" 8277 8278 For information on Systemd-boot, see the `Systemd-boot 8279 documentation <https://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__. 8280 8281 :term:`SYSTEMD_BOOT_TIMEOUT` 8282 When :term:`EFI_PROVIDER` is set to 8283 "systemd-boot", the :term:`SYSTEMD_BOOT_TIMEOUT` variable specifies the 8284 boot menu timeout in seconds. By default, the 8285 :ref:`ref-classes-systemd-boot` class sets the 8286 :term:`SYSTEMD_BOOT_TIMEOUT` as follows:: 8287 8288 SYSTEMD_BOOT_TIMEOUT ?= "10" 8289 8290 For information on Systemd-boot, see the `Systemd-boot 8291 documentation <https://www.freedesktop.org/wiki/Software/systemd/systemd-boot/>`__. 8292 8293 :term:`SYSTEMD_DEFAULT_TARGET` 8294 8295 This variable allows to set the default unit that systemd starts at bootup. 8296 Usually, this is either ``multi-user.target`` or ``graphical.target``. 8297 This works by creating a ``default.target`` symbolic link to the chosen systemd 8298 target file. 8299 8300 See `systemd's documentation 8301 <https://www.freedesktop.org/software/systemd/man/systemd.special.html>`__ 8302 for details. 8303 8304 For example, this variable is used in the :oe_git:`core-image-minimal-xfce.bb 8305 </meta-openembedded/tree/meta-xfce/recipes-core/images/core-image-minimal-xfce.bb>` 8306 recipe:: 8307 8308 SYSTEMD_DEFAULT_TARGET = "graphical.target" 8309 8310 :term:`SYSTEMD_PACKAGES` 8311 When inheriting the :ref:`ref-classes-systemd` class, 8312 this variable locates the systemd unit files when they are not found 8313 in the main recipe's package. By default, the :term:`SYSTEMD_PACKAGES` 8314 variable is set such that the systemd unit files are assumed to 8315 reside in the recipes main package:: 8316 8317 SYSTEMD_PACKAGES ?= "${PN}" 8318 8319 If these unit files are not in this recipe's main package, you need 8320 to use :term:`SYSTEMD_PACKAGES` to list the package or packages in which 8321 the build system can find the systemd unit files. 8322 8323 :term:`SYSTEMD_SERVICE` 8324 When inheriting the :ref:`ref-classes-systemd` class, 8325 this variable specifies the systemd service name for a package. 8326 8327 Multiple services can be specified, each one separated by a space. 8328 8329 When you specify this file in your recipe, use a package name 8330 override to indicate the package to which the value applies. Here is 8331 an example from the connman recipe:: 8332 8333 SYSTEMD_SERVICE:${PN} = "connman.service" 8334 8335 The package overrides that can be specified are directly related to the value of 8336 :term:`SYSTEMD_PACKAGES`. Overrides not included in :term:`SYSTEMD_PACKAGES` 8337 will be silently ignored. 8338 8339 :term:`SYSVINIT_ENABLED_GETTYS` 8340 When using :ref:`SysVinit <dev-manual/new-recipe:enabling system services>`, 8341 specifies a space-separated list of the virtual terminals that should 8342 run a :wikipedia:`getty <Getty_(Unix)>` (allowing login), assuming 8343 :term:`USE_VT` is not set to "0". 8344 8345 The default value for :term:`SYSVINIT_ENABLED_GETTYS` is "1" (i.e. only 8346 run a getty on the first virtual terminal). 8347 8348 :term:`T` 8349 This variable points to a directory were BitBake places temporary 8350 files, which consist mostly of task logs and scripts, when building a 8351 particular recipe. The variable is typically set as follows:: 8352 8353 T = "${WORKDIR}/temp" 8354 8355 The :term:`WORKDIR` is the directory into which 8356 BitBake unpacks and builds the recipe. The default ``bitbake.conf`` 8357 file sets this variable. 8358 8359 The :term:`T` variable is not to be confused with the 8360 :term:`TMPDIR` variable, which points to the root of 8361 the directory tree where BitBake places the output of an entire 8362 build. 8363 8364 :term:`TARGET_ARCH` 8365 The target machine's architecture. The OpenEmbedded build system 8366 supports many architectures. Here is an example list of architectures 8367 supported. This list is by no means complete as the architecture is 8368 configurable: 8369 8370 - arm 8371 - i586 8372 - x86_64 8373 - powerpc 8374 - powerpc64 8375 - mips 8376 - mipsel 8377 8378 For additional information on machine architectures, see the 8379 :term:`TUNE_ARCH` variable. 8380 8381 :term:`TARGET_AS_ARCH` 8382 Specifies architecture-specific assembler flags for the target 8383 system. :term:`TARGET_AS_ARCH` is initialized from 8384 :term:`TUNE_ASARGS` by default in the BitBake 8385 configuration file (``meta/conf/bitbake.conf``):: 8386 8387 TARGET_AS_ARCH = "${TUNE_ASARGS}" 8388 8389 :term:`TARGET_CC_ARCH` 8390 Specifies architecture-specific C compiler flags for the target 8391 system. :term:`TARGET_CC_ARCH` is initialized from 8392 :term:`TUNE_CCARGS` by default. 8393 8394 .. note:: 8395 8396 It is a common workaround to append :term:`LDFLAGS` to 8397 :term:`TARGET_CC_ARCH` in recipes that build software for the target that 8398 would not otherwise respect the exported :term:`LDFLAGS` variable. 8399 8400 :term:`TARGET_CC_KERNEL_ARCH` 8401 This is a specific kernel compiler flag for a CPU or Application 8402 Binary Interface (ABI) tune. The flag is used rarely and only for 8403 cases where a userspace :term:`TUNE_CCARGS` is not 8404 compatible with the kernel compilation. The :term:`TARGET_CC_KERNEL_ARCH` 8405 variable allows the kernel (and associated modules) to use a 8406 different configuration. See the 8407 ``meta/conf/machine/include/arm/feature-arm-thumb.inc`` file in the 8408 :term:`Source Directory` for an example. 8409 8410 :term:`TARGET_CFLAGS` 8411 Specifies the flags to pass to the C compiler when building for the 8412 target. When building in the target context, 8413 :term:`CFLAGS` is set to the value of this variable by 8414 default. 8415 8416 Additionally, the SDK's environment setup script sets the :term:`CFLAGS` 8417 variable in the environment to the :term:`TARGET_CFLAGS` value so that 8418 executables built using the SDK also have the flags applied. 8419 8420 :term:`TARGET_CPPFLAGS` 8421 Specifies the flags to pass to the C pre-processor (i.e. to both the 8422 C and the C++ compilers) when building for the target. When building 8423 in the target context, :term:`CPPFLAGS` is set to the 8424 value of this variable by default. 8425 8426 Additionally, the SDK's environment setup script sets the 8427 :term:`CPPFLAGS` variable in the environment to the :term:`TARGET_CPPFLAGS` 8428 value so that executables built using the SDK also have the flags 8429 applied. 8430 8431 :term:`TARGET_CXXFLAGS` 8432 Specifies the flags to pass to the C++ compiler when building for the 8433 target. When building in the target context, 8434 :term:`CXXFLAGS` is set to the value of this variable 8435 by default. 8436 8437 Additionally, the SDK's environment setup script sets the 8438 :term:`CXXFLAGS` variable in the environment to the :term:`TARGET_CXXFLAGS` 8439 value so that executables built using the SDK also have the flags 8440 applied. 8441 8442 :term:`TARGET_FPU` 8443 Specifies the method for handling FPU code. For FPU-less targets, 8444 which include most ARM CPUs, the variable must be set to "soft". If 8445 not, the kernel emulation gets used, which results in a performance 8446 penalty. 8447 8448 :term:`TARGET_LD_ARCH` 8449 Specifies architecture-specific linker flags for the target system. 8450 :term:`TARGET_LD_ARCH` is initialized from 8451 :term:`TUNE_LDARGS` by default in the BitBake 8452 configuration file (``meta/conf/bitbake.conf``):: 8453 8454 TARGET_LD_ARCH = "${TUNE_LDARGS}" 8455 8456 :term:`TARGET_LDFLAGS` 8457 Specifies the flags to pass to the linker when building for the 8458 target. When building in the target context, 8459 :term:`LDFLAGS` is set to the value of this variable 8460 by default. 8461 8462 Additionally, the SDK's environment setup script sets the 8463 :term:`LDFLAGS` variable in the environment to the 8464 :term:`TARGET_LDFLAGS` value so that executables built using the SDK also 8465 have the flags applied. 8466 8467 :term:`TARGET_OS` 8468 Specifies the target's operating system. The variable can be set to 8469 "linux" for glibc-based systems (GNU C Library) and to "linux-musl" 8470 for musl libc. For ARM/EABI targets, the possible values are 8471 "linux-gnueabi" and "linux-musleabi". 8472 8473 :term:`TARGET_PREFIX` 8474 Specifies the prefix used for the toolchain binary target tools. 8475 8476 Depending on the type of recipe and the build target, 8477 :term:`TARGET_PREFIX` is set as follows: 8478 8479 - For recipes building for the target machine, the value is 8480 "${:term:`TARGET_SYS`}-". 8481 8482 - For native recipes, the build system sets the variable to the 8483 value of :term:`BUILD_PREFIX`. 8484 8485 - For native SDK recipes (:ref:`ref-classes-nativesdk`), 8486 the build system sets the variable to the value of :term:`SDK_PREFIX`. 8487 8488 :term:`TARGET_SYS` 8489 Specifies the system, including the architecture and the operating 8490 system, for which the build is occurring in the context of the 8491 current recipe. 8492 8493 The OpenEmbedded build system automatically sets this variable based 8494 on :term:`TARGET_ARCH`, 8495 :term:`TARGET_VENDOR`, and 8496 :term:`TARGET_OS` variables. 8497 8498 .. note:: 8499 8500 You do not need to set the :term:`TARGET_SYS` variable yourself. 8501 8502 Consider these two examples: 8503 8504 - Given a native recipe on a 32-bit, x86 machine running Linux, the 8505 value is "i686-linux". 8506 8507 - Given a recipe being built for a little-endian, MIPS target 8508 running Linux, the value might be "mipsel-linux". 8509 8510 :term:`TARGET_VENDOR` 8511 Specifies the name of the target vendor. 8512 8513 :term:`TCLIBC` 8514 Specifies the GNU standard C library (``libc``) variant to use during 8515 the build process. 8516 8517 You can select "glibc", "musl", "newlib", or "baremetal". 8518 8519 :term:`TCLIBCAPPEND` 8520 Specifies a suffix to be appended onto the :term:`TMPDIR` value. The 8521 suffix identifies the ``libc`` variant for building. When you are 8522 building for multiple variants with the same :term:`Build Directory`, 8523 this mechanism ensures that output for different ``libc`` variants is 8524 kept separate to avoid potential conflicts. 8525 8526 In the ``defaultsetup.conf`` file, the default value of 8527 :term:`TCLIBCAPPEND` is "-${TCLIBC}". However, distros such as poky, 8528 which normally only support one ``libc`` variant, set 8529 :term:`TCLIBCAPPEND` to "" in their distro configuration file resulting 8530 in no suffix being applied. 8531 8532 :term:`TCMODE` 8533 Specifies the toolchain selector. :term:`TCMODE` controls the 8534 characteristics of the generated packages and images by telling the 8535 OpenEmbedded build system which toolchain profile to use. By default, 8536 the OpenEmbedded build system builds its own internal toolchain. The 8537 variable's default value is "default", which uses that internal 8538 toolchain. 8539 8540 .. note:: 8541 8542 If :term:`TCMODE` is set to a value other than "default", then it is your 8543 responsibility to ensure that the toolchain is compatible with the 8544 default toolchain. Using older or newer versions of these 8545 components might cause build problems. See 8546 :doc:`Release Information </migration-guides/index>` for your 8547 version of the Yocto Project, to find the specific components with 8548 which the toolchain must be compatible. 8549 8550 The :term:`TCMODE` variable is similar to :term:`TCLIBC`, 8551 which controls the variant of the GNU standard C library (``libc``) 8552 used during the build process: ``glibc`` or ``musl``. 8553 8554 With additional layers, it is possible to use a pre-compiled external 8555 toolchain. One example is the Sourcery G++ Toolchain. The support for 8556 this toolchain resides in the separate Mentor Graphics 8557 ``meta-sourcery`` layer at 8558 https://github.com/MentorEmbedded/meta-sourcery/. 8559 8560 The layer's ``README`` file contains information on how to use the 8561 Sourcery G++ Toolchain as an external toolchain. You will have to 8562 add the layer to your ``bblayers.conf`` file and then set the 8563 :term:`EXTERNAL_TOOLCHAIN` variable in your ``local.conf`` file to 8564 the location of the toolchain. 8565 8566 The fundamentals used for this example apply to any external 8567 toolchain. You can use ``meta-sourcery`` as a template for adding 8568 support for other external toolchains. 8569 8570 In addition to toolchain configuration, you will also need a 8571 corresponding toolchain recipe file. This recipe file needs to package 8572 up any pre-built objects in the toolchain such as ``libgcc``, 8573 ``libstdcc++``, any locales, and ``libc``. 8574 8575 :term:`TC_CXX_RUNTIME` 8576 Specifies the C/C++ STL and runtime variant to use during 8577 the build process. Default value is 'gnu' 8578 8579 You can select "gnu", "llvm", or "android". 8580 8581 :term:`TEMPLATECONF` 8582 Specifies the directory used by the build system to find templates 8583 from which to build the ``bblayers.conf`` and ``local.conf`` files. 8584 Use this variable if you wish to customize such files, and the default 8585 BitBake targets shown when sourcing the ``oe-init-build-env`` script. 8586 8587 For details, see the 8588 :ref:`dev-manual/custom-template-configuration-directory:creating a custom template configuration directory` 8589 section in the Yocto Project Development Tasks manual. 8590 8591 .. note:: 8592 8593 You must set this variable in the external environment in order 8594 for it to work. 8595 8596 :term:`TEST_EXPORT_DIR` 8597 The location the OpenEmbedded build system uses to export tests when 8598 the :term:`TEST_EXPORT_ONLY` variable is set 8599 to "1". 8600 8601 The :term:`TEST_EXPORT_DIR` variable defaults to 8602 ``"${TMPDIR}/testimage/${PN}"``. 8603 8604 :term:`TEST_EXPORT_ONLY` 8605 Specifies to export the tests only. Set this variable to "1" if you 8606 do not want to run the tests but you want them to be exported in a 8607 manner that you to run them outside of the build system. 8608 8609 :term:`TEST_LOG_DIR` 8610 Holds the SSH log and the boot log for QEMU machines. The 8611 :term:`TEST_LOG_DIR` variable defaults to ``"${WORKDIR}/testimage"``. 8612 8613 .. note:: 8614 8615 Actual test results reside in the task log (``log.do_testimage``), 8616 which is in the ``${WORKDIR}/temp/`` directory. 8617 8618 :term:`TEST_POWERCONTROL_CMD` 8619 For automated hardware testing, specifies the command to use to 8620 control the power of the target machine under test. Typically, this 8621 command would point to a script that performs the appropriate action 8622 (e.g. interacting with a web-enabled power strip). The specified 8623 command should expect to receive as the last argument "off", "on" or 8624 "cycle" specifying to power off, on, or cycle (power off and then 8625 power on) the device, respectively. 8626 8627 :term:`TEST_POWERCONTROL_EXTRA_ARGS` 8628 For automated hardware testing, specifies additional arguments to 8629 pass through to the command specified in 8630 :term:`TEST_POWERCONTROL_CMD`. Setting 8631 :term:`TEST_POWERCONTROL_EXTRA_ARGS` is optional. You can use it if you 8632 wish, for example, to separate the machine-specific and 8633 non-machine-specific parts of the arguments. 8634 8635 :term:`TEST_QEMUBOOT_TIMEOUT` 8636 The time in seconds allowed for an image to boot before automated 8637 runtime tests begin to run against an image. The default timeout 8638 period to allow the boot process to reach the login prompt is 500 8639 seconds. You can specify a different value in the ``local.conf`` 8640 file. 8641 8642 For more information on testing images, see the 8643 ":ref:`dev-manual/runtime-testing:performing automated runtime testing`" 8644 section in the Yocto Project Development Tasks Manual. 8645 8646 :term:`TEST_SERIALCONTROL_CMD` 8647 For automated hardware testing, specifies the command to use to 8648 connect to the serial console of the target machine under test. This 8649 command simply needs to connect to the serial console and forward 8650 that connection to standard input and output as any normal terminal 8651 program does. 8652 8653 For example, to use the Picocom terminal program on serial device 8654 ``/dev/ttyUSB0`` at 115200bps, you would set the variable as follows:: 8655 8656 TEST_SERIALCONTROL_CMD = "picocom /dev/ttyUSB0 -b 115200" 8657 8658 :term:`TEST_SERIALCONTROL_EXTRA_ARGS` 8659 For automated hardware testing, specifies additional arguments to 8660 pass through to the command specified in 8661 :term:`TEST_SERIALCONTROL_CMD`. Setting 8662 :term:`TEST_SERIALCONTROL_EXTRA_ARGS` is optional. You can use it if you 8663 wish, for example, to separate the machine-specific and 8664 non-machine-specific parts of the command. 8665 8666 :term:`TEST_SERVER_IP` 8667 The IP address of the build machine (host machine). This IP address 8668 is usually automatically detected. However, if detection fails, this 8669 variable needs to be set to the IP address of the build machine (i.e. 8670 where the build is taking place). 8671 8672 .. note:: 8673 8674 The :term:`TEST_SERVER_IP` variable is only used for a small number of 8675 tests such as the "dnf" test suite, which needs to download packages 8676 from ``WORKDIR/oe-rootfs-repo``. 8677 8678 :term:`TEST_SUITES` 8679 An ordered list of tests (modules) to run against an image when 8680 performing automated runtime testing. 8681 8682 The OpenEmbedded build system provides a core set of tests that can 8683 be used against images. 8684 8685 .. note:: 8686 8687 Currently, there is only support for running these tests under 8688 QEMU. 8689 8690 Tests include ``ping``, ``ssh``, ``df`` among others. You can add 8691 your own tests to the list of tests by appending :term:`TEST_SUITES` as 8692 follows:: 8693 8694 TEST_SUITES:append = " mytest" 8695 8696 Alternatively, you can 8697 provide the "auto" option to have all applicable tests run against 8698 the image:: 8699 8700 TEST_SUITES:append = " auto" 8701 8702 Using this option causes the 8703 build system to automatically run tests that are applicable to the 8704 image. Tests that are not applicable are skipped. 8705 8706 The order in which tests are run is important. Tests that depend on 8707 another test must appear later in the list than the test on which 8708 they depend. For example, if you append the list of tests with two 8709 tests (``test_A`` and ``test_B``) where ``test_B`` is dependent on 8710 ``test_A``, then you must order the tests as follows:: 8711 8712 TEST_SUITES = "test_A test_B" 8713 8714 For more information on testing images, see the 8715 ":ref:`dev-manual/runtime-testing:performing automated runtime testing`" 8716 section in the Yocto Project Development Tasks Manual. 8717 8718 :term:`TEST_TARGET` 8719 Specifies the target controller to use when running tests against a 8720 test image. The default controller to use is "qemu":: 8721 8722 TEST_TARGET = "qemu" 8723 8724 A target controller is a class that defines how an image gets 8725 deployed on a target and how a target is started. A layer can extend 8726 the controllers by adding a module in the layer's 8727 ``/lib/oeqa/controllers`` directory and by inheriting the 8728 ``BaseTarget`` class, which is an abstract class that cannot be used 8729 as a value of :term:`TEST_TARGET`. 8730 8731 You can provide the following arguments with :term:`TEST_TARGET`: 8732 8733 - *"qemu":* Boots a QEMU image and runs the tests. See the 8734 ":ref:`dev-manual/runtime-testing:enabling runtime tests on qemu`" section 8735 in the Yocto Project Development Tasks Manual for more 8736 information. 8737 8738 - *"simpleremote":* Runs the tests on target hardware that is 8739 already up and running. The hardware can be on the network or it 8740 can be a device running an image on QEMU. You must also set 8741 :term:`TEST_TARGET_IP` when you use 8742 "simpleremote". 8743 8744 .. note:: 8745 8746 This argument is defined in 8747 ``meta/lib/oeqa/controllers/simpleremote.py``. 8748 8749 For information on running tests on hardware, see the 8750 ":ref:`dev-manual/runtime-testing:enabling runtime tests on hardware`" 8751 section in the Yocto Project Development Tasks Manual. 8752 8753 :term:`TEST_TARGET_IP` 8754 The IP address of your hardware under test. The :term:`TEST_TARGET_IP` 8755 variable has no effect when :term:`TEST_TARGET` is 8756 set to "qemu". 8757 8758 When you specify the IP address, you can also include a port. Here is 8759 an example:: 8760 8761 TEST_TARGET_IP = "192.168.1.4:2201" 8762 8763 Specifying a port is 8764 useful when SSH is started on a non-standard port or in cases when 8765 your hardware under test is behind a firewall or network that is not 8766 directly accessible from your host and you need to do port address 8767 translation. 8768 8769 :term:`TESTIMAGE_AUTO` 8770 Automatically runs the series of automated tests for images when an 8771 image is successfully built. Setting :term:`TESTIMAGE_AUTO` to "1" causes 8772 any image that successfully builds to automatically boot under QEMU. 8773 Using the variable also adds in dependencies so that any SDK for 8774 which testing is requested is automatically built first. 8775 8776 These tests are written in Python making use of the ``unittest`` 8777 module, and the majority of them run commands on the target system 8778 over ``ssh``. You can set this variable to "1" in your ``local.conf`` 8779 file in the :term:`Build Directory` to have the 8780 OpenEmbedded build system automatically run these tests after an 8781 image successfully builds: 8782 8783 TESTIMAGE_AUTO = "1" 8784 8785 For more information 8786 on enabling, running, and writing these tests, see the 8787 ":ref:`dev-manual/runtime-testing:performing automated runtime testing`" 8788 section in the Yocto Project Development Tasks Manual and the 8789 ":ref:`ref-classes-testimage`" section. 8790 8791 :term:`THISDIR` 8792 The directory in which the file BitBake is currently parsing is 8793 located. Do not manually set this variable. 8794 8795 :term:`TIME` 8796 The time the build was started. Times appear using the hour, minute, 8797 and second (HMS) format (e.g. "140159" for one minute and fifty-nine 8798 seconds past 1400 hours). 8799 8800 :term:`TMPDIR` 8801 This variable is the base directory the OpenEmbedded build system 8802 uses for all build output and intermediate files (other than the 8803 shared state cache). By default, the :term:`TMPDIR` variable points to 8804 ``tmp`` within the :term:`Build Directory`. 8805 8806 If you want to establish this directory in a location other than the 8807 default, you can uncomment and edit the following statement in the 8808 ``conf/local.conf`` file in the :term:`Source Directory`:: 8809 8810 #TMPDIR = "${TOPDIR}/tmp" 8811 8812 An example use for this scenario is to set :term:`TMPDIR` to a local disk, 8813 which does not use NFS, while having the :term:`Build Directory` use NFS. 8814 8815 The filesystem used by :term:`TMPDIR` must have standard filesystem 8816 semantics (i.e. mixed-case files are unique, POSIX file locking, and 8817 persistent inodes). Due to various issues with NFS and bugs in some 8818 implementations, NFS does not meet this minimum requirement. 8819 Consequently, :term:`TMPDIR` cannot be on NFS. 8820 8821 :term:`TOOLCHAIN_HOST_TASK` 8822 This variable lists packages the OpenEmbedded build system uses when 8823 building an SDK, which contains a cross-development environment. The 8824 packages specified by this variable are part of the toolchain set 8825 that runs on the :term:`SDKMACHINE`, and each 8826 package should usually have the prefix ``nativesdk-``. For example, 8827 consider the following command when building an SDK:: 8828 8829 $ bitbake -c populate_sdk imagename 8830 8831 In this case, a default list of packages is 8832 set in this variable, but you can add additional packages to the 8833 list. See the 8834 ":ref:`sdk-manual/appendix-customizing-standard:adding individual packages to the standard sdk`" section 8835 in the Yocto Project Application Development and the Extensible 8836 Software Development Kit (eSDK) manual for more information. 8837 8838 For background information on cross-development toolchains in the 8839 Yocto Project development environment, see the 8840 ":ref:`sdk-manual/intro:the cross-development toolchain`" 8841 section in the Yocto Project Overview and Concepts Manual. For 8842 information on setting up a cross-development environment, see the 8843 :doc:`/sdk-manual/index` manual. 8844 8845 Note that this variable applies to building an SDK, not an eSDK, 8846 in which case the :term:`TOOLCHAIN_HOST_TASK_ESDK` setting should be 8847 used instead. 8848 8849 :term:`TOOLCHAIN_HOST_TASK_ESDK` 8850 This variable allows to extend what is installed in the host 8851 portion of an eSDK. This is similar to :term:`TOOLCHAIN_HOST_TASK` 8852 applying to SDKs. 8853 8854 :term:`TOOLCHAIN_OUTPUTNAME` 8855 This variable defines the name used for the toolchain output. The 8856 :ref:`populate_sdk_base <ref-classes-populate-sdk-*>` class sets 8857 the :term:`TOOLCHAIN_OUTPUTNAME` variable as follows:: 8858 8859 TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-toolchain-${SDK_VERSION}" 8860 8861 See 8862 the :term:`SDK_NAME` and 8863 :term:`SDK_VERSION` variables for additional 8864 information. 8865 8866 :term:`TOOLCHAIN_TARGET_TASK` 8867 This variable lists packages the OpenEmbedded build system uses when 8868 it creates the target part of an SDK (i.e. the part built for the 8869 target hardware), which includes libraries and headers. Use this 8870 variable to add individual packages to the part of the SDK that runs 8871 on the target. See the 8872 ":ref:`sdk-manual/appendix-customizing-standard:adding individual packages to the standard sdk`" section 8873 in the Yocto Project Application Development and the Extensible 8874 Software Development Kit (eSDK) manual for more information. 8875 8876 For background information on cross-development toolchains in the 8877 Yocto Project development environment, see the 8878 ":ref:`sdk-manual/intro:the cross-development toolchain`" 8879 section in the Yocto Project Overview and Concepts Manual. For 8880 information on setting up a cross-development environment, see the 8881 :doc:`/sdk-manual/index` manual. 8882 8883 :term:`TOPDIR` 8884 See :term:`bitbake:TOPDIR` in the BitBake manual. 8885 8886 :term:`TRANSLATED_TARGET_ARCH` 8887 A sanitized version of :term:`TARGET_ARCH`. This 8888 variable is used where the architecture is needed in a value where 8889 underscores are not allowed, for example within package filenames. In 8890 this case, dash characters replace any underscore characters used in 8891 :term:`TARGET_ARCH`. 8892 8893 Do not edit this variable. 8894 8895 :term:`TUNE_ARCH` 8896 The GNU canonical architecture for a specific architecture (i.e. 8897 ``arm``, ``armeb``, ``mips``, ``mips64``, and so forth). BitBake uses 8898 this value to setup configuration. 8899 8900 :term:`TUNE_ARCH` definitions are specific to a given architecture. The 8901 definitions can be a single static definition, or can be dynamically 8902 adjusted. You can see details for a given CPU family by looking at 8903 the architecture's ``README`` file. For example, the 8904 ``meta/conf/machine/include/mips/README`` file in the 8905 :term:`Source Directory` provides information for 8906 :term:`TUNE_ARCH` specific to the ``mips`` architecture. 8907 8908 :term:`TUNE_ARCH` is tied closely to 8909 :term:`TARGET_ARCH`, which defines the target 8910 machine's architecture. The BitBake configuration file 8911 (``meta/conf/bitbake.conf``) sets :term:`TARGET_ARCH` as follows:: 8912 8913 TARGET_ARCH = "${TUNE_ARCH}" 8914 8915 The following list, which is by no means complete since architectures 8916 are configurable, shows supported machine architectures: 8917 8918 - arm 8919 - i586 8920 - x86_64 8921 - powerpc 8922 - powerpc64 8923 - mips 8924 - mipsel 8925 8926 :term:`TUNE_ASARGS` 8927 Specifies architecture-specific assembler flags for the target 8928 system. The set of flags is based on the selected tune features. 8929 :term:`TUNE_ASARGS` is set using the tune include files, which are 8930 typically under ``meta/conf/machine/include/`` and are influenced 8931 through :term:`TUNE_FEATURES`. For example, the 8932 ``meta/conf/machine/include/x86/arch-x86.inc`` file defines the flags 8933 for the x86 architecture as follows:: 8934 8935 TUNE_ASARGS += "${@bb.utils.contains("TUNE_FEATURES", "mx32", "-x32", "", d)}" 8936 8937 .. note:: 8938 8939 Board Support Packages (BSPs) select the tune. The selected tune, 8940 in turn, affects the tune variables themselves (i.e. the tune can 8941 supply its own set of flags). 8942 8943 :term:`TUNE_CCARGS` 8944 Specifies architecture-specific C compiler flags for the target 8945 system. The set of flags is based on the selected tune features. 8946 :term:`TUNE_CCARGS` is set using the tune include files, which are 8947 typically under ``meta/conf/machine/include/`` and are influenced 8948 through :term:`TUNE_FEATURES`. 8949 8950 .. note:: 8951 8952 Board Support Packages (BSPs) select the tune. The selected tune, 8953 in turn, affects the tune variables themselves (i.e. the tune can 8954 supply its own set of flags). 8955 8956 :term:`TUNE_FEATURES` 8957 Features used to "tune" a compiler for optimal use given a specific 8958 processor. The features are defined within the tune files and allow 8959 arguments (i.e. ``TUNE_*ARGS``) to be dynamically generated based on 8960 the features. 8961 8962 The OpenEmbedded build system verifies the features to be sure they 8963 are not conflicting and that they are supported. 8964 8965 The BitBake configuration file (``meta/conf/bitbake.conf``) defines 8966 :term:`TUNE_FEATURES` as follows:: 8967 8968 TUNE_FEATURES ??= "${TUNE_FEATURES:tune-${DEFAULTTUNE}}" 8969 8970 See the :term:`DEFAULTTUNE` variable for more information. 8971 8972 :term:`TUNE_LDARGS` 8973 Specifies architecture-specific linker flags for the target system. 8974 The set of flags is based on the selected tune features. 8975 :term:`TUNE_LDARGS` is set using the tune include files, which are 8976 typically under ``meta/conf/machine/include/`` and are influenced 8977 through :term:`TUNE_FEATURES`. For example, the 8978 ``meta/conf/machine/include/x86/arch-x86.inc`` file defines the flags 8979 for the x86 architecture as follows:: 8980 8981 TUNE_LDARGS += "${@bb.utils.contains("TUNE_FEATURES", "mx32", "-m elf32_x86_64", "", d)}" 8982 8983 .. note:: 8984 8985 Board Support Packages (BSPs) select the tune. The selected tune, 8986 in turn, affects the tune variables themselves (i.e. the tune can 8987 supply its own set of flags). 8988 8989 :term:`TUNE_PKGARCH` 8990 The package architecture understood by the packaging system to define 8991 the architecture, ABI, and tuning of output packages. The specific 8992 tune is defined using the "_tune" override as follows:: 8993 8994 TUNE_PKGARCH:tune-tune = "tune" 8995 8996 These tune-specific package architectures are defined in the machine 8997 include files. Here is an example of the "core2-32" tuning as used in 8998 the ``meta/conf/machine/include/x86/tune-core2.inc`` file:: 8999 9000 TUNE_PKGARCH:tune-core2-32 = "core2-32" 9001 9002 :term:`TUNECONFLICTS[feature]` 9003 Specifies CPU or Application Binary Interface (ABI) tuning features 9004 that conflict with feature. 9005 9006 Known tuning conflicts are specified in the machine include files in 9007 the :term:`Source Directory`. Here is an example from 9008 the ``meta/conf/machine/include/mips/arch-mips.inc`` include file 9009 that lists the "o32" and "n64" features as conflicting with the "n32" 9010 feature:: 9011 9012 TUNECONFLICTS[n32] = "o32 n64" 9013 9014 :term:`TUNEVALID[feature]` 9015 Specifies a valid CPU or Application Binary Interface (ABI) tuning 9016 feature. The specified feature is stored as a flag. Valid features 9017 are specified in the machine include files (e.g. 9018 ``meta/conf/machine/include/arm/arch-arm.inc``). Here is an example 9019 from that file:: 9020 9021 TUNEVALID[bigendian] = "Enable big-endian mode." 9022 9023 See the machine include files in the :term:`Source Directory` 9024 for these features. 9025 9026 :term:`UBOOT_CONFIG` 9027 Configures the :term:`UBOOT_MACHINE` and can 9028 also define :term:`IMAGE_FSTYPES` for individual 9029 cases. 9030 9031 Following is an example from the ``meta-fsl-arm`` layer. :: 9032 9033 UBOOT_CONFIG ??= "sd" 9034 UBOOT_CONFIG[sd] = "mx6qsabreauto_config,sdcard" 9035 UBOOT_CONFIG[eimnor] = "mx6qsabreauto_eimnor_config" 9036 UBOOT_CONFIG[nand] = "mx6qsabreauto_nand_config,ubifs" 9037 UBOOT_CONFIG[spinor] = "mx6qsabreauto_spinor_config" 9038 9039 In this example, "sd" is selected as the configuration of the possible four for the 9040 :term:`UBOOT_MACHINE`. The "sd" configuration defines 9041 "mx6qsabreauto_config" as the value for :term:`UBOOT_MACHINE`, while the 9042 "sdcard" specifies the :term:`IMAGE_FSTYPES` to use for the U-Boot image. 9043 9044 For more information on how the :term:`UBOOT_CONFIG` is handled, see the 9045 :ref:`ref-classes-uboot-config` class. 9046 9047 :term:`UBOOT_DTB_LOADADDRESS` 9048 Specifies the load address for the dtb image used by U-Boot. During FIT 9049 image creation, the :term:`UBOOT_DTB_LOADADDRESS` variable is used in 9050 :ref:`ref-classes-kernel-fitimage` class to specify the load address to be 9051 used in creating the dtb sections of Image Tree Source for the FIT image. 9052 9053 :term:`UBOOT_DTBO_LOADADDRESS` 9054 Specifies the load address for the dtbo image used by U-Boot. During FIT 9055 image creation, the :term:`UBOOT_DTBO_LOADADDRESS` variable is used in 9056 :ref:`ref-classes-kernel-fitimage` class to specify the load address to be 9057 used in creating the dtbo sections of Image Tree Source for the FIT image. 9058 9059 :term:`UBOOT_ENTRYPOINT` 9060 Specifies the entry point for the U-Boot image. During U-Boot image 9061 creation, the :term:`UBOOT_ENTRYPOINT` variable is passed as a 9062 command-line parameter to the ``uboot-mkimage`` utility. 9063 9064 To pass a 64 bit address for FIT image creation, you will need to set 9065 the :term:`FIT_ADDRESS_CELLS` variable too. 9066 9067 :term:`UBOOT_LOADADDRESS` 9068 Specifies the load address for the U-Boot image. During U-Boot image 9069 creation, the :term:`UBOOT_LOADADDRESS` variable is passed as a 9070 command-line parameter to the ``uboot-mkimage`` utility. 9071 9072 To pass a 64 bit address for FIT image creation, you will need to set 9073 the :term:`FIT_ADDRESS_CELLS` variable too. 9074 9075 :term:`UBOOT_LOCALVERSION` 9076 Appends a string to the name of the local version of the U-Boot 9077 image. For example, assuming the version of the U-Boot image built 9078 was "2013.10", the full version string reported by U-Boot would be 9079 "2013.10-yocto" given the following statement:: 9080 9081 UBOOT_LOCALVERSION = "-yocto" 9082 9083 :term:`UBOOT_MACHINE` 9084 Specifies the value passed on the ``make`` command line when building 9085 a U-Boot image. The value indicates the target platform 9086 configuration. You typically set this variable from the machine 9087 configuration file (i.e. ``conf/machine/machine_name.conf``). 9088 9089 Please see the "Selection of Processor Architecture and Board Type" 9090 section in the U-Boot README for valid values for this variable. 9091 9092 :term:`UBOOT_MAKE_TARGET` 9093 Specifies the target called in the ``Makefile``. The default target 9094 is "all". 9095 9096 :term:`UBOOT_MKIMAGE` 9097 Specifies the name of the mkimage command as used by the 9098 :ref:`ref-classes-kernel-fitimage` class to assemble 9099 the FIT image. This can be used to substitute an alternative command, wrapper 9100 script or function if desired. The default is "uboot-mkimage". 9101 9102 :term:`UBOOT_MKIMAGE_DTCOPTS` 9103 Options for the device tree compiler passed to mkimage '-D' feature while 9104 creating FIT image in :ref:`ref-classes-kernel-fitimage` class. If 9105 :term:`UBOOT_MKIMAGE_DTCOPTS` is not set then 9106 :ref:`ref-classes-kernel-fitimage` will not pass the ``-D`` option to 9107 mkimage. 9108 9109 :term:`UBOOT_MKIMAGE_KERNEL_TYPE` 9110 Specifies the type argument for the kernel as passed to ``uboot-mkimage``. 9111 The default value is "kernel". 9112 9113 :term:`UBOOT_MKIMAGE_SIGN` 9114 Specifies the name of the mkimage command as used by the 9115 :ref:`ref-classes-kernel-fitimage` class to sign 9116 the FIT image after it has been assembled (if enabled). This can be used 9117 to substitute an alternative command, wrapper script or function if 9118 desired. The default is "${:term:`UBOOT_MKIMAGE`}". 9119 9120 :term:`UBOOT_MKIMAGE_SIGN_ARGS` 9121 Optionally specifies additional arguments for the 9122 :ref:`ref-classes-kernel-fitimage` class to pass to the 9123 mkimage command when signing the FIT image. 9124 9125 :term:`UBOOT_RD_ENTRYPOINT` 9126 Specifies the entrypoint for the RAM disk image. During FIT image 9127 creation, the :term:`UBOOT_RD_ENTRYPOINT` variable is used in 9128 :ref:`ref-classes-kernel-fitimage` class to specify the entrypoint to be 9129 used in creating the Image Tree Source for the FIT image. 9130 9131 :term:`UBOOT_RD_LOADADDRESS` 9132 Specifies the load address for the RAM disk image. During FIT image 9133 creation, the :term:`UBOOT_RD_LOADADDRESS` variable is used in 9134 :ref:`ref-classes-kernel-fitimage` class to specify the load address to 9135 be used in creating the Image Tree Source for the FIT image. 9136 9137 :term:`UBOOT_SIGN_ENABLE` 9138 Enable signing of FIT image. The default value is "0". 9139 9140 :term:`UBOOT_SIGN_KEYDIR` 9141 Location of the directory containing the RSA key and 9142 certificate used for signing FIT image. 9143 9144 :term:`UBOOT_SIGN_KEYNAME` 9145 The name of keys used for signing U-Boot FIT image stored in 9146 :term:`UBOOT_SIGN_KEYDIR` directory. For e.g. dev.key key and dev.crt 9147 certificate stored in :term:`UBOOT_SIGN_KEYDIR` directory will have 9148 :term:`UBOOT_SIGN_KEYNAME` set to "dev". 9149 9150 :term:`UBOOT_SUFFIX` 9151 Points to the generated U-Boot extension. For example, ``u-boot.sb`` 9152 has a ``.sb`` extension. 9153 9154 The default U-Boot extension is ``.bin`` 9155 9156 :term:`UBOOT_TARGET` 9157 Specifies the target used for building U-Boot. The target is passed 9158 directly as part of the "make" command (e.g. SPL and AIS). If you do 9159 not specifically set this variable, the OpenEmbedded build process 9160 passes and uses "all" for the target during the U-Boot building 9161 process. 9162 9163 :term:`UNKNOWN_CONFIGURE_OPT_IGNORE` 9164 Specifies a list of options that, if reported by the configure script 9165 as being invalid, should not generate a warning during the 9166 :ref:`ref-tasks-configure` task. Normally, invalid 9167 configure options are simply not passed to the configure script (e.g. 9168 should be removed from :term:`EXTRA_OECONF` or 9169 :term:`PACKAGECONFIG_CONFARGS`). 9170 However, there are common options that are passed to all 9171 configure scripts at a class level, but might not be valid for some 9172 configure scripts. Therefore warnings about these options are useless. 9173 For these cases, the options are added to :term:`UNKNOWN_CONFIGURE_OPT_IGNORE`. 9174 9175 The configure arguments check that uses 9176 :term:`UNKNOWN_CONFIGURE_OPT_IGNORE` is part of the 9177 :ref:`ref-classes-insane` class and is only enabled if the 9178 recipe inherits the :ref:`ref-classes-autotools` class. 9179 9180 :term:`UPDATERCPN` 9181 For recipes inheriting the 9182 :ref:`ref-classes-update-rc.d` class, :term:`UPDATERCPN` 9183 specifies the package that contains the initscript that is enabled. 9184 9185 The default value is "${PN}". Given that almost all recipes that 9186 install initscripts package them in the main package for the recipe, 9187 you rarely need to set this variable in individual recipes. 9188 9189 :term:`UPSTREAM_CHECK_COMMITS` 9190 You can perform a per-recipe check for what the latest upstream 9191 source code version is by calling ``devtool latest-version recipe``. If 9192 the recipe source code is provided from Git repositories, but 9193 releases are not identified by Git tags, set :term:`UPSTREAM_CHECK_COMMITS` 9194 to ``1`` in the recipe, and the OpenEmbedded build system 9195 will compare the latest commit with the one currently specified 9196 by the recipe (:term:`SRCREV`):: 9197 9198 UPSTREAM_CHECK_COMMITS = "1" 9199 9200 :term:`UPSTREAM_CHECK_GITTAGREGEX` 9201 You can perform a per-recipe check for what the latest upstream 9202 source code version is by calling ``devtool latest-version recipe``. If 9203 the recipe source code is provided from Git repositories, the 9204 OpenEmbedded build system determines the latest upstream version by 9205 picking the latest tag from the list of all repository tags. 9206 9207 You can use the :term:`UPSTREAM_CHECK_GITTAGREGEX` variable to provide a 9208 regular expression to filter only the relevant tags should the 9209 default filter not work correctly:: 9210 9211 UPSTREAM_CHECK_GITTAGREGEX = "git_tag_regex" 9212 9213 :term:`UPSTREAM_CHECK_REGEX` 9214 Use the :term:`UPSTREAM_CHECK_REGEX` variable to specify a different 9215 regular expression instead of the default one when the package 9216 checking system is parsing the page found using 9217 :term:`UPSTREAM_CHECK_URI`:: 9218 9219 UPSTREAM_CHECK_REGEX = "package_regex" 9220 9221 :term:`UPSTREAM_CHECK_URI` 9222 You can perform a per-recipe check for what the latest upstream 9223 source code version is by calling ``devtool latest-version recipe``. If 9224 the source code is provided from tarballs, the latest version is 9225 determined by fetching the directory listing where the tarball is and 9226 attempting to find a later tarball. When this approach does not work, 9227 you can use :term:`UPSTREAM_CHECK_URI` to provide a different URI that 9228 contains the link to the latest tarball:: 9229 9230 UPSTREAM_CHECK_URI = "recipe_url" 9231 9232 :term:`UPSTREAM_VERSION_UNKNOWN` 9233 You can perform a per-recipe check for what the latest upstream 9234 source code version is by calling ``devtool latest-version recipe``. 9235 If no combination of the :term:`UPSTREAM_CHECK_URI`, :term:`UPSTREAM_CHECK_REGEX`, 9236 :term:`UPSTREAM_CHECK_GITTAGREGEX` and :term:`UPSTREAM_CHECK_COMMITS` variables in 9237 the recipe allows to determine what the latest upstream version is, 9238 you can set :term:`UPSTREAM_VERSION_UNKNOWN` to ``1`` in the recipe 9239 to acknowledge that the check cannot be performed:: 9240 9241 UPSTREAM_VERSION_UNKNOWN = "1" 9242 9243 :term:`USE_DEVFS` 9244 Determines if ``devtmpfs`` is used for ``/dev`` population. The 9245 default value used for :term:`USE_DEVFS` is "1" when no value is 9246 specifically set. Typically, you would set :term:`USE_DEVFS` to "0" for a 9247 statically populated ``/dev`` directory. 9248 9249 See the ":ref:`dev-manual/device-manager:selecting a device manager`" section in 9250 the Yocto Project Development Tasks Manual for information on how to 9251 use this variable. 9252 9253 :term:`USE_VT` 9254 When using 9255 :ref:`SysVinit <dev-manual/new-recipe:enabling system services>`, 9256 determines whether or not to run a :wikipedia:`getty <Getty_(Unix)>` 9257 on any virtual terminals in order to enable logging in through those 9258 terminals. 9259 9260 The default value used for :term:`USE_VT` is "1" when no default value is 9261 specifically set. Typically, you would set :term:`USE_VT` to "0" in the 9262 machine configuration file for machines that do not have a graphical 9263 display attached and therefore do not need virtual terminal 9264 functionality. 9265 9266 :term:`USER_CLASSES` 9267 A list of classes to globally inherit. These classes are used by the 9268 OpenEmbedded build system to enable extra features. 9269 9270 Classes inherited using :term:`USER_CLASSES` must be located in the 9271 ``classes-global/`` or ``classes/`` subdirectories. 9272 9273 The default list is set in your ``local.conf`` file:: 9274 9275 USER_CLASSES ?= "buildstats" 9276 9277 For more information, see 9278 ``meta-poky/conf/templates/default/local.conf.sample`` in the 9279 :term:`Source Directory`. 9280 9281 :term:`USERADD_ERROR_DYNAMIC` 9282 If set to ``error``, forces the OpenEmbedded build system to produce 9283 an error if the user identification (``uid``) and group 9284 identification (``gid``) values are not defined in any of the files 9285 listed in :term:`USERADD_UID_TABLES` and 9286 :term:`USERADD_GID_TABLES`. If set to 9287 ``warn``, a warning will be issued instead. 9288 9289 The default behavior for the build system is to dynamically apply 9290 ``uid`` and ``gid`` values. Consequently, the 9291 :term:`USERADD_ERROR_DYNAMIC` variable is by default not set. If you plan 9292 on using statically assigned ``gid`` and ``uid`` values, you should 9293 set the :term:`USERADD_ERROR_DYNAMIC` variable in your ``local.conf`` 9294 file as follows:: 9295 9296 USERADD_ERROR_DYNAMIC = "error" 9297 9298 Overriding the 9299 default behavior implies you are going to also take steps to set 9300 static ``uid`` and ``gid`` values through use of the 9301 :term:`USERADDEXTENSION`, 9302 :term:`USERADD_UID_TABLES`, and 9303 :term:`USERADD_GID_TABLES` variables. 9304 9305 .. note:: 9306 9307 There is a difference in behavior between setting 9308 :term:`USERADD_ERROR_DYNAMIC` to ``error`` and setting it to ``warn``. 9309 When it is set to ``warn``, the build system will report a warning for 9310 every undefined ``uid`` and ``gid`` in any recipe. But when it is set 9311 to ``error``, it will only report errors for recipes that are actually 9312 built. 9313 This saves you from having to add static IDs for recipes that you 9314 know will never be built. 9315 9316 :term:`USERADD_GID_TABLES` 9317 Specifies a password file to use for obtaining static group 9318 identification (``gid``) values when the OpenEmbedded build system 9319 adds a group to the system during package installation. 9320 9321 When applying static group identification (``gid``) values, the 9322 OpenEmbedded build system looks in :term:`BBPATH` for a 9323 ``files/group`` file and then applies those ``uid`` values. Set the 9324 variable as follows in your ``local.conf`` file:: 9325 9326 9327 USERADD_GID_TABLES = "files/group" 9328 9329 .. note:: 9330 9331 Setting the :term:`USERADDEXTENSION` variable to "useradd-staticids" 9332 causes the build system to use static ``gid`` values. 9333 9334 :term:`USERADD_PACKAGES` 9335 When inheriting the :ref:`ref-classes-useradd` class, 9336 this variable specifies the individual packages within the recipe 9337 that require users and/or groups to be added. 9338 9339 You must set this variable if the recipe inherits the class. For 9340 example, the following enables adding a user for the main package in 9341 a recipe:: 9342 9343 USERADD_PACKAGES = "${PN}" 9344 9345 .. note:: 9346 9347 It follows that if you are going to use the :term:`USERADD_PACKAGES` 9348 variable, you need to set one or more of the :term:`USERADD_PARAM`, 9349 :term:`GROUPADD_PARAM`, or :term:`GROUPMEMS_PARAM` variables. 9350 9351 :term:`USERADD_PARAM` 9352 When inheriting the :ref:`ref-classes-useradd` class, 9353 this variable specifies for a package what parameters should pass to 9354 the ``useradd`` command if you add a user to the system when the 9355 package is installed. 9356 9357 Here is an example from the ``dbus`` recipe:: 9358 9359 USERADD_PARAM:${PN} = "--system --home ${localstatedir}/lib/dbus \ 9360 --no-create-home --shell /bin/false \ 9361 --user-group messagebus" 9362 9363 For information on the 9364 standard Linux shell command ``useradd``, see 9365 https://linux.die.net/man/8/useradd. 9366 9367 :term:`USERADD_UID_TABLES` 9368 Specifies a password file to use for obtaining static user 9369 identification (``uid``) values when the OpenEmbedded build system 9370 adds a user to the system during package installation. 9371 9372 When applying static user identification (``uid``) values, the 9373 OpenEmbedded build system looks in :term:`BBPATH` for a 9374 ``files/passwd`` file and then applies those ``uid`` values. Set the 9375 variable as follows in your ``local.conf`` file:: 9376 9377 USERADD_UID_TABLES = "files/passwd" 9378 9379 .. note:: 9380 9381 Setting the :term:`USERADDEXTENSION` variable to "useradd-staticids" 9382 causes the build system to use static ``uid`` values. 9383 9384 :term:`USERADDEXTENSION` 9385 When set to "useradd-staticids", causes the OpenEmbedded build system 9386 to base all user and group additions on a static ``passwd`` and 9387 ``group`` files found in :term:`BBPATH`. 9388 9389 To use static user identification (``uid``) and group identification 9390 (``gid``) values, set the variable as follows in your ``local.conf`` 9391 file: USERADDEXTENSION = "useradd-staticids" 9392 9393 .. note:: 9394 9395 Setting this variable to use static ``uid`` and ``gid`` 9396 values causes the OpenEmbedded build system to employ the 9397 :ref:`ref-classes-useradd` class. 9398 9399 If you use static ``uid`` and ``gid`` information, you must also 9400 specify the ``files/passwd`` and ``files/group`` files by setting the 9401 :term:`USERADD_UID_TABLES` and 9402 :term:`USERADD_GID_TABLES` variables. 9403 Additionally, you should also set the 9404 :term:`USERADD_ERROR_DYNAMIC` variable. 9405 9406 :term:`VOLATILE_LOG_DIR` 9407 Specifies the persistence of the target's ``/var/log`` directory, 9408 which is used to house postinstall target log files. 9409 9410 By default, :term:`VOLATILE_LOG_DIR` is set to "yes", which means the 9411 file is not persistent. You can override this setting by setting the 9412 variable to "no" to make the log directory persistent. 9413 9414 :term:`VOLATILE_TMP_DIR` 9415 Specifies the persistence of the target's ``/tmp`` directory. 9416 9417 By default, :term:`VOLATILE_TMP_DIR` is set to "yes", in which case 9418 ``/tmp`` links to a directory which resides in RAM in a ``tmpfs`` 9419 filesystem. 9420 9421 If instead, you want the ``/tmp`` directory to be persistent, set the 9422 variable to "no" to make it a regular directory in the root filesystem. 9423 9424 This supports both sysvinit and systemd based systems. 9425 9426 :term:`WARN_QA` 9427 Specifies the quality assurance checks whose failures are reported as 9428 warnings by the OpenEmbedded build system. You set this variable in 9429 your distribution configuration file. For a list of the checks you 9430 can control with this variable, see the 9431 ":ref:`ref-classes-insane`" section. 9432 9433 :term:`WATCHDOG_TIMEOUT` 9434 Specifies the timeout in seconds used by the ``watchdog`` recipe and 9435 also by ``systemd`` during reboot. The default is 60 seconds. 9436 9437 :term:`WIRELESS_DAEMON` 9438 For ``connman`` and ``packagegroup-base``, specifies the wireless 9439 daemon to use. The default is "wpa-supplicant" (note that the value 9440 uses a dash and not an underscore). 9441 9442 :term:`WKS_FILE` 9443 Specifies the location of the Wic kickstart file that is used by the 9444 OpenEmbedded build system to create a partitioned image 9445 (``image.wic``). For information on how to create a partitioned 9446 image, see the 9447 ":ref:`dev-manual/wic:creating partitioned images using wic`" 9448 section in the Yocto Project Development Tasks Manual. For details on 9449 the kickstart file format, see the ":doc:`/ref-manual/kickstart`" Chapter. 9450 9451 :term:`WKS_FILE_DEPENDS` 9452 When placed in the recipe that builds your image, this variable lists 9453 build-time dependencies. The :term:`WKS_FILE_DEPENDS` variable is only 9454 applicable when Wic images are active (i.e. when 9455 :term:`IMAGE_FSTYPES` contains entries related 9456 to Wic). If your recipe does not create Wic images, the variable has 9457 no effect. 9458 9459 The :term:`WKS_FILE_DEPENDS` variable is similar to the 9460 :term:`DEPENDS` variable. When you use the variable in 9461 your recipe that builds the Wic image, dependencies you list in the 9462 :term:`WKS_FILE_DEPENDS` variable are added to the :term:`DEPENDS` variable. 9463 9464 With the :term:`WKS_FILE_DEPENDS` variable, you have the possibility to 9465 specify a list of additional dependencies (e.g. native tools, 9466 bootloaders, and so forth), that are required to build Wic images. 9467 Following is an example:: 9468 9469 WKS_FILE_DEPENDS = "some-native-tool" 9470 9471 In the 9472 previous example, some-native-tool would be replaced with an actual 9473 native tool on which the build would depend. 9474 9475 :term:`WKS_FILES` 9476 Specifies a list of candidate Wic kickstart files to be used by the 9477 OpenEmbedded build system to create a partitioned image. Only the 9478 first one that is found, from left to right, will be used. 9479 9480 This is only useful when there are multiple ``.wks`` files that can be 9481 used to produce an image. A typical case is when multiple layers are 9482 used for different hardware platforms, each supplying a different 9483 ``.wks`` file. In this case, you specify all possible ones through 9484 :term:`WKS_FILES`. 9485 9486 If only one ``.wks`` file is used, set :term:`WKS_FILE` instead. 9487 9488 :term:`WORKDIR` 9489 The pathname of the work directory in which the OpenEmbedded build 9490 system builds a recipe. This directory is located within the 9491 :term:`TMPDIR` directory structure and is specific to 9492 the recipe being built and the system for which it is being built. 9493 9494 The :term:`WORKDIR` directory is defined as follows:: 9495 9496 ${TMPDIR}/work/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR} 9497 9498 The actual directory depends on several things: 9499 9500 - :term:`TMPDIR`: The top-level build output directory 9501 - :term:`MULTIMACH_TARGET_SYS`: The target system identifier 9502 - :term:`PN`: The recipe name 9503 - :term:`EXTENDPE`: The epoch --- if :term:`PE` is not specified, which 9504 is usually the case for most recipes, then :term:`EXTENDPE` is blank. 9505 - :term:`PV`: The recipe version 9506 - :term:`PR`: The recipe revision 9507 9508 As an example, assume a Source Directory top-level folder name 9509 ``poky``, a default :term:`Build Directory` at ``poky/build``, and a 9510 ``qemux86-poky-linux`` machine target system. Furthermore, suppose 9511 your recipe is named ``foo_1.3.0-r0.bb``. In this case, the work 9512 directory the build system uses to build the package would be as 9513 follows:: 9514 9515 poky/build/tmp/work/qemux86-poky-linux/foo/1.3.0-r0 9516 9517 :term:`XSERVER` 9518 Specifies the packages that should be installed to provide an X 9519 server and drivers for the current machine, assuming your image 9520 directly includes ``packagegroup-core-x11-xserver`` or, perhaps 9521 indirectly, includes "x11-base" in 9522 :term:`IMAGE_FEATURES`. 9523 9524 The default value of :term:`XSERVER`, if not specified in the machine 9525 configuration, is "xserver-xorg xf86-video-fbdev xf86-input-evdev". 9526 9527 :term:`XZ_THREADS` 9528 Specifies the number of parallel threads that should be used when 9529 using xz compression. 9530 9531 By default this scales with core count, but is never set less than 2 9532 to ensure that multi-threaded mode is always used so that the output 9533 file contents are deterministic. Builds will work with a value of 1 9534 but the output will differ compared to the output from the compression 9535 generated when more than one thread is used. 9536 9537 On systems where many tasks run in parallel, setting a limit to this 9538 can be helpful in controlling system resource usage. 9539 9540 :term:`XZ_MEMLIMIT` 9541 Specifies the maximum memory the xz compression should use as a percentage 9542 of system memory. If unconstrained the xz compressor can use large amounts of 9543 memory and become problematic with parallelism elsewhere in the build. 9544 "50%" has been found to be a good value. 9545 9546 :term:`ZSTD_THREADS` 9547 Specifies the number of parallel threads that should be used when 9548 using ZStandard compression. 9549 9550 By default this scales with core count, but is never set less than 2 9551 to ensure that multi-threaded mode is always used so that the output 9552 file contents are deterministic. Builds will work with a value of 1 9553 but the output will differ compared to the output from the compression 9554 generated when more than one thread is used. 9555 9556 On systems where many tasks run in parallel, setting a limit to this 9557 can be helpful in controlling system resource usage. 9558