blob: 011e0d74964abea4a66ddddd5969cb5a3ba7e9d2 [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
2"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
3[<!ENTITY % poky SYSTEM "../poky.ent"> %poky; ] >
4
5<chapter id='ref-tasks'>
6<title>Tasks</title>
7
8<para>
9 Tasks are units of execution for BitBake.
10 Recipes (<filename>.bb</filename> files) use tasks to complete
11 configuring, compiling, and packaging software.
12 This chapter provides a reference of the tasks defined in the
13 OpenEmbedded build system.
14</para>
15
16<section id='normal-recipe-build-tasks'>
17 <title>Normal Recipe Build Tasks</title>
18
19 <para>
20 The following sections describe normal tasks associated with building
21 a recipe.
Patrick Williamsc0f7c042017-02-23 20:41:17 -060022 For more information on tasks and dependencies, see the
23 "<ulink url='&YOCTO_DOCS_BB_URL;#tasks'>Tasks</ulink>" and
24 "<ulink url='&YOCTO_DOCS_BB_URL;#dependencies'>Dependencies</ulink>"
25 sections in the BitBake User Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -050026 </para>
27
28 <section id='ref-tasks-build'>
29 <title><filename>do_build</filename></title>
30
31 <para>
32 The default task for all recipes.
33 This task depends on all other normal tasks
34 required to build a recipe.
35 </para>
36 </section>
37
38 <section id='ref-tasks-compile'>
39 <title><filename>do_compile</filename></title>
40
41 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -060042 Compiles the source code.
43 This task runs with the current working directory set
44 to
45 <filename>${</filename><link linkend='var-B'><filename>B</filename></link><filename>}</filename>.
46 </para>
47
48 <para>
49 The default behavior of this task is to run the
50 <filename>oe_runmake</filename> function if a makefile
51 (<filename>Makefile</filename>, <filename>makefile</filename>,
52 or <filename>GNUmakefile</filename>) is found.
53 If no such file is found, the <filename>do_compile</filename>
54 task does nothing.
Patrick Williamsc124f4f2015-09-15 14:41:29 -050055 </para>
56 </section>
57
58 <section id='ref-tasks-compile_ptest_base'>
59 <title><filename>do_compile_ptest_base</filename></title>
60
61 <para>
62 Compiles the runtime test suite included in the software being
63 built.
64 </para>
65 </section>
66
67 <section id='ref-tasks-configure'>
68 <title><filename>do_configure</filename></title>
69
70 <para>
71 Configures the source by enabling and disabling any build-time and
72 configuration options for the software being built.
Patrick Williamsc0f7c042017-02-23 20:41:17 -060073 The task runs with the current working directory set to
74 <filename>${</filename><link linkend='var-B'><filename>B</filename></link><filename>}</filename>.
75 </para>
76
77 <para>
78 The default behavior of this task is to run
79 <filename>oe_runmake clean</filename> if a makefile
80 (<filename>Makefile</filename>, <filename>makefile</filename>,
81 or <filename>GNUmakefile</filename>) is found and
82 <link linkend='var-CLEANBROKEN'><filename>CLEANBROKEN</filename></link>
83 is not set to "1".
84 If no such file is found or the <filename>CLEANBROKEN</filename>
85 variable is set to "1", the <filename>do_configure</filename>
86 task does nothing.
Patrick Williamsc124f4f2015-09-15 14:41:29 -050087 </para>
88 </section>
89
90 <section id='ref-tasks-configure_ptest_base'>
91 <title><filename>do_configure_ptest_base</filename></title>
92
93 <para>
94 Configures the runtime test suite included in the software being
95 built.
96 </para>
97 </section>
98
99 <section id='ref-tasks-deploy'>
100 <title><filename>do_deploy</filename></title>
101
102 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600103 Writes output files that are to be deployed to
104 <filename>${</filename><link linkend='var-DEPLOY_DIR_IMAGE'><filename>DEPLOY_DIR_IMAGE</filename></link><filename>}</filename>.
105 The task runs with the current working directory set to
106 <filename>${</filename><link linkend='var-B'><filename>B</filename></link><filename>}</filename>.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500107 </para>
108
109 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600110 Recipes implementing this task should inherit the
111 <link linkend='ref-classes-deploy'><filename>deploy</filename></link>
112 class and should write the output to
113 <filename>${</filename><link linkend='var-DEPLOYDIR'><filename>DEPLOYDIR</filename></link><filename>}</filename>,
Brad Bishop316dfdd2018-06-25 12:45:53 -0400114 which is not to be confused with <filename>${DEPLOY_DIR}</filename>.
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600115 The <filename>deploy</filename> class sets up
116 <filename>do_deploy</filename> as a shared state (sstate) task that
117 can be accelerated through sstate use.
118 The sstate mechanism takes care of copying the output from
119 <filename>${DEPLOYDIR}</filename> to
120 <filename>${DEPLOY_DIR_IMAGE}</filename>.
121 <note>
122 <title>Caution</title>
123 Do not write the output directly to
124 <filename>${DEPLOY_DIR_IMAGE}</filename>, as this causes
125 the sstate mechanism to malfunction.
126 </note>
127 </para>
128
129 <para>
130 The <filename>do_deploy</filename> task is not added as a task
131 by default and consequently needs to be added manually.
132 If you want the task to run after
133 <link linkend='ref-tasks-compile'><filename>do_compile</filename></link>,
134 you can add it by doing the following:
135 <literallayout class='monospaced'>
136 addtask deploy after do_compile
137 </literallayout>
138 Adding <filename>do_deploy</filename> after other tasks works the
139 same way.
140 <note>
141 You do not need to add <filename>before do_build</filename>
142 to the <filename>addtask</filename> command (though it is
143 harmless), because the
144 <link linkend='ref-classes-base'><filename>base</filename></link>
145 class contains the following:
146 <literallayout class='monospaced'>
147 do_build[recrdeptask] += "do_deploy"
148 </literallayout>
149 See the
150 "<ulink url='&YOCTO_DOCS_BB_URL;#dependencies'>Dependencies</ulink>"
151 section in the BitBake User Manual for more information.
152 </note>
153 </para>
154
155 <para>
156 If the <filename>do_deploy</filename> task re-executes, any
157 previous output is removed (i.e. "cleaned").
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500158 </para>
159 </section>
160
161 <section id='ref-tasks-fetch'>
162 <title><filename>do_fetch</filename></title>
163
164 <para>
165 Fetches the source code.
166 This task uses the
167 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
168 variable and the argument's prefix to determine the correct
Brad Bishop15ae2502019-06-18 21:44:24 -0400169 <ulink url='&YOCTO_DOCS_BB_URL;#bb-fetchers'>fetcher</ulink>
170 module.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500171 </para>
172 </section>
173
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500174 <section id='ref-tasks-image'>
175 <title><filename>do_image</filename></title>
176
177 <para>
178 Starts the image generation process.
179 The <filename>do_image</filename> task runs after the
180 OpenEmbedded build system has run the
181 <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
182 task during which packages are identified for installation into
183 the image and the root filesystem is created, complete with
184 post-processing.
185 </para>
186
187 <para>
188 The <filename>do_image</filename> task performs pre-processing
189 on the image through the
190 <link linkend='var-IMAGE_PREPROCESS_COMMAND'><filename>IMAGE_PREPROCESS_COMMAND</filename></link>
191 and dynamically generates supporting
192 <filename>do_image_*</filename> tasks as needed.
193 </para>
194
195 <para>
196 For more information on image creation, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400197 "<ulink url='&YOCTO_DOCS_OM_URL;#image-generation-dev-environment'>Image Generation</ulink>"
198 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500199 </para>
200 </section>
201
202 <section id='ref-tasks-image-complete'>
203 <title><filename>do_image_complete</filename></title>
204
205 <para>
206 Completes the image generation process.
207 The <filename>do_image_complete</filename> task runs after the
208 OpenEmbedded build system has run the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400209 <link linkend='ref-tasks-image'><filename>do_image</filename></link>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500210 task during which image pre-processing occurs and through
211 dynamically generated <filename>do_image_*</filename> tasks the
212 image is constructed.
213 </para>
214
215 <para>
216 The <filename>do_image_complete</filename> task performs
217 post-processing on the image through the
218 <link linkend='var-IMAGE_POSTPROCESS_COMMAND'><filename>IMAGE_POSTPROCESS_COMMAND</filename></link>.
219 </para>
220
221 <para>
222 For more information on image creation, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400223 "<ulink url='&YOCTO_DOCS_OM_URL;#image-generation-dev-environment'>Image Generation</ulink>"
224 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500225 </para>
226 </section>
227
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500228 <section id='ref-tasks-install'>
229 <title><filename>do_install</filename></title>
230
231 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600232 Copies files that are to be packaged into the holding area
233 <filename>${</filename><link linkend='var-D'><filename>D</filename></link><filename>}</filename>.
234 This task runs with the current working directory set to
235 <filename>${</filename><link linkend='var-B'><filename>B</filename></link><filename>}</filename>,
236 which is the compilation directory.
237 The <filename>do_install</filename> task, as well as other tasks
238 that either directly or indirectly depend on the installed files
239 (e.g.
240 <link linkend='ref-tasks-package'><filename>do_package</filename></link>,
241 <link linkend='ref-tasks-package_write_deb'><filename>do_package_write_*</filename></link>,
242 and
243 <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>),
244 run under
Brad Bishop316dfdd2018-06-25 12:45:53 -0400245 <ulink url='&YOCTO_DOCS_OM_URL;#fakeroot-and-pseudo'>fakeroot</ulink>.
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600246 <note>
247 <title>Caution</title>
248
249 <para>
250 When installing files, be careful not to set the owner and
251 group IDs of the installed files to unintended values.
252 Some methods of copying files, notably when using the
253 recursive <filename>cp</filename> command, can preserve the
254 UID and/or GID of the original file, which is usually not
255 what you want.
256 The
Brad Bishop316dfdd2018-06-25 12:45:53 -0400257 <link linkend='insane-host-user-contaminated'><filename>host-user-contaminated</filename></link>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600258 QA check checks for files that probably have the wrong
259 ownership.
260 </para>
261
262 <para>
263 Safe methods for installing files include the following:
264 <itemizedlist>
265 <listitem><para>
266 The <filename>install</filename> utility.
267 This utility is the preferred method.
268 </para></listitem>
269 <listitem><para>
270 The <filename>cp</filename> command with the
271 "--no-preserve=ownership" option.
272 </para></listitem>
273 <listitem><para>
274 The <filename>tar</filename> command with the
275 "--no-same-owner" option.
276 See the <filename>bin_package.bbclass</filename>
277 file in the <filename>meta/classes</filename>
278 directory of the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500279 <link linkend='source-directory'>Source Directory</link>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600280 for an example.
281 </para></listitem>
282 </itemizedlist>
283 </para>
284 </note>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500285 </para>
286 </section>
287
288 <section id='ref-tasks-install_ptest_base'>
289 <title><filename>do_install_ptest_base</filename></title>
290
291 <para>
292 Copies the runtime test suite files from the compilation directory
293 to a holding area.
294 </para>
295 </section>
296
297 <section id='ref-tasks-package'>
298 <title><filename>do_package</filename></title>
299
300 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600301 Analyzes the content of the holding area
302 <filename>${</filename><link linkend='var-D'><filename>D</filename></link><filename>}</filename>
303 and splits the content into subsets based on available packages
304 and files.
305 This task makes use of the
306 <link linkend='var-PACKAGES'><filename>PACKAGES</filename></link>
307 and
308 <link linkend='var-FILES'><filename>FILES</filename></link>
309 variables.
310 </para>
311
312 <para>
313 The <filename>do_package</filename> task, in conjunction with the
314 <link linkend='ref-tasks-packagedata'><filename>do_packagedata</filename></link>
315 task, also saves some important package metadata.
316 For additional information, see the
317 <link linkend='var-PKGDESTWORK'><filename>PKGDESTWORK</filename></link>
318 variable and the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400319 "<ulink url='&YOCTO_DOCS_OM_URL;#automatically-added-runtime-dependencies'>Automatically Added Runtime Dependencies</ulink>"
320 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500321 </para>
322 </section>
323
324 <section id='ref-tasks-package_qa'>
325 <title><filename>do_package_qa</filename></title>
326
327 <para>
328 Runs QA checks on packaged files.
329 For more information on these checks, see the
330 <link linkend='ref-classes-insane'><filename>insane</filename></link>
331 class.
332 </para>
333 </section>
334
335 <section id='ref-tasks-package_write_deb'>
336 <title><filename>do_package_write_deb</filename></title>
337
338 <para>
339 Creates Debian packages (i.e. <filename>*.deb</filename> files) and
340 places them in the
341 <filename>${</filename><link linkend='var-DEPLOY_DIR_DEB'><filename>DEPLOY_DIR_DEB</filename></link><filename>}</filename>
342 directory in the package feeds area.
343 For more information, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400344 "<ulink url='&YOCTO_DOCS_OM_URL;#package-feeds-dev-environment'>Package Feeds</ulink>"
345 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500346 </para>
347 </section>
348
349 <section id='ref-tasks-package_write_ipk'>
350 <title><filename>do_package_write_ipk</filename></title>
351
352 <para>
353 Creates IPK packages (i.e. <filename>*.ipk</filename> files) and
354 places them in the
355 <filename>${</filename><link linkend='var-DEPLOY_DIR_IPK'><filename>DEPLOY_DIR_IPK</filename></link><filename>}</filename>
356 directory in the package feeds area.
357 For more information, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400358 "<ulink url='&YOCTO_DOCS_OM_URL;#package-feeds-dev-environment'>Package Feeds</ulink>"
359 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500360 </para>
361 </section>
362
363 <section id='ref-tasks-package_write_rpm'>
364 <title><filename>do_package_write_rpm</filename></title>
365
366 <para>
367 Creates RPM packages (i.e. <filename>*.rpm</filename> files) and
368 places them in the
369 <filename>${</filename><link linkend='var-DEPLOY_DIR_RPM'><filename>DEPLOY_DIR_RPM</filename></link><filename>}</filename>
370 directory in the package feeds area.
371 For more information, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400372 "<ulink url='&YOCTO_DOCS_OM_URL;#package-feeds-dev-environment'>Package Feeds</ulink>"
373 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500374 </para>
375 </section>
376
377 <section id='ref-tasks-package_write_tar'>
378 <title><filename>do_package_write_tar</filename></title>
379
380 <para>
381 Creates tarballs and places them in the
382 <filename>${</filename><link linkend='var-DEPLOY_DIR_TAR'><filename>DEPLOY_DIR_TAR</filename></link><filename>}</filename>
383 directory in the package feeds area.
384 For more information, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400385 "<ulink url='&YOCTO_DOCS_OM_URL;#package-feeds-dev-environment'>Package Feeds</ulink>"
386 section in the Yocto Project Overview and Concepts Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500387 </para>
388 </section>
389
390 <section id='ref-tasks-packagedata'>
391 <title><filename>do_packagedata</filename></title>
392
393 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600394 Saves package metadata generated by the
395 <link linkend='ref-tasks-package'><filename>do_package</filename></link>
396 task in
397 <link linkend='var-PKGDATA_DIR'><filename>PKGDATA_DIR</filename></link>
398 to make it available globally.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500399 </para>
400 </section>
401
402 <section id='ref-tasks-patch'>
403 <title><filename>do_patch</filename></title>
404
405 <para>
406 Locates patch files and applies them to the source code.
Brad Bishop316dfdd2018-06-25 12:45:53 -0400407 </para>
408
409 <para>
410 After fetching and unpacking source files, the build system
411 uses the recipe's
412 <ulink url='&YOCTO_DOCS_REF_URL;#var-SRC_URI'><filename>SRC_URI</filename></ulink>
413 statements to locate and apply patch files to the source code.
414 <note>
415 The build system uses the
416 <ulink url='&YOCTO_DOCS_REF_URL;#var-FILESPATH'><filename>FILESPATH</filename></ulink>
417 variable to determine the default set of directories when
418 searching for patches.
419 </note>
420 Patch files, by default, are <filename>*.patch</filename> and
421 <filename>*.diff</filename> files created and kept in a
422 subdirectory of the directory holding the recipe file.
423 For example, consider the
424 <ulink url='&YOCTO_GIT_URL;/cgit/cgit.cgi/poky/tree/meta/recipes-connectivity/bluez5'><filename>bluez5</filename></ulink>
425 recipe from the OE-Core layer (i.e.
426 <filename>poky/meta</filename>):
427 <literallayout class='monospaced'>
428 poky/meta/recipes-connectivity/bluez5
429 </literallayout>
430 This recipe has two patch files located here:
431 <literallayout class='monospaced'>
432 poky/meta/recipes-connectivity/bluez5/bluez5
433 </literallayout>
434 </para>
435
436 <para>
437 In the <filename>bluez5</filename> recipe, the
438 <filename>SRC_URI</filename> statements point to the source and
439 patch files needed to build the package.
440 <note>
441 In the case for the <filename>bluez5_5.48.bb</filename>
442 recipe, the <filename>SRC_URI</filename> statements are from an
443 include file <filename>bluez5.inc</filename>.
444 </note>
445 </para>
446
447 <para>
448 As mentioned earlier, the build system treats files whose file
449 types are <filename>.patch</filename> and
450 <filename>.diff</filename> as patch files.
451 However, you can use the "apply=yes" parameter with the
452 <filename>SRC_URI</filename> statement to indicate any file as a
453 patch file:
454 <literallayout class='monospaced'>
455 SRC_URI = " \
456 git://<replaceable>path_to_repo</replaceable>/<replaceable>some_package</replaceable> \
457 file://<replaceable>file</replaceable>;apply=yes \
458 "
459 </literallayout>
460 </para>
461
462 <para>
463 Conversely, if you have a directory full of patch files and you
464 want to exclude some so that the <filename>do_patch</filename>
465 task does not apply them during the patch phase, you can use
466 the "apply=no" parameter with the <filename>SRC_URI</filename>
467 statement:
468 <literallayout class='monospaced'>
469 SRC_URI = " \
470 git://<replaceable>path_to_repo</replaceable>/<replaceable>some_package</replaceable> \
471 file://<replaceable>path_to_lots_of_patch_files</replaceable> \
472 file://<replaceable>path_to_lots_of_patch_files</replaceable>/<replaceable>patch_file5</replaceable>;apply=no \
473 "
474 </literallayout>
475 In the previous example, assuming all the files in the directory
476 holding the patch files end with either <filename>.patch</filename>
477 or <filename>.diff</filename>, every file would be applied as a
478 patch by default except for the
479 <replaceable>patch_file5</replaceable> patch.
480 </para>
481
482 <para>
483 You can find out more about the patching process in the
484 "<ulink url='&YOCTO_DOCS_OM_URL;#patching-dev-environment'>Patching</ulink>"
485 section in the Yocto Project Overview and Concepts Manual and the
486 "<ulink url='&YOCTO_DOCS_DEV_URL;#new-recipe-patching-code'>Patching Code</ulink>"
487 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500488 </para>
489 </section>
490
491 <section id='ref-tasks-populate_lic'>
492 <title><filename>do_populate_lic</filename></title>
493
494 <para>
495 Writes license information for the recipe that is collected later
496 when the image is constructed.
497 </para>
498 </section>
499
500 <section id='ref-tasks-populate_sdk'>
501 <title><filename>do_populate_sdk</filename></title>
502
503 <para>
504 Creates the file and directory structure for an installable SDK.
505 See the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400506 "<ulink url='&YOCTO_DOCS_OM_URL;#sdk-generation-dev-environment'>SDK Generation</ulink>"
507 section in the Yocto Project Overview and Concepts Manual for more
508 information.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500509 </para>
510 </section>
511
512 <section id='ref-tasks-populate_sysroot'>
513 <title><filename>do_populate_sysroot</filename></title>
514
515 <para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600516 Stages (copies) a subset of the files installed by the
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500517 <link linkend='ref-tasks-install'><filename>do_install</filename></link>
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600518 task into the appropriate sysroot.
519 For information on how to access these files from other recipes,
520 see the
521 <link linkend='var-STAGING_DIR_HOST'><filename>STAGING_DIR*</filename></link>
522 variables.
523 Directories that would typically not be needed by other recipes at
524 build time (e.g. <filename>/etc</filename>) are not copied by
525 default.
526 </para>
527
528 <para>
529 For information on what directories are copied by default, see the
530 <link linkend='var-SYSROOT_DIRS'><filename>SYSROOT_DIRS*</filename></link>
531 variables.
532 You can change these variables inside your recipe if you need
533 to make additional (or fewer) directories available to other
534 recipes at build time.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500535 </para>
536
537 <para>
538 The <filename>do_populate_sysroot</filename> task is a
539 shared state (sstate) task, which means that the task can
540 be accelerated through sstate use.
541 Realize also that if the task is re-executed, any previous output
542 is removed (i.e. "cleaned").
543 </para>
544 </section>
545
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500546 <section id='ref-tasks-prepare_recipe_sysroot'>
547 <title><filename>do_prepare_recipe_sysroot</filename></title>
548
549 <para>
550 Installs the files into the individual recipe specific sysroots
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500551 (i.e. <filename>recipe-sysroot</filename> and
552 <filename>recipe-sysroot-native</filename> under
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500553 <filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}</filename>
554 based upon the dependencies specified by
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500555 <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>).
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500556 See the
557 "<link linkend='ref-classes-staging'><filename>staging</filename></link>"
558 class for more information.
559 </para>
560 </section>
561
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500562 <section id='ref-tasks-rm_work'>
563 <title><filename>do_rm_work</filename></title>
564
565 <para>
566 Removes work files after the OpenEmbedded build system has
567 finished with them.
568 You can learn more by looking at the
569 "<link linkend='ref-classes-rm-work'><filename>rm_work.bbclass</filename></link>"
570 section.
571 </para>
572 </section>
573
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500574 <section id='ref-tasks-unpack'>
575 <title><filename>do_unpack</filename></title>
576
577 <para>
578 Unpacks the source code into a working directory pointed to
579 by
580 <filename>${</filename><link linkend='var-WORKDIR'><filename>WORKDIR</filename></link><filename>}</filename>.
581 The
582 <link linkend='var-S'><filename>S</filename></link> variable also
583 plays a role in where unpacked source files ultimately reside.
584 For more information on how source files are unpacked, see the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400585 "<ulink url='&YOCTO_DOCS_OM_URL;#source-fetching-dev-environment'>Source Fetching</ulink>"
586 section in the Yocto Project Overview and Concepts Manual and also
587 see the <filename>WORKDIR</filename> and
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500588 <filename>S</filename> variable descriptions.
589 </para>
590 </section>
591</section>
592
593<section id='manually-called-tasks'>
594 <title>Manually Called Tasks</title>
595
596 <para>
597 These tasks are typically manually triggered (e.g. by using the
598 <filename>bitbake -c</filename> command-line option):
599 </para>
600
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600601 <section id='ref-tasks-checkpkg'>
602 <title><filename>do_checkpkg</filename></title>
603
604 <para>
605 Provides information about the recipe including its upstream
606 version and status.
607 The upstream version and status reveals whether or not a version
608 of the recipe exists upstream and a status of not updated, updated,
609 or unknown.
610 </para>
611
612 <para>
Brad Bishop15ae2502019-06-18 21:44:24 -0400613 To check the upstream version and status of a recipe, use the
614 following devtool commands:
615 <literallayout class='monospaced'>
616 $ devtool latest-version
617 $ devtool check-upgrade-status
618 </literallayout>
619 See the
620 "<link linkend='ref-devtool-reference'><filename>devtool</filename> Quick Reference</link>"
621 chapter for more information on <filename>devtool</filename>.
622 See the
623 "<ulink url='&YOCTO_DOCS_REF_URL;#devtool-checking-on-the-upgrade-status-of-a-recipe'>Checking on the Upgrade Status of a Recipe</ulink>"
624 section for information on checking the upgrade status of a recipe.
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600625 </para>
626
627 <para>
628 To build the <filename>checkpkg</filename> task, use the
629 <filename>bitbake</filename> command with the "-c" option and
630 task name:
631 <literallayout class='monospaced'>
632 $ bitbake core-image-minimal -c checkpkg
633 </literallayout>
634 By default, the results are stored in
635 <link linkend='var-LOG_DIR'><filename>$LOG_DIR</filename></link>
636 (e.g. <filename>$BUILD_DIR/tmp/log</filename>).
637 </para>
638 </section>
639
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500640 <section id='ref-tasks-checkuri'>
641 <title><filename>do_checkuri</filename></title>
642
643 <para>
644 Validates the
645 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
646 value.
647 </para>
648 </section>
649
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500650 <section id='ref-tasks-clean'>
651 <title><filename>do_clean</filename></title>
652
653 <para>
654 Removes all output files for a target from the
655 <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
Brad Bishop316dfdd2018-06-25 12:45:53 -0400656 task forward (i.e. <filename>do_unpack</filename>,
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500657 <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>,
658 <link linkend='ref-tasks-compile'><filename>do_compile</filename></link>,
659 <link linkend='ref-tasks-install'><filename>do_install</filename></link>,
660 and
661 <link linkend='ref-tasks-package'><filename>do_package</filename></link>).
662 </para>
663
664 <para>
665 You can run this task using BitBake as follows:
666 <literallayout class='monospaced'>
667 $ bitbake -c clean <replaceable>recipe</replaceable>
668 </literallayout>
669 </para>
670
671 <para>
672 Running this task does not remove the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400673 <ulink url='&YOCTO_DOCS_OM_URL;#shared-state-cache'>sstate</ulink>
674 cache files.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500675 Consequently, if no changes have been made and the recipe is
676 rebuilt after cleaning, output files are simply restored from the
677 sstate cache.
678 If you want to remove the sstate cache files for the recipe,
679 you need to use the
680 <link linkend='ref-tasks-cleansstate'><filename>do_cleansstate</filename></link>
681 task instead (i.e. <filename>bitbake -c cleansstate</filename> <replaceable>recipe</replaceable>).
682 </para>
683 </section>
684
685 <section id='ref-tasks-cleanall'>
686 <title><filename>do_cleanall</filename></title>
687
688 <para>
689 Removes all output files, shared state
Brad Bishop316dfdd2018-06-25 12:45:53 -0400690 (<ulink url='&YOCTO_DOCS_OM_URL;#shared-state-cache'>sstate</ulink>)
691 cache, and downloaded source files for a target (i.e. the contents
692 of
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500693 <link linkend='var-DL_DIR'><filename>DL_DIR</filename></link>).
694 Essentially, the <filename>do_cleanall</filename> task is
695 identical to the
696 <link linkend='ref-tasks-cleansstate'><filename>do_cleansstate</filename></link>
697 task with the added removal of downloaded source files.
698 </para>
699
700 <para>
701 You can run this task using BitBake as follows:
702 <literallayout class='monospaced'>
703 $ bitbake -c cleanall <replaceable>recipe</replaceable>
704 </literallayout>
705 </para>
706
707 <para>
708 Typically, you would not normally use the
709 <filename>cleanall</filename> task.
710 Do so only if you want to start fresh with the
711 <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
712 task.
713 </para>
714 </section>
715
716 <section id='ref-tasks-cleansstate'>
717 <title><filename>do_cleansstate</filename></title>
718
719 <para>
720 Removes all output files and shared state
Brad Bishop316dfdd2018-06-25 12:45:53 -0400721 (<ulink url='&YOCTO_DOCS_OM_URL;#shared-state-cache'>sstate</ulink>)
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500722 cache for a target.
723 Essentially, the <filename>do_cleansstate</filename> task is
724 identical to the
725 <link linkend='ref-tasks-clean'><filename>do_clean</filename></link>
726 task with the added removal of shared state
Brad Bishop316dfdd2018-06-25 12:45:53 -0400727 (<ulink url='&YOCTO_DOCS_OM_URL;#shared-state-cache'>sstate</ulink>)
728 cache.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500729 </para>
730
731 <para>
732 You can run this task using BitBake as follows:
733 <literallayout class='monospaced'>
734 $ bitbake -c cleansstate <replaceable>recipe</replaceable>
735 </literallayout>
736 </para>
737
738 <para>
739 When you run the <filename>do_cleansstate</filename> task,
740 the OpenEmbedded build system no longer uses any
741 sstate.
742 Consequently, building the recipe from scratch is guaranteed.
743 <note>
744 The <filename>do_cleansstate</filename> task cannot remove
745 sstate from a remote sstate mirror.
746 If you need to build a target from scratch using remote
747 mirrors, use the "-f" option as follows:
748 <literallayout class='monospaced'>
749 $ bitbake -f -c do_cleansstate <replaceable>target</replaceable>
750 </literallayout>
751 </note>
752 </para>
753 </section>
754
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600755 <section id='ref-tasks-devpyshell'>
756 <title><filename>do_devpyshell</filename></title>
757
758 <para>
759 Starts a shell in which an interactive Python interpreter allows
760 you to interact with the BitBake build environment.
761 From within this shell, you can directly examine and set
762 bits from the data store and execute functions as if within
763 the BitBake environment.
764 See the
765 "<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devpyshell'>Using a Development Python Shell</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500766 section in the Yocto Project Development Tasks Manual for more
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600767 information about using <filename>devpyshell</filename>.
768 </para>
769 </section>
770
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500771 <section id='ref-tasks-devshell'>
772 <title><filename>do_devshell</filename></title>
773
774 <para>
775 Starts a shell whose environment is set up for
776 development, debugging, or both.
777 See the
778 "<ulink url='&YOCTO_DOCS_DEV_URL;#platdev-appdev-devshell'>Using a Development Shell</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500779 section in the Yocto Project Development Tasks Manual for more
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500780 information about using <filename>devshell</filename>.
781 </para>
782 </section>
783
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500784 <section id='ref-tasks-listtasks'>
785 <title><filename>do_listtasks</filename></title>
786
787 <para>
788 Lists all defined tasks for a target.
789 </para>
790 </section>
791
792 <section id='ref-tasks-package_index'>
793 <title><filename>do_package_index</filename></title>
794
795 <para>
796 Creates or updates the index in the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400797 <ulink url='&YOCTO_DOCS_OM_URL;#package-feeds-dev-environment'>Package Feeds</ulink>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500798 area.
799 <note>
800 This task is not triggered with the
801 <filename>bitbake -c</filename> command-line option as
802 are the other tasks in this section.
803 Because this task is specifically for the
804 <filename>package-index</filename> recipe,
805 you run it using
806 <filename>bitbake package-index</filename>.
807 </note>
808 </para>
809 </section>
810</section>
811
812<section id='image-related-tasks'>
813 <title>Image-Related Tasks</title>
814
815 <para>
816 The following tasks are applicable to image recipes.
817 </para>
818
819 <section id='ref-tasks-bootimg'>
820 <title><filename>do_bootimg</filename></title>
821
822 <para>
823 Creates a bootable live image.
824 See the
825 <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
826 variable for additional information on live image types.
827 </para>
828 </section>
829
830 <section id='ref-tasks-bundle_initramfs'>
831 <title><filename>do_bundle_initramfs</filename></title>
832
833 <para>
834 Combines an initial RAM disk (initramfs) image and kernel
835 together to form a single image.
836 The
837 <link linkend='var-CONFIG_INITRAMFS_SOURCE'><filename>CONFIG_INITRAMFS_SOURCE</filename></link>
838 variable has some more information about these types of images.
839 </para>
840 </section>
841
842 <section id='ref-tasks-rootfs'>
843 <title><filename>do_rootfs</filename></title>
844
845 <para>
846 Creates the root filesystem (file and directory structure) for an
847 image.
848 See the
Brad Bishop316dfdd2018-06-25 12:45:53 -0400849 "<ulink url='&YOCTO_DOCS_OM_URL;#image-generation-dev-environment'>Image Generation</ulink>"
850 section in the Yocto Project Overview and Concepts Manual for more
851 information on how the root filesystem is created.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500852 </para>
853 </section>
854
855 <section id='ref-tasks-testimage'>
856 <title><filename>do_testimage</filename></title>
857
858 <para>
859 Boots an image and performs runtime tests within the image.
860 For information on automatically testing images, see the
861 "<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500862 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500863 </para>
864 </section>
865
866 <section id='ref-tasks-testimage_auto'>
867 <title><filename>do_testimage_auto</filename></title>
868
869 <para>
870 Boots an image and performs runtime tests within the image
871 immediately after it has been built.
872 This task is enabled when you set
Brad Bishop1a4b7ee2018-12-16 17:11:34 -0800873 <link linkend='var-TESTIMAGE_AUTO'><filename>TESTIMAGE_AUTO</filename></link>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500874 equal to "1".
875 </para>
876
877 <para>
878 For information on automatically testing images, see the
879 "<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500880 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500881 </para>
882 </section>
883</section>
884
885<section id='kernel-related-tasks'>
886 <title>Kernel-Related Tasks</title>
887
888 <para>
889 The following tasks are applicable to kernel recipes.
890 Some of these tasks (e.g. the
891 <link linkend='ref-tasks-menuconfig'><filename>do_menuconfig</filename></link>
892 task) are also applicable to recipes that use
893 Linux kernel style configuration such as the BusyBox recipe.
894 </para>
895
896 <section id='ref-tasks-compile_kernelmodules'>
897 <title><filename>do_compile_kernelmodules</filename></title>
898
899 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500900 Runs the step that builds the kernel modules (if needed).
901 Building a kernel consists of two steps: 1) the kernel
902 (<filename>vmlinux</filename>) is built, and 2) the modules
903 are built (i.e. <filename>make modules</filename>).
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500904 </para>
905 </section>
906
907 <section id='ref-tasks-diffconfig'>
908 <title><filename>do_diffconfig</filename></title>
909
910 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500911 When invoked by the user, this task creates a file containing the
912 differences between the original config as produced by
913 <link linkend='ref-tasks-kernel_configme'><filename>do_kernel_configme</filename></link>
914 task and the changes made by the user with other methods
915 (i.e. using
916 (<link linkend='ref-tasks-kernel_menuconfig'><filename>do_kernel_menuconfig</filename></link>).
917 Once the file of differences is created, it can be used to create
918 a config fragment that only contains the differences.
919 You can invoke this task from the command line as follows:
920 <literallayout class='monospaced'>
921 $ bitbake linux-yocto -c diffconfig
922 </literallayout>
923 For more information, see the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500924 "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#creating-config-fragments'>Creating Configuration Fragments</ulink>"
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500925 section in the Yocto Project Linux Kernel Development Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500926 </para>
927 </section>
928
929 <section id='ref-tasks-kernel_checkout'>
930 <title><filename>do_kernel_checkout</filename></title>
931
932 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500933 Converts the newly unpacked kernel source into a form with which
934 the OpenEmbedded build system can work.
935 Because the kernel source can be fetched in several different ways,
936 the <filename>do_kernel_checkout</filename> task makes sure that
937 subsequent tasks are given a clean working tree copy of the kernel
938 with the correct branches checked out.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500939 </para>
940 </section>
941
942 <section id='ref-tasks-kernel_configcheck'>
943 <title><filename>do_kernel_configcheck</filename></title>
944
945 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500946 Validates the configuration produced by the
947 <link linkend='ref-tasks-kernel_menuconfig'><filename>do_kernel_menuconfig</filename></link>
948 task.
949 The <filename>do_kernel_configcheck</filename> task produces
950 warnings when a requested configuration does not appear in the
951 final <filename>.config</filename> file or when you override a
952 policy configuration in a hardware configuration fragment.
953 You can run this task explicitly and view the output by using
954 the following command:
955 <literallayout class='monospaced'>
956 $ bitbake linux-yocto -c kernel_configcheck -f
957 </literallayout>
958 For more information, see the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500959 "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#validating-configuration'>Validating Configuration</ulink>"
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500960 section in the Yocto Project Linux Kernel Development Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500961 </para>
962 </section>
963
964 <section id='ref-tasks-kernel_configme'>
965 <title><filename>do_kernel_configme</filename></title>
966
967 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500968 After the kernel is patched by the
969 <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
970 task, the <filename>do_kernel_configme</filename> task assembles
971 and merges all the kernel config fragments into a merged
972 configuration that can then be passed to the kernel configuration
973 phase proper.
974 This is also the time during which user-specified defconfigs
975 are applied if present, and where configuration modes such as
976 <filename>--allnoconfig</filename> are applied.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500977 </para>
978 </section>
979
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500980 <section id='ref-tasks-kernel_menuconfig'>
981 <title><filename>do_kernel_menuconfig</filename></title>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500982
983 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500984 Invoked by the user to manipulate the
985 <filename>.config</filename> file used to build a linux-yocto
986 recipe.
987 This task starts the Linux kernel configuration tool, which you
988 then use to modify the kernel configuration.
989 <note>
990 You can also invoke this tool from the command line as
991 follows:
992 <literallayout class='monospaced'>
993 $ bitbake linux-yocto -c menuconfig
994 </literallayout>
995 </note>
996 See the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500997 "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#using-menuconfig'>Using <filename>menuconfig</filename></ulink>"
Brad Bishop6e60e8b2018-02-01 10:27:11 -0500998 section in the Yocto Project Linux Kernel Development Manual
999 for more information on this configuration tool.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001000 </para>
1001 </section>
1002
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001003 <section id='ref-tasks-kernel_metadata'>
1004 <title><filename>do_kernel_metadata</filename></title>
1005
1006 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001007 Collects all the features required for a given kernel build,
1008 whether the features come from
1009 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
1010 or from Git repositories.
1011 After collection, the <filename>do_kernel_metadata</filename> task
1012 processes the features into a series of config fragments and
1013 patches, which can then be applied by subsequent tasks such as
1014 <link linkend='ref-tasks-patch'><filename>do_patch</filename></link>
1015 and
1016 <link linkend='ref-tasks-kernel_configme'><filename>do_kernel_configme</filename></link>.
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001017 </para>
1018 </section>
1019
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001020 <section id='ref-tasks-menuconfig'>
1021 <title><filename>do_menuconfig</filename></title>
1022
1023 <para>
1024 Runs <filename>make menuconfig</filename> for the kernel.
1025 For information on <filename>menuconfig</filename>, see the
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001026 "<ulink url='&YOCTO_DOCS_KERNEL_DEV_URL;#using-menuconfig'>Using&nbsp;&nbsp;<filename>menuconfig</filename></ulink>"
1027 section in the Yocto Project Linux Kernel Development Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001028 </para>
1029 </section>
1030
1031 <section id='ref-tasks-savedefconfig'>
1032 <title><filename>do_savedefconfig</filename></title>
1033
1034 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001035 When invoked by the user, creates a defconfig file that can be
1036 used instead of the default defconfig.
1037 The saved defconfig contains the differences between the default
1038 defconfig and the changes made by the user using other methods
1039 (i.e. the
1040 <link linkend='ref-tasks-kernel_menuconfig'><filename>do_kernel_menuconfig</filename></link>
1041 task.
1042 You can invoke the task using the following command:
1043 <literallayout class='monospaced'>
1044 $ bitbake linux-yocto -c savedefconfig
1045 </literallayout>
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001046 </para>
1047 </section>
1048
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001049 <section id='ref-tasks-shared_workdir'>
1050 <title><filename>do_shared_workdir</filename></title>
1051
1052 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001053 After the kernel has been compiled but before the kernel modules
1054 have been compiled, this task copies files required for module
1055 builds and which are generated from the kernel build into the
1056 shared work directory.
1057 With these copies successfully copied, the
1058 <link linkend='ref-tasks-compile_kernelmodules'><filename>do_compile_kernelmodules</filename></link>
1059 task can successfully build the kernel modules in the next step
1060 of the build.
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001061 </para>
1062 </section>
1063
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001064 <section id='ref-tasks-sizecheck'>
1065 <title><filename>do_sizecheck</filename></title>
1066
1067 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001068 After the kernel has been built, this task checks the size of the
1069 stripped kernel image against
1070 <link linkend='var-KERNEL_IMAGE_MAXSIZE'><filename>KERNEL_IMAGE_MAXSIZE</filename></link>.
1071 If that variable was set and the size of the stripped kernel
1072 exceeds that size, the kernel build produces a warning to that
1073 effect.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001074 </para>
1075 </section>
1076
1077 <section id='ref-tasks-strip'>
1078 <title><filename>do_strip</filename></title>
1079
1080 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001081 If
1082 <filename>KERNEL_IMAGE_STRIP_EXTRA_SECTIONS</filename> is defined,
1083 this task strips the sections named in that variable from
1084 <filename>vmlinux</filename>.
1085 This stripping is typically used to remove nonessential sections
1086 such as <filename>.comment</filename> sections from a
1087 size-sensitive configuration.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001088 </para>
1089 </section>
1090
1091 <section id='ref-tasks-validate_branches'>
1092 <title><filename>do_validate_branches</filename></title>
1093
1094 <para>
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001095 After the kernel is unpacked but before it is patched, this task
1096 makes sure that the machine and metadata branches as specified
1097 by the <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
1098 variables actually exist on the specified branches.
1099 If these branches do not exist and
1100 <link linkend='var-AUTOREV'><filename>AUTOREV</filename></link>
1101 is not being used, the <filename>do_validate_branches</filename>
1102 task fails during the build.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001103 </para>
1104 </section>
1105</section>
1106
1107<section id='miscellaneous-tasks'>
1108 <title>Miscellaneous Tasks</title>
1109
1110 <para>
1111 The following sections describe miscellaneous tasks.
1112 </para>
1113
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001114 <section id='ref-tasks-spdx'>
1115 <title><filename>do_spdx</filename></title>
1116
1117 <para>
1118 A build stage that takes the source code and scans it on a remote
1119 FOSSOLOGY server in order to produce an SPDX document.
1120 This task applies only to the
1121 <link linkend='ref-classes-spdx'><filename>spdx</filename></link>
1122 class.
1123 </para>
1124 </section>
1125</section>
1126
1127</chapter>
1128<!--
1129vim: expandtab tw=80 ts=4
1130-->