blob: 811577bb6f6f5c2cecc71136102d769f5944f715 [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='migration'>
6<title>Migrating to a Newer Yocto Project Release</title>
7
8 <para>
9 This chapter provides information you can use to migrate work to a
10 newer Yocto Project release. You can find the same information in the
11 release notes for a given release.
12 </para>
13
14<section id='general-migration-considerations'>
15 <title>General Migration Considerations</title>
16
17 <para>
18 Some considerations are not tied to a specific Yocto Project
19 release.
20 This section presents information you should consider when
21 migrating to any new Yocto Project release.
22 <itemizedlist>
23 <listitem><para><emphasis>Dealing with Customized Recipes</emphasis>:
24 Issues could arise if you take older recipes that contain
25 customizations and simply copy them forward expecting them
26 to work after you migrate to new Yocto Project metadata.
27 For example, suppose you have a recipe in your layer that is
28 a customized version of a core recipe copied from the earlier
29 release, rather than through the use of an append file.
30 When you migrate to a newer version of Yocto Project, the
31 metadata (e.g. perhaps an include file used by the recipe)
32 could have changed in a way that would break the build.
33 Say, for example, a function is removed from an include file
34 and the customized recipe tries to call that function.
35 </para>
36
37 <para>You could "forward-port" all your customizations in your
38 recipe so that everything works for the new release.
39 However, this is not the optimal solution as you would have
40 to repeat this process with each new release if changes
41 occur that give rise to problems.</para>
42
43 <para>The better solution (where practical) is to use append
44 files (<filename>*.bbappend</filename>) to capture any
45 customizations you want to make to a recipe.
46 Doing so, isolates your changes from the main recipe making
47 them much more manageable.
48 However, sometimes it is not practical to use an append
49 file.
50 A good example of this is when introducing a newer or older
51 version of a recipe in another layer.</para>
52 </listitem>
53 <listitem><para><emphasis>Updating Append Files</emphasis>:
54 Since append files generally only contain your customizations,
55 they often do not need to be adjusted for new releases.
56 However, if the <filename>.bbappend</filename> file is
57 specific to a particular version of the recipe (i.e. its
58 name does not use the % wildcard) and the version of the
59 recipe to which it is appending has changed, then you will
60 at a minimum need to rename the append file to match the
61 name of the recipe file.
62 A mismatch between an append file and its corresponding
63 recipe file (<filename>.bb</filename>) will
64 trigger an error during parsing.</para>
65 <para>Depending on the type of customization the append file
66 applies, other incompatibilities might occur when you
67 upgrade.
68 For example, if your append file applies a patch and the
69 recipe to which it is appending is updated to a newer
70 version, the patch might no longer apply.
71 If this is the case and assuming the patch is still needed,
72 you must modify the patch file so that it does apply.
73 </para></listitem>
74 </itemizedlist>
75 </para>
76</section>
77
78<section id='moving-to-the-yocto-project-1.3-release'>
79 <title>Moving to the Yocto Project 1.3 Release</title>
80
81 <para>
82 This section provides migration information for moving to the
83 Yocto Project 1.3 Release from the prior release.
84 </para>
85
86 <section id='1.3-local-configuration'>
87 <title>Local Configuration</title>
88
89 <para>
90 Differences include changes for
91 <link linkend='var-SSTATE_MIRRORS'><filename>SSTATE_MIRRORS</filename></link>
92 and <filename>bblayers.conf</filename>.
93 </para>
94
95 <section id='migration-1.3-sstate-mirrors'>
96 <title>SSTATE_MIRRORS</title>
97
98 <para>
99 The shared state cache (sstate-cache), as pointed to by
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500100 <link linkend='var-SSTATE_DIR'><filename>SSTATE_DIR</filename></link>,
101 by default now has two-character subdirectories to prevent
102 issues arising from too many files in the same directory.
103 Also, native sstate-cache packages, which are built to run
104 on the host system, will go into a subdirectory named using
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500105 the distro ID string.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500106 If you copy the newly structured sstate-cache to a mirror
107 location (either local or remote) and then point to it in
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500108 <link linkend='var-SSTATE_MIRRORS'><filename>SSTATE_MIRRORS</filename></link>,
109 you need to append "PATH" to the end of the mirror URL so that
110 the path used by BitBake before the mirror substitution is
111 appended to the path used to access the mirror.
112 Here is an example:
113 <literallayout class='monospaced'>
114 SSTATE_MIRRORS = "file://.* http://<replaceable>someserver</replaceable>.tld/share/sstate/PATH"
115 </literallayout>
116 </para>
117 </section>
118
119 <section id='migration-1.3-bblayers-conf'>
120 <title>bblayers.conf</title>
121
122 <para>
123 The <filename>meta-yocto</filename> layer consists of two parts
124 that correspond to the Poky reference distribution and the
125 reference hardware Board Support Packages (BSPs), respectively:
126 <filename>meta-yocto</filename> and
127 <filename>meta-yocto-bsp</filename>.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500128 When running BitBake for the first time after upgrading,
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500129 your <filename>conf/bblayers.conf</filename> file will be
130 updated to handle this change and you will be asked to
131 re-run or restart for the changes to take effect.
132 </para>
133 </section>
134 </section>
135
136 <section id='1.3-recipes'>
137 <title>Recipes</title>
138
139 <para>
140 Differences include changes for the following:
141 <itemizedlist>
142 <listitem><para>Python function whitespace</para></listitem>
143 <listitem><para><filename>proto=</filename> in <filename>SRC_URI</filename></para></listitem>
144 <listitem><para><filename>nativesdk</filename></para></listitem>
145 <listitem><para>Task recipes</para></listitem>
146 <listitem><para><filename>IMAGE_FEATURES</filename></para></listitem>
147 <listitem><para>Removed recipes</para></listitem>
148 </itemizedlist>
149 </para>
150
151 <section id='migration-1.3-python-function-whitespace'>
152 <title>Python Function Whitespace</title>
153
154 <para>
155 All Python functions must now use four spaces for indentation.
156 Previously, an inconsistent mix of spaces and tabs existed,
157 which made extending these functions using
158 <filename>_append</filename> or <filename>_prepend</filename>
159 complicated given that Python treats whitespace as
160 syntactically significant.
161 If you are defining or extending any Python functions (e.g.
162 <filename>populate_packages</filename>, <filename>do_unpack</filename>,
163 <filename>do_patch</filename> and so forth) in custom recipes
164 or classes, you need to ensure you are using consistent
165 four-space indentation.
166 </para>
167 </section>
168
169 <section id='migration-1.3-proto=-in-src-uri'>
170 <title>proto= in SRC_URI</title>
171
172 <para>
173 Any use of <filename>proto=</filename> in
174 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
175 needs to be changed to <filename>protocol=</filename>.
176 In particular, this applies to the following URIs:
177 <itemizedlist>
178 <listitem><para><filename>svn://</filename></para></listitem>
179 <listitem><para><filename>bzr://</filename></para></listitem>
180 <listitem><para><filename>hg://</filename></para></listitem>
181 <listitem><para><filename>osc://</filename></para></listitem>
182 </itemizedlist>
183 Other URIs were already using <filename>protocol=</filename>.
184 This change improves consistency.
185 </para>
186 </section>
187
188 <section id='migration-1.3-nativesdk'>
189 <title>nativesdk</title>
190
191 <para>
192 The suffix <filename>nativesdk</filename> is now implemented
193 as a prefix, which simplifies a lot of the packaging code for
194 <filename>nativesdk</filename> recipes.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500195 All custom <filename>nativesdk</filename> recipes, which are
196 relocatable packages that are native to
197 <link linkend='var-SDK_ARCH'><filename>SDK_ARCH</filename></link>,
198 and any references need to be updated to use
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500199 <filename>nativesdk-*</filename> instead of
200 <filename>*-nativesdk</filename>.
201 </para>
202 </section>
203
204 <section id='migration-1.3-task-recipes'>
205 <title>Task Recipes</title>
206
207 <para>
208 "Task" recipes are now known as "Package groups" and have
209 been renamed from <filename>task-*.bb</filename> to
210 <filename>packagegroup-*.bb</filename>.
211 Existing references to the previous <filename>task-*</filename>
212 names should work in most cases as there is an automatic
213 upgrade path for most packages.
214 However, you should update references in your own recipes and
215 configurations as they could be removed in future releases.
216 You should also rename any custom <filename>task-*</filename>
217 recipes to <filename>packagegroup-*</filename>, and change
218 them to inherit <filename>packagegroup</filename> instead of
219 <filename>task</filename>, as well as taking the opportunity
220 to remove anything now handled by
221 <filename>packagegroup.bbclass</filename>, such as providing
222 <filename>-dev</filename> and <filename>-dbg</filename>
223 packages, setting
224 <link linkend='var-LIC_FILES_CHKSUM'><filename>LIC_FILES_CHKSUM</filename></link>,
225 and so forth.
226 See the
227 "<link linkend='ref-classes-packagegroup'><filename>packagegroup.bbclass</filename></link>"
228 section for further details.
229 </para>
230 </section>
231
232 <section id='migration-1.3-image-features'>
233 <title>IMAGE_FEATURES</title>
234
235 <para>
236 Image recipes that previously included "apps-console-core"
237 in <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>
238 should now include "splash" instead to enable the boot-up
239 splash screen.
240 Retaining "apps-console-core" will still include the splash
241 screen but generates a warning.
242 The "apps-x11-core" and "apps-x11-games"
243 <filename>IMAGE_FEATURES</filename> features have been removed.
244 </para>
245 </section>
246
247 <section id='migration-1.3-removed-recipes'>
248 <title>Removed Recipes</title>
249
250 <para>
251 The following recipes have been removed.
252 For most of them, it is unlikely that you would have any
253 references to them in your own
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500254 <link linkend='metadata'>Metadata</link>.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500255 However, you should check your metadata against this list to be sure:
256 <itemizedlist>
257 <listitem><para><emphasis><filename>libx11-trim</filename></emphasis>:
258 Replaced by <filename>libx11</filename>, which has a negligible
259 size difference with modern Xorg.</para></listitem>
260 <listitem><para><emphasis><filename>xserver-xorg-lite</filename></emphasis>:
261 Use <filename>xserver-xorg</filename>, which has a negligible
262 size difference when DRI and GLX modules are not installed.</para></listitem>
263 <listitem><para><emphasis><filename>xserver-kdrive</filename></emphasis>:
264 Effectively unmaintained for many years.</para></listitem>
265 <listitem><para><emphasis><filename>mesa-xlib</filename></emphasis>:
266 No longer serves any purpose.</para></listitem>
267 <listitem><para><emphasis><filename>galago</filename></emphasis>:
268 Replaced by telepathy.</para></listitem>
269 <listitem><para><emphasis><filename>gail</filename></emphasis>:
270 Functionality was integrated into GTK+ 2.13.</para></listitem>
271 <listitem><para><emphasis><filename>eggdbus</filename></emphasis>:
272 No longer needed.</para></listitem>
273 <listitem><para><emphasis><filename>gcc-*-intermediate</filename></emphasis>:
274 The build has been restructured to avoid the need for
275 this step.</para></listitem>
276 <listitem><para><emphasis><filename>libgsmd</filename></emphasis>:
277 Unmaintained for many years.
278 Functionality now provided by
279 <filename>ofono</filename> instead.</para></listitem>
280 <listitem><para><emphasis>contacts, dates, tasks, eds-tools</emphasis>:
281 Largely unmaintained PIM application suite.
282 It has been moved to <filename>meta-gnome</filename>
283 in <filename>meta-openembedded</filename>.</para></listitem>
284 </itemizedlist>
285 In addition to the previously listed changes, the
286 <filename>meta-demoapps</filename> directory has also been removed
287 because the recipes in it were not being maintained and many
288 had become obsolete or broken.
289 Additionally, these recipes were not parsed in the default configuration.
290 Many of these recipes are already provided in an updated and
291 maintained form within the OpenEmbedded community layers such as
292 <filename>meta-oe</filename> and <filename>meta-gnome</filename>.
293 For the remainder, you can now find them in the
294 <filename>meta-extras</filename> repository, which is in the
295 Yocto Project
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500296 <link linkend='source-repositories'>Source Repositories</link>.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500297 </para>
298 </section>
299 </section>
300
301 <section id='1.3-linux-kernel-naming'>
302 <title>Linux Kernel Naming</title>
303
304 <para>
305 The naming scheme for kernel output binaries has been changed to
306 now include
307 <link linkend='var-PE'><filename>PE</filename></link> as part of the
308 filename:
309 <literallayout class='monospaced'>
310 KERNEL_IMAGE_BASE_NAME ?= "${KERNEL_IMAGETYPE}-${PE}-${PV}-${PR}-${MACHINE}-${DATETIME}"
311 </literallayout>
312 </para>
313
314 <para>
315 Because the <filename>PE</filename> variable is not set by default,
316 these binary files could result with names that include two dash
317 characters.
318 Here is an example:
319 <literallayout class='monospaced'>
320 bzImage--3.10.9+git0+cd502a8814_7144bcc4b8-r0-qemux86-64-20130830085431.bin
321 </literallayout>
322 </para>
323 </section>
324</section>
325
326<section id='moving-to-the-yocto-project-1.4-release'>
327 <title>Moving to the Yocto Project 1.4 Release</title>
328
329 <para>
330 This section provides migration information for moving to the
331 Yocto Project 1.4 Release from the prior release.
332 </para>
333
334 <section id='migration-1.4-bitbake'>
335 <title>BitBake</title>
336
337 <para>
338 Differences include the following:
339 <itemizedlist>
340 <listitem><para><emphasis>Comment Continuation:</emphasis>
341 If a comment ends with a line continuation (\) character,
342 then the next line must also be a comment.
343 Any instance where this is not the case, now triggers
344 a warning.
345 You must either remove the continuation character, or be
346 sure the next line is a comment.
347 </para></listitem>
348 <listitem><para><emphasis>Package Name Overrides:</emphasis>
349 The runtime package specific variables
350 <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>,
351 <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>,
352 <link linkend='var-RSUGGESTS'><filename>RSUGGESTS</filename></link>,
353 <link linkend='var-RPROVIDES'><filename>RPROVIDES</filename></link>,
354 <link linkend='var-RCONFLICTS'><filename>RCONFLICTS</filename></link>,
355 <link linkend='var-RREPLACES'><filename>RREPLACES</filename></link>,
356 <link linkend='var-FILES'><filename>FILES</filename></link>,
357 <link linkend='var-ALLOW_EMPTY'><filename>ALLOW_EMPTY</filename></link>,
358 and the pre, post, install, and uninstall script functions
359 <filename>pkg_preinst</filename>,
360 <filename>pkg_postinst</filename>,
361 <filename>pkg_prerm</filename>, and
362 <filename>pkg_postrm</filename> should always have a
363 package name override.
364 For example, use <filename>RDEPENDS_${PN}</filename> for
365 the main package instead of <filename>RDEPENDS</filename>.
366 BitBake uses more strict checks when it parses recipes.
367 </para></listitem>
368 </itemizedlist>
369 </para>
370 </section>
371
372 <section id='migration-1.4-build-behavior'>
373 <title>Build Behavior</title>
374
375 <para>
376 Differences include the following:
377 <itemizedlist>
378 <listitem><para><emphasis>Shared State Code:</emphasis>
379 The shared state code has been optimized to avoid running
380 unnecessary tasks.
381 For example, the following no longer populates the target
382 sysroot since that is not necessary:
383 <literallayout class='monospaced'>
384 $ bitbake -c rootfs <replaceable>some-image</replaceable>
385 </literallayout>
386 Instead, the system just needs to extract the output
387 package contents, re-create the packages, and construct
388 the root filesystem.
389 This change is unlikely to cause any problems unless
390 you have missing declared dependencies.
391 </para></listitem>
392 <listitem><para><emphasis>Scanning Directory Names:</emphasis>
393 When scanning for files in
394 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>,
395 the build system now uses
396 <link linkend='var-FILESOVERRIDES'><filename>FILESOVERRIDES</filename></link>
397 instead of <link linkend='var-OVERRIDES'><filename>OVERRIDES</filename></link>
398 for the directory names.
399 In general, the values previously in
400 <filename>OVERRIDES</filename> are now in
401 <filename>FILESOVERRIDES</filename> as well.
402 However, if you relied upon an additional value
403 you previously added to <filename>OVERRIDES</filename>,
404 you might now need to add it to
405 <filename>FILESOVERRIDES</filename> unless you are already
406 adding it through the
407 <link linkend='var-MACHINEOVERRIDES'><filename>MACHINEOVERRIDES</filename></link>
408 or <link linkend='var-DISTROOVERRIDES'><filename>DISTROOVERRIDES</filename></link>
409 variables, as appropriate.
410 For more related changes, see the
411 "<link linkend='migration-1.4-variables'>Variables</link>"
412 section.
413 </para></listitem>
414 </itemizedlist>
415 </para>
416 </section>
417
418
419 <section id='migration-1.4-proxies-and-fetching-source'>
420 <title>Proxies and Fetching Source</title>
421
422 <para>
423 A new <filename>oe-git-proxy</filename> script has been added to
424 replace previous methods of handling proxies and fetching source
425 from Git.
426 See the <filename>meta-yocto/conf/site.conf.sample</filename> file
427 for information on how to use this script.
428 </para>
429 </section>
430
431 <section id='migration-1.4-custom-interfaces-file-netbase-change'>
432 <title>Custom Interfaces File (netbase change)</title>
433
434 <para>
435 If you have created your own custom
436 <filename>etc/network/interfaces</filename> file by creating
437 an append file for the <filename>netbase</filename> recipe,
438 you now need to create an append file for the
439 <filename>init-ifupdown</filename> recipe instead, which you can
440 find in the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500441 <link linkend='source-directory'>Source Directory</link>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500442 at <filename>meta/recipes-core/init-ifupdown</filename>.
443 For information on how to use append files, see the
444 "<ulink url='&YOCTO_DOCS_DEV_URL;#using-bbappend-files'>Using .bbappend Files</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500445 in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500446 </para>
447 </section>
448
449 <section id='migration-1.4-remote-debugging'>
450 <title>Remote Debugging</title>
451
452 <para>
453 Support for remote debugging with the Eclipse IDE is now
454 separated into an image feature
455 (<filename>eclipse-debug</filename>) that corresponds to the
456 <filename>packagegroup-core-eclipse-debug</filename> package group.
457 Previously, the debugging feature was included through the
458 <filename>tools-debug</filename> image feature, which corresponds
459 to the <filename>packagegroup-core-tools-debug</filename>
460 package group.
461 </para>
462 </section>
463
464 <section id='migration-1.4-variables'>
465 <title>Variables</title>
466
467 <para>
468 The following variables have changed:
469 <itemizedlist>
470 <listitem><para><emphasis><filename>SANITY_TESTED_DISTROS</filename>:</emphasis>
471 This variable now uses a distribution ID, which is composed
472 of the host distributor ID followed by the release.
473 Previously,
474 <link linkend='var-SANITY_TESTED_DISTROS'><filename>SANITY_TESTED_DISTROS</filename></link>
475 was composed of the description field.
476 For example, "Ubuntu 12.10" becomes "Ubuntu-12.10".
477 You do not need to worry about this change if you are not
478 specifically setting this variable, or if you are
479 specifically setting it to "".
480 </para></listitem>
481 <listitem><para><emphasis><filename>SRC_URI</filename>:</emphasis>
482 The <filename>${</filename><link linkend='var-PN'><filename>PN</filename></link><filename>}</filename>,
483 <filename>${</filename><link linkend='var-PF'><filename>PF</filename></link><filename>}</filename>,
484 <filename>${</filename><link linkend='var-P'><filename>P</filename></link><filename>}</filename>,
485 and <filename>FILE_DIRNAME</filename> directories have been
486 dropped from the default value of the
487 <link linkend='var-FILESPATH'><filename>FILESPATH</filename></link>
488 variable, which is used as the search path for finding files
489 referred to in
490 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>.
491 If you have a recipe that relied upon these directories,
492 which would be unusual, then you will need to add the
493 appropriate paths within the recipe or, alternatively,
494 rearrange the files.
495 The most common locations are still covered by
496 <filename>${BP}</filename>, <filename>${BPN}</filename>,
497 and "files", which all remain in the default value of
498 <link linkend='var-FILESPATH'><filename>FILESPATH</filename></link>.
499 </para></listitem>
500 </itemizedlist>
501 </para>
502 </section>
503
504 <section id='migration-target-package-management-with-rpm'>
505 <title>Target Package Management with RPM</title>
506
507 <para>
508 If runtime package management is enabled and the RPM backend
509 is selected, Smart is now installed for package download, dependency
510 resolution, and upgrades instead of Zypper.
511 For more information on how to use Smart, run the following command
512 on the target:
513 <literallayout class='monospaced'>
514 smart --help
515 </literallayout>
516 </para>
517 </section>
518
519 <section id='migration-1.4-recipes-moved'>
520 <title>Recipes Moved</title>
521
522 <para>
523 The following recipes were moved from their previous locations
524 because they are no longer used by anything in
525 the OpenEmbedded-Core:
526 <itemizedlist>
527 <listitem><para><emphasis><filename>clutter-box2d</filename>:</emphasis>
528 Now resides in the <filename>meta-oe</filename> layer.
529 </para></listitem>
530 <listitem><para><emphasis><filename>evolution-data-server</filename>:</emphasis>
531 Now resides in the <filename>meta-gnome</filename> layer.
532 </para></listitem>
533 <listitem><para><emphasis><filename>gthumb</filename>:</emphasis>
534 Now resides in the <filename>meta-gnome</filename> layer.
535 </para></listitem>
536 <listitem><para><emphasis><filename>gtkhtml2</filename>:</emphasis>
537 Now resides in the <filename>meta-oe</filename> layer.
538 </para></listitem>
539 <listitem><para><emphasis><filename>gupnp</filename>:</emphasis>
540 Now resides in the <filename>meta-multimedia</filename> layer.
541 </para></listitem>
542 <listitem><para><emphasis><filename>gypsy</filename>:</emphasis>
543 Now resides in the <filename>meta-oe</filename> layer.
544 </para></listitem>
545 <listitem><para><emphasis><filename>libcanberra</filename>:</emphasis>
546 Now resides in the <filename>meta-gnome</filename> layer.
547 </para></listitem>
548 <listitem><para><emphasis><filename>libgdata</filename>:</emphasis>
549 Now resides in the <filename>meta-gnome</filename> layer.
550 </para></listitem>
551 <listitem><para><emphasis><filename>libmusicbrainz</filename>:</emphasis>
552 Now resides in the <filename>meta-multimedia</filename> layer.
553 </para></listitem>
554 <listitem><para><emphasis><filename>metacity</filename>:</emphasis>
555 Now resides in the <filename>meta-gnome</filename> layer.
556 </para></listitem>
557 <listitem><para><emphasis><filename>polkit</filename>:</emphasis>
558 Now resides in the <filename>meta-oe</filename> layer.
559 </para></listitem>
560 <listitem><para><emphasis><filename>zeroconf</filename>:</emphasis>
561 Now resides in the <filename>meta-networking</filename> layer.
562 </para></listitem>
563 </itemizedlist>
564 </para>
565 </section>
566
567 <section id='migration-1.4-removals-and-renames'>
568 <title>Removals and Renames</title>
569
570 <para>
571 The following list shows what has been removed or renamed:
572 <itemizedlist>
573 <listitem><para><emphasis><filename>evieext</filename>:</emphasis>
574 Removed because it has been removed from
575 <filename>xserver</filename> since 2008.
576 </para></listitem>
577 <listitem><para><emphasis>Gtk+ DirectFB:</emphasis>
578 Removed support because upstream Gtk+ no longer supports it
579 as of version 2.18.
580 </para></listitem>
581 <listitem><para><emphasis><filename>libxfontcache / xfontcacheproto</filename>:</emphasis>
582 Removed because they were removed from the Xorg server in 2008.
583 </para></listitem>
584 <listitem><para><emphasis><filename>libxp / libxprintapputil / libxprintutil / printproto</filename>:</emphasis>
585 Removed because the XPrint server was removed from
586 Xorg in 2008.
587 </para></listitem>
588 <listitem><para><emphasis><filename>libxtrap / xtrapproto</filename>:</emphasis>
589 Removed because their functionality was broken upstream.
590 </para></listitem>
591 <listitem><para><emphasis>linux-yocto 3.0 kernel:</emphasis>
592 Removed with linux-yocto 3.8 kernel being added.
593 The linux-yocto 3.2 and linux-yocto 3.4 kernels remain
594 as part of the release.
595 </para></listitem>
596 <listitem><para><emphasis><filename>lsbsetup</filename>:</emphasis>
597 Removed with functionality now provided by
598 <filename>lsbtest</filename>.
599 </para></listitem>
600 <listitem><para><emphasis><filename>matchbox-stroke</filename>:</emphasis>
601 Removed because it was never more than a proof-of-concept.
602 </para></listitem>
603 <listitem><para><emphasis><filename>matchbox-wm-2 / matchbox-theme-sato-2</filename>:</emphasis>
604 Removed because they are not maintained.
605 However, <filename>matchbox-wm</filename> and
606 <filename>matchbox-theme-sato</filename> are still
607 provided.
608 </para></listitem>
609 <listitem><para><emphasis><filename>mesa-dri</filename>:</emphasis>
610 Renamed to <filename>mesa</filename>.
611 </para></listitem>
612 <listitem><para><emphasis><filename>mesa-xlib</filename>:</emphasis>
613 Removed because it was no longer useful.
614 </para></listitem>
615 <listitem><para><emphasis><filename>mutter</filename>:</emphasis>
616 Removed because nothing ever uses it and the recipe is
617 very old.
618 </para></listitem>
619 <listitem><para><emphasis><filename>orinoco-conf</filename>:</emphasis>
620 Removed because it has become obsolete.
621 </para></listitem>
622 <listitem><para><emphasis><filename>update-modules</filename>:</emphasis>
623 Removed because it is no longer used.
624 The kernel module <filename>postinstall</filename> and
625 <filename>postrm</filename> scripts can now do the same
626 task without the use of this script.
627 </para></listitem>
628 <listitem><para><emphasis><filename>web</filename>:</emphasis>
629 Removed because it is not maintained. Superseded by
630 <filename>web-webkit</filename>.
631 </para></listitem>
632 <listitem><para><emphasis><filename>xf86bigfontproto</filename>:</emphasis>
633 Removed because upstream it has been disabled by default
634 since 2007.
635 Nothing uses <filename>xf86bigfontproto</filename>.
636 </para></listitem>
637 <listitem><para><emphasis><filename>xf86rushproto</filename>:</emphasis>
638 Removed because its dependency in
639 <filename>xserver</filename> was spurious and it was
640 removed in 2005.
641 </para></listitem>
642 <listitem><para><emphasis><filename>zypper / libzypp / sat-solver</filename>:</emphasis>
643 Removed and been functionally replaced with Smart
644 (<filename>python-smartpm</filename>) when RPM packaging
645 is used and package management is enabled on the target.
646 </para></listitem>
647 </itemizedlist>
648 </para>
649 </section>
650</section>
651
652<section id='moving-to-the-yocto-project-1.5-release'>
653 <title>Moving to the Yocto Project 1.5 Release</title>
654
655 <para>
656 This section provides migration information for moving to the
657 Yocto Project 1.5 Release from the prior release.
658 </para>
659
660 <section id='migration-1.5-host-dependency-changes'>
661 <title>Host Dependency Changes</title>
662
663 <para>
664 The OpenEmbedded build system now has some additional requirements
665 on the host system:
666 <itemizedlist>
667 <listitem><para>Python 2.7.3+</para></listitem>
668 <listitem><para>Tar 1.24+</para></listitem>
669 <listitem><para>Git 1.7.8+</para></listitem>
670 <listitem><para>Patched version of Make if you are using
671 3.82.
672 Most distributions that provide Make 3.82 use the patched
673 version.</para></listitem>
674 </itemizedlist>
675 If the Linux distribution you are using on your build host
676 does not provide packages for these, you can install and use
677 the Buildtools tarball, which provides an SDK-like environment
678 containing them.
679 </para>
680
681 <para>
682 For more information on this requirement, see the
683 "<link linkend='required-git-tar-and-python-versions'>Required Git, tar, and Python Versions</link>"
684 section.
685 </para>
686 </section>
687
688 <section id='migration-1.5-atom-pc-bsp'>
689 <title><filename>atom-pc</filename> Board Support Package (BSP)</title>
690
691 <para>
692 The <filename>atom-pc</filename> hardware reference BSP has been
693 replaced by a <filename>genericx86</filename> BSP.
694 This BSP is not necessarily guaranteed to work on all x86
695 hardware, but it will run on a wider range of systems than the
696 <filename>atom-pc</filename> did.
697 <note>
698 Additionally, a <filename>genericx86-64</filename> BSP has
699 been added for 64-bit Atom systems.
700 </note>
701 </para>
702 </section>
703
704 <section id='migration-1.5-bitbake'>
705 <title>BitBake</title>
706
707 <para>
708 The following changes have been made that relate to BitBake:
709 <itemizedlist>
710 <listitem><para>
711 BitBake now supports a <filename>_remove</filename>
712 operator.
713 The addition of this operator means you will have to
714 rename any items in recipe space (functions, variables)
715 whose names currently contain
716 <filename>_remove_</filename> or end with
717 <filename>_remove</filename> to avoid unexpected behavior.
718 </para></listitem>
719 <listitem><para>
720 BitBake's global method pool has been removed.
721 This method is not particularly useful and led to clashes
722 between recipes containing functions that had the
723 same name.</para></listitem>
724 <listitem><para>
725 The "none" server backend has been removed.
726 The "process" server backend has been serving well as the
727 default for a long time now.</para></listitem>
728 <listitem><para>
729 The <filename>bitbake-runtask</filename> script has been
730 removed.</para></listitem>
731 <listitem><para>
732 <filename>${</filename><link linkend='var-P'><filename>P</filename></link><filename>}</filename>
733 and
734 <filename>${</filename><link linkend='var-PF'><filename>PF</filename></link><filename>}</filename>
735 are no longer added to
736 <link linkend='var-PROVIDES'><filename>PROVIDES</filename></link>
737 by default in <filename>bitbake.conf</filename>.
738 These version-specific <filename>PROVIDES</filename>
739 items were seldom used.
740 Attempting to use them could result in two versions being
741 built simultaneously rather than just one version due to
742 the way BitBake resolves dependencies.</para></listitem>
743 </itemizedlist>
744 </para>
745 </section>
746
747 <section id='migration-1.5-qa-warnings'>
748 <title>QA Warnings</title>
749
750 <para>
751 The following changes have been made to the package QA checks:
752 <itemizedlist>
753 <listitem><para>
754 If you have customized
755 <link linkend='var-ERROR_QA'><filename>ERROR_QA</filename></link>
756 or <link linkend='var-WARN_QA'><filename>WARN_QA</filename></link>
757 values in your configuration, check that they contain all of
758 the issues that you wish to be reported.
759 Previous Yocto Project versions contained a bug that meant
760 that any item not mentioned in <filename>ERROR_QA</filename>
761 or <filename>WARN_QA</filename> would be treated as a
762 warning.
763 Consequently, several important items were not already in
764 the default value of <filename>WARN_QA</filename>.
765 All of the possible QA checks are now documented in the
766 "<link linkend='ref-classes-insane'><filename>insane.bbclass</filename></link>"
767 section.</para></listitem>
768 <listitem><para>
769 An additional QA check has been added to check if
770 <filename>/usr/share/info/dir</filename> is being installed.
771 Your recipe should delete this file within
772 <link linkend='ref-tasks-install'><filename>do_install</filename></link>
773 if "make install" is installing it.
774 </para></listitem>
775 <listitem><para>
776 If you are using the buildhistory class, the check for the
777 package version going backwards is now controlled using a
778 standard QA check.
779 Thus, if you have customized your
780 <filename>ERROR_QA</filename> or
781 <filename>WARN_QA</filename> values and still wish to have
782 this check performed, you should add
783 "version-going-backwards" to your value for one or the
784 other variables depending on how you wish it to be handled.
785 See the documented QA checks in the
786 "<link linkend='ref-classes-insane'><filename>insane.bbclass</filename></link>"
787 section.
788 </para></listitem>
789 </itemizedlist>
790 </para>
791 </section>
792
793 <section id='migration-1.5-directory-layout-changes'>
794 <title>Directory Layout Changes</title>
795
796 <para>
797 The following directory changes exist:
798 <itemizedlist>
799 <listitem><para>
800 Output SDK installer files are now named to include the
801 image name and tuning architecture through the
802 <link linkend='var-SDK_NAME'><filename>SDK_NAME</filename></link>
803 variable.</para></listitem>
804 <listitem><para>
805 Images and related files are now installed into a directory
806 that is specific to the machine, instead of a parent
807 directory containing output files for multiple machines.
808 The
809 <link linkend='var-DEPLOY_DIR_IMAGE'><filename>DEPLOY_DIR_IMAGE</filename></link>
810 variable continues to point to the directory containing
811 images for the current
812 <link linkend='var-MACHINE'><filename>MACHINE</filename></link>
813 and should be used anywhere there is a need to refer to
814 this directory.
815 The <filename>runqemu</filename> script now uses this
816 variable to find images and kernel binaries and will use
817 BitBake to determine the directory.
818 Alternatively, you can set the
819 <filename>DEPLOY_DIR_IMAGE</filename> variable in the
820 external environment.</para></listitem>
821 <listitem><para>
822 When buildhistory is enabled, its output is now written
823 under the
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500824 <link linkend='build-directory'>Build Directory</link>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500825 rather than
826 <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>.
827 Doing so makes it easier to delete
828 <filename>TMPDIR</filename> and preserve the build history.
829 Additionally, data for produced SDKs is now split by
830 <link linkend='var-IMAGE_NAME'><filename>IMAGE_NAME</filename></link>.
831 </para></listitem>
832 <listitem><para>
833 The <filename>pkgdata</filename> directory produced as
834 part of the packaging process has been collapsed into a
835 single machine-specific directory.
836 This directory is located under
837 <filename>sysroots</filename> and uses a machine-specific
838 name (i.e.
839 <filename>tmp/sysroots/<replaceable>machine</replaceable>/pkgdata</filename>).
840 </para></listitem>
841 </itemizedlist>
842 </para>
843 </section>
844
845 <section id='migration-1.5-shortened-git-srcrev-values'>
846 <title>Shortened Git <filename>SRCREV</filename> Values</title>
847
848 <para>
849 BitBake will now shorten revisions from Git repositories from the
850 normal 40 characters down to 10 characters within
851 <link linkend='var-SRCPV'><filename>SRCPV</filename></link>
852 for improved usability in path and file names.
853 This change should be safe within contexts where these revisions
854 are used because the chances of spatially close collisions
855 is very low.
856 Distant collisions are not a major issue in the way
857 the values are used.
858 </para>
859 </section>
860
861 <section id='migration-1.5-image-features'>
862 <title><filename>IMAGE_FEATURES</filename></title>
863
864 <para>
865 The following changes have been made that relate to
866 <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>:
867 <itemizedlist>
868 <listitem><para>
869 The value of
870 <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>
871 is now validated to ensure invalid feature items are not
872 added.
873 Some users mistakenly add package names to this variable
874 instead of using
875 <link linkend='var-IMAGE_INSTALL'><filename>IMAGE_INSTALL</filename></link>
876 in order to have the package added to the image, which does
877 not work.
878 This change is intended to catch those kinds of situations.
879 Valid <filename>IMAGE_FEATURES</filename> are drawn from
880 <link linkend='var-PACKAGE_GROUP'><filename>PACKAGE_GROUP</filename></link>
881 definitions,
882 <link linkend='var-COMPLEMENTARY_GLOB'><filename>COMPLEMENTARY_GLOB</filename></link>
883 and a new "validitems" varflag on
884 <filename>IMAGE_FEATURES</filename>.
885 The "validitems" varflag change allows additional features
886 to be added if they are not provided using the previous
887 two mechanisms.
888 </para></listitem>
889 <listitem><para>
890 The previously deprecated "apps-console-core"
891 <filename>IMAGE_FEATURES</filename> item is no longer
892 supported.
893 Add "splash" to <filename>IMAGE_FEATURES</filename> if you
894 wish to have the splash screen enabled, since this is
895 all that apps-console-core was doing.</para></listitem>
896 </itemizedlist>
897 </para>
898 </section>
899
900 <section id='migration-1.5-run'>
901 <title><filename>/run</filename></title>
902
903 <para>
904 The <filename>/run</filename> directory from the Filesystem
905 Hierarchy Standard 3.0 has been introduced.
906 You can find some of the implications for this change
907 <ulink url='http://cgit.openembedded.org/openembedded-core/commit/?id=0e326280a15b0f2c4ef2ef4ec441f63f55b75873'>here</ulink>.
908 The change also means that recipes that install files to
909 <filename>/var/run</filename> must be changed.
910 You can find a guide on how to make these changes
911 <ulink url='http://permalink.gmane.org/gmane.comp.handhelds.openembedded/58530'>here</ulink>.
912 </para>
913 </section>
914
915 <section id='migration-1.5-removal-of-package-manager-database-within-image-recipes'>
916 <title>Removal of Package Manager Database Within Image Recipes</title>
917
918 <para>
919 The image <filename>core-image-minimal</filename> no longer adds
920 <filename>remove_packaging_data_files</filename> to
921 <link linkend='var-ROOTFS_POSTPROCESS_COMMAND'><filename>ROOTFS_POSTPROCESS_COMMAND</filename></link>.
922 This addition is now handled automatically when "package-management"
923 is not in
924 <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>.
925 If you have custom image recipes that make this addition,
926 you should remove the lines, as they are not needed and might
927 interfere with correct operation of postinstall scripts.
928 </para>
929 </section>
930
931 <section id='migration-1.5-images-now-rebuild-only-on-changes-instead-of-every-time'>
932 <title>Images Now Rebuild Only on Changes Instead of Every Time</title>
933
934 <para>
935 The
936 <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
937 and other related image
938 construction tasks are no longer marked as "nostamp".
939 Consequently, they will only be re-executed when their inputs have
940 changed.
941 Previous versions of the OpenEmbedded build system always rebuilt
942 the image when requested rather when necessary.
943 </para>
944 </section>
945
946 <section id='migration-1.5-task-recipes'>
947 <title>Task Recipes</title>
948
949 <para>
950 The previously deprecated <filename>task.bbclass</filename> has
951 now been dropped.
952 For recipes that previously inherited from this class, you should
953 rename them from <filename>task-*</filename> to
954 <filename>packagegroup-*</filename> and inherit packagegroup
955 instead.
956 </para>
957
958 <para>
959 For more information, see the
960 "<link linkend='ref-classes-packagegroup'><filename>packagegroup.bbclass</filename></link>"
961 section.
962 </para>
963 </section>
964
965 <section id='migration-1.5-busybox'>
966 <title>BusyBox</title>
967
968 <para>
969 By default, we now split BusyBox into two binaries:
970 one that is suid root for those components that need it, and
971 another for the rest of the components.
972 Splitting BusyBox allows for optimization that eliminates the
973 <filename>tinylogin</filename> recipe as recommended by upstream.
974 You can disable this split by setting
975 <link linkend='var-BUSYBOX_SPLIT_SUID'><filename>BUSYBOX_SPLIT_SUID</filename></link>
976 to "0".
977 </para>
978 </section>
979
980 <section id='migration-1.5-automated-image-testing'>
981 <title>Automated Image Testing</title>
982
983 <para>
984 A new automated image testing framework has been added
985 through the
Patrick Williamsf1e5d692016-03-30 15:21:19 -0500986 <link linkend='ref-classes-testimage*'><filename>testimage.bbclass</filename></link>
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500987 class.
988 This framework replaces the older
989 <filename>imagetest-qemu</filename> framework.
990 </para>
991
992 <para>
993 You can learn more about performing automated image tests in the
994 "<ulink url='&YOCTO_DOCS_DEV_URL;#performing-automated-runtime-testing'>Performing Automated Runtime Testing</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -0500995 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -0500996 </para>
997 </section>
998
999 <section id='migration-1.5-build-history'>
1000 <title>Build History</title>
1001
1002 <para>
1003 Following are changes to Build History:
1004 <itemizedlist>
1005 <listitem><para>
1006 Installed package sizes:
1007 <filename>installed-package-sizes.txt</filename> for an
1008 image now records the size of the files installed by each
1009 package instead of the size of each compressed package
1010 archive file.</para></listitem>
1011 <listitem><para>
1012 The dependency graphs (<filename>depends*.dot</filename>)
1013 now use the actual package names instead of replacing
1014 dashes, dots and plus signs with underscores.
1015 </para></listitem>
1016 <listitem><para>
1017 The <filename>buildhistory-diff</filename> and
1018 <filename>buildhistory-collect-srcrevs</filename>
1019 utilities have improved command-line handling.
1020 Use the <filename>--help</filename> option for
1021 each utility for more information on the new syntax.
1022 </para></listitem>
1023 </itemizedlist>
1024 For more information on Build History, see the
1025 "<link linkend='maintaining-build-output-quality'>Maintaining Build Output Quality</link>"
1026 section.
1027 </para>
1028 </section>
1029
1030 <section id='migration-1.5-udev'>
1031 <title><filename>udev</filename></title>
1032
1033 <para>
1034 Following are changes to <filename>udev</filename>:
1035 <itemizedlist>
1036 <listitem><para>
1037 <filename>udev</filename> no longer brings in
1038 <filename>udev-extraconf</filename> automatically
1039 through
1040 <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>,
1041 since this was originally intended to be optional.
1042 If you need the extra rules, then add
1043 <filename>udev-extraconf</filename> to your image.
1044 </para></listitem>
1045 <listitem><para>
1046 <filename>udev</filename> no longer brings in
1047 <filename>pciutils-ids</filename> or
1048 <filename>usbutils-ids</filename> through
1049 <filename>RRECOMMENDS</filename>.
1050 These are not needed by <filename>udev</filename> itself
1051 and removing them saves around 350KB.
1052 </para></listitem>
1053 </itemizedlist>
1054 </para>
1055 </section>
1056
1057 <section id='migration-1.5-removed-renamed-recipes'>
1058 <title>Removed and Renamed Recipes</title>
1059
1060 <itemizedlist>
1061 <listitem><para>
1062 The <filename>linux-yocto</filename> 3.2 kernel has been
1063 removed.</para></listitem>
1064 <listitem><para>
1065 <filename>libtool-nativesdk</filename> has been renamed to
1066 <filename>nativesdk-libtool</filename>.</para></listitem>
1067 <listitem><para>
1068 <filename>tinylogin</filename> has been removed.
1069 It has been replaced by a suid portion of Busybox.
1070 See the
1071 "<link linkend='migration-1.5-busybox'>BusyBox</link>" section
1072 for more information.</para></listitem>
1073 <listitem><para>
1074 <filename>external-python-tarball</filename> has been renamed
1075 to <filename>buildtools-tarball</filename>.
1076 </para></listitem>
1077 <listitem><para>
1078 <filename>web-webkit</filename> has been removed.
1079 It has been functionally replaced by
1080 <filename>midori</filename>.</para></listitem>
1081 <listitem><para>
1082 <filename>imake</filename> has been removed.
1083 It is no longer needed by any other recipe.
1084 </para></listitem>
1085 <listitem><para>
1086 <filename>transfig-native</filename> has been removed.
1087 It is no longer needed by any other recipe.
1088 </para></listitem>
1089 <listitem><para>
1090 <filename>anjuta-remote-run</filename> has been removed.
1091 Anjuta IDE integration has not been officially supported for
1092 several releases.</para></listitem>
1093 </itemizedlist>
1094 </section>
1095
1096 <section id='migration-1.5-other-changes'>
1097 <title>Other Changes</title>
1098
1099 <para>
1100 Following is a list of short entries describing other changes:
1101 <itemizedlist>
1102 <listitem><para>
1103 <filename>run-postinsts</filename>: Make this generic.
1104 </para></listitem>
1105 <listitem><para>
1106 <filename>base-files</filename>: Remove the unnecessary
1107 <filename>media/</filename><replaceable>xxx</replaceable> directories.
1108 </para></listitem>
1109 <listitem><para>
1110 <filename>alsa-state</filename>: Provide an empty
1111 <filename>asound.conf</filename> by default.
1112 </para></listitem>
1113 <listitem><para>
1114 <filename>classes/image</filename>: Ensure
1115 <link linkend='var-BAD_RECOMMENDATIONS'><filename>BAD_RECOMMENDATIONS</filename></link>
1116 supports pre-renamed package names.</para></listitem>
1117 <listitem><para>
1118 <filename>classes/rootfs_rpm</filename>: Implement
1119 <link linkend='var-BAD_RECOMMENDATIONS'><filename>BAD_RECOMMENDATIONS</filename></link>
1120 for RPM.</para></listitem>
1121 <listitem><para>
1122 <filename>systemd</filename>: Remove
1123 <filename>systemd_unitdir</filename> if
1124 <filename>systemd</filename> is not in
1125 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
1126 </para></listitem>
1127 <listitem><para>
1128 <filename>systemd</filename>: Remove
1129 <filename>init.d</filename> dir if
1130 <filename>systemd</filename> unit file is present and
1131 <filename>sysvinit</filename> is not a distro feature.
1132 </para></listitem>
1133 <listitem><para>
1134 <filename>libpam</filename>: Deny all services for the
1135 <filename>OTHER</filename> entries.
1136 </para></listitem>
1137 <listitem><para>
1138 <filename>image.bbclass</filename>: Move
1139 <filename>runtime_mapping_rename</filename> to avoid
1140 conflict with <filename>multilib</filename>.
1141 See
1142 <ulink url='https://bugzilla.yoctoproject.org/show_bug.cgi?id=4993'><filename>YOCTO #4993</filename></ulink>
1143 in Bugzilla for more information.
1144 </para></listitem>
1145 <listitem><para>
1146 <filename>linux-dtb</filename>: Use kernel build system
1147 to generate the <filename>dtb</filename> files.
1148 </para></listitem>
1149 <listitem><para>
1150 <filename>kern-tools</filename>: Switch from guilt to
1151 new <filename>kgit-s2q</filename> tool.
1152 </para></listitem>
1153 </itemizedlist>
1154 </para>
1155 </section>
1156</section>
1157
1158<section id='moving-to-the-yocto-project-1.6-release'>
1159 <title>Moving to the Yocto Project 1.6 Release</title>
1160
1161 <para>
1162 This section provides migration information for moving to the
1163 Yocto Project 1.6 Release from the prior release.
1164 </para>
1165
1166
1167 <section id='migration-1.6-archiver-class'>
1168 <title><filename>archiver</filename> Class</title>
1169
1170 <para>
1171 The
1172 <link linkend='ref-classes-archiver'><filename>archiver</filename></link>
1173 class has been rewritten and its configuration has been simplified.
1174 For more details on the source archiver, see the
1175 "<ulink url='&YOCTO_DOCS_DEV_URL;#maintaining-open-source-license-compliance-during-your-products-lifecycle'>Maintaining Open Source License Compliance During Your Product's Lifecycle</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001176 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001177 </para>
1178 </section>
1179
1180 <section id='migration-1.6-packaging-changes'>
1181 <title>Packaging Changes</title>
1182
1183 <para>
1184 The following packaging changes have been made:
1185 <itemizedlist>
1186 <listitem><para>
1187 The <filename>binutils</filename> recipe no longer produces
1188 a <filename>binutils-symlinks</filename> package.
1189 <filename>update-alternatives</filename> is now used to
1190 handle the preferred <filename>binutils</filename>
1191 variant on the target instead.
1192 </para></listitem>
1193 <listitem><para>
1194 The tc (traffic control) utilities have been split out of
1195 the main <filename>iproute2</filename> package and put
1196 into the <filename>iproute2-tc</filename> package.
1197 </para></listitem>
1198 <listitem><para>
1199 The <filename>gtk-engines</filename> schemas have been
1200 moved to a dedicated
1201 <filename>gtk-engines-schemas</filename> package.
1202 </para></listitem>
1203 <listitem><para>
1204 The <filename>armv7a</filename> with thumb package
1205 architecture suffix has changed.
1206 The suffix for these packages with the thumb
1207 optimization enabled is "t2" as it should be.
1208 Use of this suffix was not the case in the 1.5 release.
1209 Architecture names will change within package feeds as a
1210 result.
1211 </para></listitem>
1212 </itemizedlist>
1213 </para>
1214 </section>
1215
1216 <section id='migration-1.6-bitbake'>
1217 <title>BitBake</title>
1218
1219 <para>
1220 The following changes have been made to
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001221 <link linkend='bitbake-term'>BitBake</link>.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001222 </para>
1223
1224 <section id='migration-1.6-matching-branch-requirement-for-git-fetching'>
1225 <title>Matching Branch Requirement for Git Fetching</title>
1226
1227 <para>
1228 When fetching source from a Git repository using
1229 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>,
1230 BitBake will now validate the
1231 <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
1232 value against the branch.
1233 You can specify the branch using the following form:
1234 <literallayout class='monospaced'>
1235 SRC_URI = "git://server.name/repository;branch=<replaceable>branchname</replaceable>"
1236 </literallayout>
1237 If you do not specify a branch, BitBake looks
1238 in the default "master" branch.
1239 </para>
1240
1241 <para>
1242 Alternatively, if you need to bypass this check (e.g.
1243 if you are fetching a revision corresponding to a tag that
1244 is not on any branch), you can add ";nobranch=1" to
1245 the end of the URL within <filename>SRC_URI</filename>.
1246 </para>
1247 </section>
1248
1249 <section id='migration-1.6-bitbake-deps'>
1250 <title>Python Definition substitutions</title>
1251
1252 <para>
1253 BitBake had some previously deprecated Python definitions
1254 within its <filename>bb</filename> module removed.
1255 You should use their sub-module counterparts instead:
1256 <itemizedlist>
1257 <listitem><para><filename>bb.MalformedUrl</filename>:
1258 Use <filename>bb.fetch.MalformedUrl</filename>.
1259 </para></listitem>
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001260 <listitem><para><filename>bb.encodeurl</filename>:
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001261 Use <filename>bb.fetch.encodeurl</filename>.
1262 </para></listitem>
1263 <listitem><para><filename>bb.decodeurl</filename>:
1264 Use <filename>bb.fetch.decodeurl</filename>
1265 </para></listitem>
1266 <listitem><para><filename>bb.mkdirhier</filename>:
1267 Use <filename>bb.utils.mkdirhier</filename>.
1268 </para></listitem>
1269 <listitem><para><filename>bb.movefile</filename>:
1270 Use <filename>bb.utils.movefile</filename>.
1271 </para></listitem>
1272 <listitem><para><filename>bb.copyfile</filename>:
1273 Use <filename>bb.utils.copyfile</filename>.
1274 </para></listitem>
1275 <listitem><para><filename>bb.which</filename>:
1276 Use <filename>bb.utils.which</filename>.
1277 </para></listitem>
1278 <listitem><para><filename>bb.vercmp_string</filename>:
1279 Use <filename>bb.utils.vercmp_string</filename>.
1280 </para></listitem>
1281 <listitem><para><filename>bb.vercmp</filename>:
1282 Use <filename>bb.utils.vercmp</filename>.
1283 </para></listitem>
1284 </itemizedlist>
1285 </para>
1286 </section>
1287
1288 <section id='migration-1.6-bitbake-fetcher'>
1289 <title>SVK Fetcher</title>
1290
1291 <para>
1292 The SVK fetcher has been removed from BitBake.
1293 </para>
1294 </section>
1295
1296 <section id='migration-1.6-bitbake-console-output'>
1297 <title>Console Output Error Redirection</title>
1298
1299 <para>
1300 The BitBake console UI will now output errors to
1301 <filename>stderr</filename> instead of
1302 <filename>stdout</filename>.
1303 Consequently, if you are piping or redirecting the output of
1304 <filename>bitbake</filename> to somewhere else, and you wish
1305 to retain the errors, you will need to add
1306 <filename>2>&amp;1</filename> (or something similar) to the
1307 end of your <filename>bitbake</filename> command line.
1308 </para>
1309 </section>
1310
1311 <section id='migration-1.6-task-taskname-overrides'>
1312 <title><filename>task-</filename><replaceable>taskname</replaceable> Overrides</title>
1313
1314 <para>
1315 <filename>task-</filename><replaceable>taskname</replaceable> overrides have been
1316 adjusted so that tasks whose names contain underscores have the
1317 underscores replaced by hyphens for the override so that they
1318 now function properly.
1319 For example, the task override for
1320 <link linkend='ref-tasks-populate_sdk'><filename>do_populate_sdk</filename></link>
1321 is <filename>task-populate-sdk</filename>.
1322 </para>
1323 </section>
1324 </section>
1325
1326 <section id='migration-1.6-variable-changes'>
1327 <title>Changes to Variables</title>
1328
1329 <para>
1330 The following variables have changed.
1331 For information on the OpenEmbedded build system variables, see the
1332 "<link linkend='ref-variables-glos'>Variables Glossary</link>" Chapter.
1333 </para>
1334
1335 <section id='migration-1.6-variable-changes-TMPDIR'>
1336 <title><filename>TMPDIR</filename></title>
1337
1338 <para>
1339 <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
1340 can no longer be on an NFS mount.
1341 NFS does not offer full POSIX locking and inode consistency
1342 and can cause unexpected issues if used to store
1343 <filename>TMPDIR</filename>.
1344 </para>
1345
1346 <para>
1347 The check for this occurs on startup.
1348 If <filename>TMPDIR</filename> is detected on an NFS mount,
1349 an error occurs.
1350 </para>
1351 </section>
1352
1353 <section id='migration-1.6-variable-changes-PRINC'>
1354 <title><filename>PRINC</filename></title>
1355
1356 <para>
1357 The <filename>PRINC</filename>
1358 variable has been deprecated and triggers a warning if
1359 detected during a build.
1360 For
1361 <link linkend='var-PR'><filename>PR</filename></link>
1362 increments on changes, use the PR service instead.
1363 You can find out more about this service in the
1364 "<ulink url='&YOCTO_DOCS_DEV_URL;#working-with-a-pr-service'>Working With a PR Service</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001365 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001366 </para>
1367 </section>
1368
1369 <section id='migration-1.6-variable-changes-IMAGE_TYPES'>
1370 <title><filename>IMAGE_TYPES</filename></title>
1371
1372 <para>
1373 The "sum.jffs2" option for
1374 <link linkend='var-IMAGE_TYPES'><filename>IMAGE_TYPES</filename></link>
1375 has been replaced by the "jffs2.sum" option, which fits the
1376 processing order.
1377 </para>
1378 </section>
1379
1380 <section id='migration-1.6-variable-changes-COPY_LIC_MANIFEST'>
1381 <title><filename>COPY_LIC_MANIFEST</filename></title>
1382
1383 <para>
1384 The
1385 <link linkend='var-COPY_LIC_MANIFEST'><filename>COPY_LIC_MANIFEST</filename></link>
1386 variable must
1387 now be set to "1" rather than any value in order to enable
1388 it.
1389 </para>
1390 </section>
1391
1392 <section id='migration-1.6-variable-changes-COPY_LIC_DIRS'>
1393 <title><filename>COPY_LIC_DIRS</filename></title>
1394
1395 <para>
1396 The
1397 <link linkend='var-COPY_LIC_DIRS'><filename>COPY_LIC_DIRS</filename></link>
1398 variable must
1399 now be set to "1" rather than any value in order to enable
1400 it.
1401 </para>
1402 </section>
1403
1404 <section id='migration-1.6-variable-changes-PACKAGE_GROUP'>
1405 <title><filename>PACKAGE_GROUP</filename></title>
1406
1407 <para>
1408 The
1409 <link linkend='var-PACKAGE_GROUP'><filename>PACKAGE_GROUP</filename></link>
1410 variable has been renamed to
1411 <link linkend='var-FEATURE_PACKAGES'><filename>FEATURE_PACKAGES</filename></link>
1412 to more accurately reflect its purpose.
1413 You can still use <filename>PACKAGE_GROUP</filename> but
1414 the OpenEmbedded build system produces a warning message when
1415 it encounters the variable.
1416 </para>
1417 </section>
1418
1419 <section id='migration-1.6-variable-changes-variable-entry-behavior'>
1420 <title>Preprocess and Post Process Command Variable Behavior</title>
1421
1422 <para>
1423 The following variables now expect a semicolon separated
1424 list of functions to call and not arbitrary shell commands:
1425 <literallayout class='monospaced'>
1426 <link linkend='var-ROOTFS_PREPROCESS_COMMAND'>ROOTFS_PREPROCESS_COMMAND</link>
1427 <link linkend='var-ROOTFS_POSTPROCESS_COMMAND'>ROOTFS_POSTPROCESS_COMMAND</link>
1428 <link linkend='var-SDK_POSTPROCESS_COMMAND'>SDK_POSTPROCESS_COMMAND</link>
1429 <link linkend='var-POPULATE_SDK_POST_TARGET_COMMAND'>POPULATE_SDK_POST_TARGET_COMMAND</link>
1430 <link linkend='var-POPULATE_SDK_POST_HOST_COMMAND'>POPULATE_SDK_POST_HOST_COMMAND</link>
1431 <link linkend='var-IMAGE_POSTPROCESS_COMMAND'>IMAGE_POSTPROCESS_COMMAND</link>
1432 <link linkend='var-IMAGE_PREPROCESS_COMMAND'>IMAGE_PREPROCESS_COMMAND</link>
1433 <link linkend='var-ROOTFS_POSTUNINSTALL_COMMAND'>ROOTFS_POSTUNINSTALL_COMMAND</link>
1434 <link linkend='var-ROOTFS_POSTINSTALL_COMMAND'>ROOTFS_POSTINSTALL_COMMAND</link>
1435 </literallayout>
1436 For migration purposes, you can simply wrap shell commands in
1437 a shell function and then call the function.
1438 Here is an example:
1439 <literallayout class='monospaced'>
1440 my_postprocess_function() {
1441 echo "hello" > ${IMAGE_ROOTFS}/hello.txt
1442 }
1443 ROOTFS_POSTPROCESS_COMMAND += "my_postprocess_function; "
1444 </literallayout>
1445 </para>
1446 </section>
1447 </section>
1448
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001449 <section id='migration-1.6-package-test-ptest'>
1450 <title>Package Test (ptest)</title>
1451
1452 <para>
1453 Package Tests (ptest) are built but not installed by default.
1454 For information on using Package Tests, see the
1455 "<ulink url='&YOCTO_DOCS_DEV_URL;#testing-packages-with-ptest'>Setting up and running package test (ptest)</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001456 section in the Yocto Project Development Tasks Manual.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001457 For information on the <filename>ptest</filename> class, see the
1458 "<link linkend='ref-classes-ptest'><filename>ptest.bbclass</filename></link>"
1459 section.
1460 </para>
1461 </section>
1462
1463 <section id='migration-1.6-build-changes'>
1464 <title>Build Changes</title>
1465
1466 <para>
1467 Separate build and source directories have been enabled
1468 by default for selected recipes where it is known to work
1469 (a whitelist) and for all recipes that inherit the
1470 <link linkend='ref-classes-cmake'><filename>cmake</filename></link>
1471 class.
1472 In future releases the
1473 <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
1474 class will enable a separate build directory by default as
1475 well.
1476 Recipes building Autotools-based
1477 software that fails to build with a separate build directory
1478 should be changed to inherit from the
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001479 <link linkend='ref-classes-autotools'><filename>autotools-brokensep</filename></link>
1480 class instead of the <filename>autotools</filename> or
1481 <filename>autotools_stage</filename>classes.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001482 </para>
1483 </section>
1484
1485 <section id='migration-1.6-building-qemu-native'>
1486 <title><filename>qemu-native</filename></title>
1487
1488 <para>
1489 <filename>qemu-native</filename> now builds without
1490 SDL-based graphical output support by default.
1491 The following additional lines are needed in your
1492 <filename>local.conf</filename> to enable it:
1493 <literallayout class='monospaced'>
1494 PACKAGECONFIG_pn-qemu-native = "sdl"
1495 ASSUME_PROVIDED += "libsdl-native"
1496 </literallayout>
1497 <note>
1498 The default <filename>local.conf</filename>
1499 contains these statements.
1500 Consequently, if you are building a headless system and using
1501 a default <filename>local.conf</filename> file, you will need
1502 comment these two lines out.
1503 </note>
1504 </para>
1505 </section>
1506
1507 <section id='migration-1.6-core-image-basic'>
1508 <title><filename>core-image-basic</filename></title>
1509
1510 <para>
1511 <filename>core-image-basic</filename> has been renamed to
1512 <filename>core-image-full-cmdline</filename>.
1513 </para>
1514
1515 <para>
1516 In addition to <filename>core-image-basic</filename> being renamed,
1517 <filename>packagegroup-core-basic</filename> has been renamed to
1518 <filename>packagegroup-core-full-cmdline</filename> to match.
1519 </para>
1520 </section>
1521
1522 <section id='migration-1.6-licensing'>
1523 <title>Licensing</title>
1524
1525 <para>
1526 The top-level <filename>LICENSE</filename> file has been changed
1527 to better describe the license of the various components of
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001528 <link linkend='oe-core'>OE-Core</link>.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001529 However, the licensing itself remains unchanged.
1530 </para>
1531
1532 <para>
1533 Normally, this change would not cause any side-effects.
1534 However, some recipes point to this file within
1535 <link linkend='var-LIC_FILES_CHKSUM'><filename>LIC_FILES_CHKSUM</filename></link>
1536 (as <filename>${COREBASE}/LICENSE</filename>) and thus the
1537 accompanying checksum must be changed from
1538 3f40d7994397109285ec7b81fdeb3b58 to
1539 4d92cd373abda3937c2bc47fbc49d690.
1540 A better alternative is to have
1541 <filename>LIC_FILES_CHKSUM</filename> point to a file
1542 describing the license that is distributed with the source
1543 that the recipe is building, if possible, rather than pointing
1544 to <filename>${COREBASE}/LICENSE</filename>.
1545 </para>
1546 </section>
1547
1548 <section id='migration-1.6-cflags-options'>
1549 <title><filename>CFLAGS</filename> Options</title>
1550
1551 <para>
1552 The "-fpermissive" option has been removed from the default
1553 <link linkend='var-CFLAGS'><filename>CFLAGS</filename></link>
1554 value.
1555 You need to take action on individual recipes that fail when
1556 building with this option.
1557 You need to either patch the recipes to fix the issues reported by
1558 the compiler, or you need to add "-fpermissive" to
1559 <filename>CFLAGS</filename> in the recipes.
1560 </para>
1561 </section>
1562
1563 <section id='migration-1.6-custom-images'>
1564 <title>Custom Image Output Types</title>
1565
1566 <para>
1567 Custom image output types, as selected using
1568 <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>,
1569 must declare their dependencies on other image types (if any) using
1570 a new
1571 <link linkend='var-IMAGE_TYPEDEP'><filename>IMAGE_TYPEDEP</filename></link>
1572 variable.
1573 </para>
1574 </section>
1575
1576 <section id='migration-1.6-do-package-write-task'>
1577 <title>Tasks</title>
1578
1579 <para>
1580 The <filename>do_package_write</filename> task has been removed.
1581 The task is no longer needed.
1582 </para>
1583 </section>
1584
1585 <section id='migration-1.6-update-alternatives-provider'>
1586 <title><filename>update-alternative</filename> Provider</title>
1587
1588 <para>
1589 The default <filename>update-alternatives</filename> provider has
1590 been changed from <filename>opkg</filename> to
1591 <filename>opkg-utils</filename>.
1592 This change resolves some troublesome circular dependencies.
1593 The runtime package has also been renamed from
1594 <filename>update-alternatives-cworth</filename>
1595 to <filename>update-alternatives-opkg</filename>.
1596 </para>
1597 </section>
1598
1599 <section id='migration-1.6-virtclass-overrides'>
1600 <title><filename>virtclass</filename> Overrides</title>
1601
1602 <para>
1603 The <filename>virtclass</filename> overrides are now deprecated.
1604 Use the equivalent class overrides instead (e.g.
1605 <filename>virtclass-native</filename> becomes
1606 <filename>class-native</filename>.)
1607 </para>
1608 </section>
1609
1610 <section id='migration-1.6-removed-renamed-recipes'>
1611 <title>Removed and Renamed Recipes</title>
1612
1613 <para>
1614 The following recipes have been removed:
1615 <itemizedlist>
1616 <listitem><para><filename>packagegroup-toolset-native</filename> -
1617 This recipe is largely unused.
1618 </para></listitem>
1619 <listitem><para><filename>linux-yocto-3.8</filename> -
1620 Support for the Linux yocto 3.8 kernel has been dropped.
1621 Support for the 3.10 and 3.14 kernels have been added
1622 with the <filename>linux-yocto-3.10</filename> and
1623 <filename>linux-yocto-3.14</filename> recipes.
1624 </para></listitem>
1625 <listitem><para><filename>ocf-linux</filename> -
1626 This recipe has been functionally replaced using
1627 <filename>cryptodev-linux</filename>.
1628 </para></listitem>
1629 <listitem><para><filename>genext2fs</filename> -
1630 <filename>genext2fs</filename> is no longer used by the
1631 build system and is unmaintained upstream.
1632 </para></listitem>
1633 <listitem><para><filename>js</filename> -
1634 This provided an ancient version of Mozilla's javascript
1635 engine that is no longer needed.
1636 </para></listitem>
1637 <listitem><para><filename>zaurusd</filename> -
1638 The recipe has been moved to the
1639 <filename>meta-handheld</filename> layer.
1640 </para></listitem>
1641 <listitem><para><filename>eglibc 2.17</filename> -
1642 Replaced by the <filename>eglibc 2.19</filename>
1643 recipe.
1644 </para></listitem>
1645 <listitem><para><filename>gcc 4.7.2</filename> -
1646 Replaced by the now stable
1647 <filename>gcc 4.8.2</filename>.
1648 </para></listitem>
1649 <listitem><para><filename>external-sourcery-toolchain</filename> -
1650 this recipe is now maintained in the
1651 <filename>meta-sourcery</filename> layer.
1652 </para></listitem>
1653 <listitem><para><filename>linux-libc-headers-yocto 3.4+git</filename> -
1654 Now using version 3.10 of the
1655 <filename>linux-libc-headers</filename> by default.
1656 </para></listitem>
1657 <listitem><para><filename>meta-toolchain-gmae</filename> -
1658 This recipe is obsolete.
1659 </para></listitem>
1660 <listitem><para><filename>packagegroup-core-sdk-gmae</filename> -
1661 This recipe is obsolete.
1662 </para></listitem>
1663 <listitem><para><filename>packagegroup-core-standalone-gmae-sdk-target</filename> -
1664 This recipe is obsolete.
1665 </para></listitem>
1666 </itemizedlist>
1667 </para>
1668 </section>
1669
1670 <section id='migration-1.6-removed-classes'>
1671 <title>Removed Classes</title>
1672
1673 <para>
1674 The following classes have become obsolete and have been removed:
1675 <itemizedlist>
1676 <listitem><para><filename>module_strip</filename>
1677 </para></listitem>
1678 <listitem><para><filename>pkg_metainfo</filename>
1679 </para></listitem>
1680 <listitem><para><filename>pkg_distribute</filename>
1681 </para></listitem>
1682 <listitem><para><filename>image-empty</filename>
1683 </para></listitem>
1684 </itemizedlist>
1685 </para>
1686 </section>
1687
1688 <section id='migration-1.6-reference-bsps'>
1689 <title>Reference Board Support Packages (BSPs)</title>
1690
1691 <para>
1692 The following reference BSPs changes occurred:
1693 <itemizedlist>
1694 <listitem><para>The BeagleBoard
1695 (<filename>beagleboard</filename>) ARM reference hardware
1696 has been replaced by the BeagleBone
1697 (<filename>beaglebone</filename>) hardware.
1698 </para></listitem>
1699 <listitem><para>The RouterStation Pro
1700 (<filename>routerstationpro</filename>) MIPS reference
1701 hardware has been replaced by the EdgeRouter Lite
1702 (<filename>edgerouter</filename>) hardware.
1703 </para></listitem>
1704 </itemizedlist>
1705 The previous reference BSPs for the
1706 <filename>beagleboard</filename> and
1707 <filename>routerstationpro</filename> machines are still available
1708 in a new <filename>meta-yocto-bsp-old</filename> layer in the
1709 <ulink url='&YOCTO_GIT_URL;'>Source Repositories</ulink>
1710 at
1711 <ulink url='http://git.yoctoproject.org/cgit/cgit.cgi/meta-yocto-bsp-old/'>http://git.yoctoproject.org/cgit/cgit.cgi/meta-yocto-bsp-old/</ulink>.
1712 </para>
1713 </section>
1714</section>
1715
1716<section id='moving-to-the-yocto-project-1.7-release'>
1717 <title>Moving to the Yocto Project 1.7 Release</title>
1718
1719 <para>
1720 This section provides migration information for moving to the
1721 Yocto Project 1.7 Release from the prior release.
1722 </para>
1723
1724 <section id='migration-1.7-changes-to-setting-qemu-packageconfig-options'>
1725 <title>Changes to Setting QEMU <filename>PACKAGECONFIG</filename> Options in <filename>local.conf</filename></title>
1726
1727 <para>
1728 The QEMU recipe now uses a number of
1729 <link linkend='var-PACKAGECONFIG'><filename>PACKAGECONFIG</filename></link>
1730 options to enable various optional features.
1731 The method used to set defaults for these options means that
1732 existing
1733 <filename>local.conf</filename> files will need to be be
1734 modified to append to <filename>PACKAGECONFIG</filename> for
1735 <filename>qemu-native</filename> and
1736 <filename>nativesdk-qemu</filename> instead of setting it.
1737 In other words, to enable graphical output for QEMU, you should
1738 now have these lines in <filename>local.conf</filename>:
1739 <literallayout class='monospaced'>
1740 PACKAGECONFIG_append_pn-qemu-native = " sdl"
1741 PACKAGECONFIG_append_pn-nativesdk-qemu = " sdl"
1742 </literallayout>
1743 </para>
1744 </section>
1745
1746 <section id='migration-1.7-minimum-git-version'>
1747 <title>Minimum Git version</title>
1748
1749 <para>
1750 The minimum
Brad Bishopd7bf8c12018-02-25 22:55:05 -05001751 <link linkend='git'>Git</link> version required
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001752 on the build host is now 1.7.8 because the
1753 <filename>--list</filename> option is now required by
1754 BitBake's Git fetcher.
1755 As always, if your host distribution does not provide a version of
1756 Git that meets this requirement, you can use the
1757 <filename>buildtools-tarball</filename> that does.
1758 See the
1759 "<link linkend='required-git-tar-and-python-versions'>Required Git, tar, and Python Versions</link>"
1760 section for more information.
1761 </para>
1762 </section>
1763
1764 <section id='migration-1.7-autotools-class-changes'>
1765 <title>Autotools Class Changes</title>
1766
1767 <para>
1768 The following
1769 <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
1770 class changes occurred:
1771 <itemizedlist>
1772 <listitem><para><emphasis>
1773 A separate build directory is now used by default:</emphasis>
1774 The <filename>autotools</filename> class has been changed
1775 to use a directory for building
1776 (<link linkend='var-B'><filename>B</filename></link>),
1777 which is separate from the source directory
1778 (<link linkend='var-S'><filename>S</filename></link>).
1779 This is commonly referred to as
1780 <filename>B != S</filename>, or an out-of-tree build.</para>
1781 <para>If the software being built is already capable of
1782 building in a directory separate from the source, you
1783 do not need to do anything.
1784 However, if the software is not capable of being built
1785 in this manner, you will
1786 need to either patch the software so that it can build
1787 separately, or you will need to change the recipe to
1788 inherit the
Patrick Williamsf1e5d692016-03-30 15:21:19 -05001789 <link linkend='ref-classes-autotools'><filename>autotools-brokensep</filename></link>
1790 class instead of the <filename>autotools</filename> or
1791 <filename>autotools_stage</filename> classes.
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001792 </para></listitem>
1793 <listitem><para><emphasis>
1794 The <filename>--foreign</filename> option is
1795 no longer passed to <filename>automake</filename> when
1796 running <filename>autoconf</filename>:</emphasis>
1797 This option tells <filename>automake</filename> that a
1798 particular software package does not follow the GNU
1799 standards and therefore should not be expected
1800 to distribute certain files such as
1801 <filename>ChangeLog</filename>,
1802 <filename>AUTHORS</filename>, and so forth.
1803 Because the majority of upstream software packages already
1804 tell <filename>automake</filename> to enable foreign mode
1805 themselves, the option is mostly superfluous.
1806 However, some recipes will need patches for this change.
1807 You can easily make the change by patching
1808 <filename>configure.ac</filename> so that it passes
1809 "foreign" to <filename>AM_INIT_AUTOMAKE()</filename>.
1810 See
1811 <ulink url='http://cgit.openembedded.org/openembedded-core/commit/?id=01943188f85ce6411717fb5bf702d609f55813f2'>this commit</ulink>
1812 for an example showing how to make the patch.
1813 </para></listitem>
1814 </itemizedlist>
1815 </para>
1816 </section>
1817
1818 <section id='migration-1.7-binary-configuration-scripts-disabled'>
1819 <title>Binary Configuration Scripts Disabled</title>
1820
1821 <para>
1822 Some of the core recipes that package binary configuration scripts
1823 now disable the scripts due to the
1824 scripts previously requiring error-prone path substitution.
1825 Software that links against these libraries using these scripts
1826 should use the much more robust <filename>pkg-config</filename>
1827 instead.
1828 The list of recipes changed in this version (and their
1829 configuration scripts) is as follows:
1830 <literallayout class='monospaced'>
1831 directfb (directfb-config)
1832 freetype (freetype-config)
1833 gpgme (gpgme-config)
1834 libassuan (libassuan-config)
1835 libcroco (croco-6.0-config)
1836 libgcrypt (libgcrypt-config)
1837 libgpg-error (gpg-error-config)
1838 libksba (ksba-config)
1839 libpcap (pcap-config)
1840 libpcre (pcre-config)
1841 libpng (libpng-config, libpng16-config)
1842 libsdl (sdl-config)
1843 libusb-compat (libusb-config)
1844 libxml2 (xml2-config)
1845 libxslt (xslt-config)
1846 ncurses (ncurses-config)
1847 neon (neon-config)
1848 npth (npth-config)
1849 pth (pth-config)
1850 taglib (taglib-config)
1851 </literallayout>
1852 Additionally, support for <filename>pkg-config</filename> has been
1853 added to some recipes in the previous list in the rare cases
1854 where the upstream software package does not already provide
1855 it.
1856 </para>
1857 </section>
1858
1859 <section id='migration-1.7-glibc-replaces-eglibc'>
1860 <title><filename>eglibc 2.19</filename> Replaced with <filename>glibc 2.20</filename></title>
1861
1862 <para>
1863 Because <filename>eglibc</filename> and
1864 <filename>glibc</filename> were already fairly close, this
1865 replacement should not require any significant changes to other
1866 software that links to <filename>eglibc</filename>.
1867 However, there were a number of minor changes in
1868 <filename>glibc 2.20</filename> upstream that could require
1869 patching some software (e.g. the removal of the
1870 <filename>_BSD_SOURCE</filename> feature test macro).
1871 </para>
1872
1873 <para>
1874 <filename>glibc 2.20</filename> requires version 2.6.32 or greater
1875 of the Linux kernel.
1876 Thus, older kernels will no longer be usable in conjunction with it.
1877 </para>
1878
1879 <para>
1880 For full details on the changes in <filename>glibc 2.20</filename>,
1881 see the upstream release notes
1882 <ulink url='https://sourceware.org/ml/libc-alpha/2014-09/msg00088.html'>here</ulink>.
1883 </para>
1884 </section>
1885
1886 <section id='migration-1.7-kernel-module-autoloading'>
1887 <title>Kernel Module Autoloading</title>
1888
1889 <para>
1890 The
1891 <link linkend='var-module_autoload'><filename>module_autoload_*</filename></link>
1892 variable is now deprecated and a new
1893 <link linkend='var-KERNEL_MODULE_AUTOLOAD'><filename>KERNEL_MODULE_AUTOLOAD</filename></link>
1894 variable should be used instead.
1895 Also,
1896 <link linkend='var-module_conf'><filename>module_conf_*</filename></link>
1897 must now be used in conjunction with a new
1898 <link linkend='var-KERNEL_MODULE_PROBECONF'><filename>KERNEL_MODULE_PROBECONF</filename></link>
1899 variable.
1900 The new variables no longer require you to specify the module name
1901 as part of the variable name.
1902 This change not only simplifies usage but also allows the values
1903 of these variables to be appropriately incorporated into task
1904 signatures and thus trigger the appropriate tasks to re-execute
1905 when changed.
1906 You should replace any references to
1907 <filename>module_autoload_*</filename> with
1908 <filename>KERNEL_MODULE_AUTOLOAD</filename>, and add any modules
1909 for which <filename>module_conf_*</filename> is specified to
1910 <filename>KERNEL_MODULE_PROBECONF</filename>.
1911 </para>
1912
1913 <para>
1914 For more information, see the
1915 <link linkend='var-KERNEL_MODULE_AUTOLOAD'><filename>KERNEL_MODULE_AUTOLOAD</filename></link>
1916 and
1917 <link linkend='var-KERNEL_MODULE_PROBECONF'><filename>KERNEL_MODULE_PROBECONF</filename></link>
1918 variables.
1919 </para>
1920 </section>
1921
1922 <section id='migration-1.7-qa-check-changes'>
1923 <title>QA Check Changes</title>
1924
1925 <para>
1926 The following changes have occurred to the QA check process:
1927 <itemizedlist>
1928 <listitem><para>
1929 Additional QA checks <filename>file-rdeps</filename>
1930 and <filename>build-deps</filename> have been added in
1931 order to verify that file dependencies are satisfied
1932 (e.g. package contains a script requiring
1933 <filename>/bin/bash</filename>) and build-time dependencies
1934 are declared, respectively.
1935 For more information, please see the
1936 "<link linkend='ref-qa-checks'>QA Error and Warning Messages</link>"
1937 chapter.
1938 </para></listitem>
1939 <listitem><para>
1940 Package QA checks are now performed during a new
1941 <link linkend='ref-tasks-package_qa'><filename>do_package_qa</filename></link>
1942 task rather than being part of the
1943 <link linkend='ref-tasks-package'><filename>do_package</filename></link>
1944 task.
1945 This allows more parallel execution.
1946 This change is unlikely to be an issue except for highly
1947 customized recipes that disable packaging tasks themselves
1948 by marking them as <filename>noexec</filename>.
1949 For those packages, you will need to disable the
1950 <filename>do_package_qa</filename> task as well.
1951 </para></listitem>
1952 <listitem><para>
1953 Files being overwritten during the
1954 <link linkend='ref-tasks-populate_sysroot'><filename>do_populate_sysroot</filename></link>
1955 task now trigger an error instead of a warning.
1956 Recipes should not be overwriting files written to the
1957 sysroot by other recipes.
1958 If you have these types of recipes, you need to alter them
1959 so that they do not overwrite these files.</para>
1960 <para>You might now receive this error after changes in
1961 configuration or metadata resulting in orphaned files
1962 being left in the sysroot.
1963 If you do receive this error, the way to resolve the issue
1964 is to delete your
1965 <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
1966 or to move it out of the way and then re-start the build.
1967 Anything that has been fully built up to that point and
1968 does not need rebuilding will be restored from the shared
1969 state cache and the rest of the build will be able to
1970 proceed as normal.
1971 </para></listitem>
1972 </itemizedlist>
1973 </para>
1974 </section>
1975
1976 <section id='migration-1.7-removed-recipes'>
1977 <title>Removed Recipes</title>
1978
1979 <para>
1980 The following recipes have been removed:
1981 <itemizedlist>
1982 <listitem><para>
1983 <filename>x-load</filename>:
1984 This recipe has been superseded by
1985 U-boot SPL for all Cortex-based TI SoCs.
1986 For legacy boards, the <filename>meta-ti</filename>
1987 layer, which contains a maintained recipe, should be used
1988 instead.
1989 </para></listitem>
1990 <listitem><para>
1991 <filename>ubootchart</filename>:
1992 This recipe is obsolete.
1993 A <filename>bootchart2</filename> recipe has been added
1994 to functionally replace it.
1995 </para></listitem>
1996 <listitem><para>
1997 <filename>linux-yocto 3.4</filename>:
1998 Support for the linux-yocto 3.4 kernel has been dropped.
1999 Support for the 3.10 and 3.14 kernels remains, while
2000 support for version 3.17 has been added.
2001 </para></listitem>
2002 <listitem><para>
2003 <filename>eglibc</filename> has been removed in favor of
2004 <filename>glibc</filename>.
2005 See the
2006 "<link linkend='migration-1.7-glibc-replaces-eglibc'><filename>eglibc 2.19</filename> Replaced with <filename>glibc 2.20</filename></link>"
2007 section for more information.
2008 </para></listitem>
2009 </itemizedlist>
2010 </para>
2011 </section>
2012
2013 <section id='migration-1.7-miscellaneous-changes'>
2014 <title>Miscellaneous Changes</title>
2015
2016 <para>
2017 The following miscellaneous change occurred:
2018 <itemizedlist>
2019 <listitem><para>
2020 The build history feature now writes
2021 <filename>build-id.txt</filename> instead of
2022 <filename>build-id</filename>.
2023 Additionally, <filename>build-id.txt</filename>
2024 now contains the full build header as printed by
2025 BitBake upon starting the build.
2026 You should manually remove old "build-id" files from your
2027 existing build history repositories to avoid confusion.
2028 For information on the build history feature, see the
2029 "<link linkend='maintaining-build-output-quality'>Maintaining Build Output Quality</link>"
2030 section.
2031 </para></listitem>
2032 </itemizedlist>
2033 </para>
2034 </section>
2035</section>
2036
2037<section id='moving-to-the-yocto-project-1.8-release'>
2038 <title>Moving to the Yocto Project 1.8 Release</title>
2039
2040 <para>
2041 This section provides migration information for moving to the
2042 Yocto Project 1.8 Release from the prior release.
2043 </para>
2044
2045 <section id='migration-1.8-removed-recipes'>
2046 <title>Removed Recipes</title>
2047
2048 <para>
2049 The following recipes have been removed:
2050 <itemizedlist>
2051 <listitem><para><filename>owl-video</filename>:
2052 Functionality replaced by <filename>gst-player</filename>.
2053 </para></listitem>
2054 <listitem><para><filename>gaku</filename>:
2055 Functionality replaced by <filename>gst-player</filename>.
2056 </para></listitem>
2057 <listitem><para><filename>gnome-desktop</filename>:
2058 This recipe is now available in
2059 <filename>meta-gnome</filename> and is no longer needed.
2060 </para></listitem>
2061 <listitem><para><filename>gsettings-desktop-schemas</filename>:
2062 This recipe is now available in
2063 <filename>meta-gnome</filename> and is no longer needed.
2064 </para></listitem>
2065 <listitem><para><filename>python-argparse</filename>:
2066 The <filename>argparse</filename> module is already
2067 provided in the default Python distribution in a
2068 package named <filename>python-argparse</filename>.
2069 Consequently, the separate
2070 <filename>python-argparse</filename> recipe is no
2071 longer needed.
2072 </para></listitem>
2073 <listitem><para><filename>telepathy-python, libtelepathy, telepathy-glib, telepathy-idle, telepathy-mission-control</filename>:
2074 All these recipes have moved to
2075 <filename>meta-oe</filename> and are consequently no
2076 longer needed by any recipes in OpenEmbedded-Core.
2077 </para></listitem>
2078 <listitem><para><filename>linux-yocto_3.10</filename> and <filename>linux-yocto_3.17</filename>:
2079 Support for the linux-yocto 3.10 and 3.17 kernels has been
2080 dropped.
2081 Support for the 3.14 kernel remains, while support for
2082 3.19 kernel has been added.
2083 </para></listitem>
2084 <listitem><para><filename>poky-feed-config-opkg</filename>:
2085 This recipe has become obsolete and is no longer needed.
2086 Use <filename>distro-feed-config</filename> from
2087 <filename>meta-oe</filename> instead.
2088 </para></listitem>
2089 <listitem><para><filename>libav 0.8.x</filename>:
2090 <filename>libav 9.x</filename> is now used.
2091 </para></listitem>
2092 <listitem><para><filename>sed-native</filename>:
2093 No longer needed.
2094 A working version of <filename>sed</filename> is expected
2095 to be provided by the host distribution.
2096 </para></listitem>
2097 </itemizedlist>
2098 </para>
2099 </section>
2100
2101 <section id='migration-1.8-bluez'>
2102 <title>BlueZ 4.x / 5.x Selection</title>
2103
2104 <para>
2105 Proper built-in support for selecting BlueZ 5.x in preference
2106 to the default of 4.x now exists.
2107 To use BlueZ 5.x, simply add "bluez5" to your
2108 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
2109 value.
2110 If you had previously added append files
2111 (<filename>*.bbappend</filename>) to make this selection, you can
2112 now remove them.
2113 </para>
2114
2115 <para>
2116 Additionally, a
2117 <link linkend='ref-classes-bluetooth'><filename>bluetooth</filename></link>
2118 class has been added to make selection of the appropriate bluetooth
2119 support within a recipe a little easier.
2120 If you wish to make use of this class in a recipe, add something
2121 such as the following:
2122 <literallayout class='monospaced'>
2123 inherit bluetooth
2124 PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ}', '', d)}
2125 PACKAGECONFIG[bluez4] = "--enable-bluetooth,--disable-bluetooth,bluez4"
2126 PACKAGECONFIG[bluez5] = "--enable-bluez5,--disable-bluez5,bluez5"
2127 </literallayout>
2128 </para>
2129 </section>
2130
2131 <section id='migration-1.8-kernel-build-changes'>
2132 <title>Kernel Build Changes</title>
2133
2134 <para>
2135 The kernel build process was changed to place the source
2136 in a common shared work area and to place build artifacts
2137 separately in the source code tree.
2138 In theory, migration paths have been provided for most common
2139 usages in kernel recipes but this might not work in all cases.
2140 In particular, users need to ensure that
2141 <filename>${S}</filename> (source files) and
2142 <filename>${B}</filename> (build artifacts) are used
2143 correctly in functions such as
2144 <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
2145 and
2146 <link linkend='ref-tasks-install'><filename>do_install</filename></link>.
2147 For kernel recipes that do not inherit from
2148 <filename>kernel-yocto</filename> or include
2149 <filename>linux-yocto.inc</filename>, you might wish to
2150 refer to the <filename>linux.inc</filename> file in the
2151 <filename>meta-oe</filename> layer for the kinds of changes you
2152 need to make.
2153 For reference, here is the
2154 <ulink url='http://cgit.openembedded.org/meta-openembedded/commit/meta-oe/recipes-kernel/linux/linux.inc?id=fc7132ede27ac67669448d3d2845ce7d46c6a1ee'>commit</ulink>
2155 where the <filename>linux.inc</filename> file in
2156 <filename>meta-oe</filename> was updated.
2157 </para>
2158
2159 <para>
2160 Recipes that rely on the kernel source code and do not inherit
2161 the module classes might need to add explicit dependencies on
2162 the <filename>do_shared_workdir</filename> kernel task, for example:
2163 <literallayout class='monospaced'>
2164 do_configure[depends] += "virtual/kernel:do_shared_workdir"
2165 </literallayout>
2166 </para>
2167 </section>
2168
2169 <section id='migration-1.8-ssl'>
2170 <title>SSL 3.0 is Now Disabled in OpenSSL</title>
2171
2172 <para>
2173 SSL 3.0 is now disabled when building OpenSSL.
2174 Disabling SSL 3.0 avoids any lingering instances of the POODLE
2175 vulnerability.
2176 If you feel you must re-enable SSL 3.0, then you can add an
2177 append file (<filename>*.bbappend</filename>) for the
2178 <filename>openssl</filename> recipe to remove "-no-ssl3"
2179 from
2180 <link linkend='var-EXTRA_OECONF'><filename>EXTRA_OECONF</filename></link>.
2181 </para>
2182 </section>
2183
2184 <section id='migration-1.8-default-sysroot-poisoning'>
2185 <title>Default Sysroot Poisoning</title>
2186
2187 <para>
2188 <filename>gcc's</filename> default sysroot and include directories
2189 are now "poisoned".
2190 In other words, the sysroot and include directories are being
2191 redirected to a non-existent location in order to catch when
2192 host directories are being used due to the correct options not
2193 being passed.
2194 This poisoning applies both to the cross-compiler used within the
2195 build and to the cross-compiler produced in the SDK.
2196 </para>
2197
2198 <para>
2199 If this change causes something in the build to fail, it almost
2200 certainly means the various compiler flags and commands are not
2201 being passed correctly to the underlying piece of software.
2202 In such cases, you need to take corrective steps.
2203 </para>
2204 </section>
2205
2206 <section id='migration-1.8-rebuild-improvements'>
2207 <title>Rebuild Improvements</title>
2208
2209 <para>
2210 Changes have been made to the
2211 <link linkend='ref-classes-base'><filename>base</filename></link>,
2212 <link linkend='ref-classes-autotools'><filename>autotools</filename></link>,
2213 and
2214 <link linkend='ref-classes-cmake'><filename>cmake</filename></link>
2215 classes to clean out generated files when the
2216 <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
2217 task needs to be re-executed.
2218 </para>
2219
2220 <para>
2221 One of the improvements is to attempt to run "make clean" during
2222 the <filename>do_configure</filename> task if a
2223 <filename>Makefile</filename> exists.
2224 Some software packages do not provide a working clean target
2225 within their make files.
2226 If you have such recipes, you need to set
2227 <link linkend='var-CLEANBROKEN'><filename>CLEANBROKEN</filename></link>
2228 to "1" within the recipe, for example:
2229 <literallayout class='monospaced'>
2230 CLEANBROKEN = "1"
2231 </literallayout>
2232 </para>
2233 </section>
2234
2235 <section id='migration-1.8-qa-check-and-validation-changes'>
2236 <title>QA Check and Validation Changes</title>
2237
2238 <para>
2239 The following QA Check and Validation Changes have occurred:
2240 <itemizedlist>
2241 <listitem><para>
2242 Usage of <filename>PRINC</filename>
2243 previously triggered a warning.
2244 It now triggers an error.
2245 You should remove any remaining usage of
2246 <filename>PRINC</filename> in any recipe or append file.
2247 </para></listitem>
2248 <listitem><para>
2249 An additional QA check has been added to detect usage of
2250 <filename>${D}</filename> in
2251 <link linkend='var-FILES'><filename>FILES</filename></link>
2252 values where
2253 <link linkend='var-D'><filename>D</filename></link> values
2254 should not be used at all.
2255 The same check ensures that <filename>$D</filename> is used
2256 in
2257 <filename>pkg_preinst/pkg_postinst/pkg_prerm/pkg_postrm</filename>
2258 functions instead of <filename>${D}</filename>.
2259 </para></listitem>
2260 <listitem><para>
2261 <link linkend='var-S'><filename>S</filename></link> now
2262 needs to be set to a valid value within a recipe.
2263 If <filename>S</filename> is not set in the recipe, the
2264 directory is not automatically created.
2265 If <filename>S</filename> does not point to a directory
2266 that exists at the time the
2267 <link linkend='ref-tasks-unpack'><filename>do_unpack</filename></link>
2268 task finishes, a warning will be shown.
2269 </para></listitem>
2270 <listitem><para>
2271 <link linkend='var-LICENSE'><filename>LICENSE</filename></link>
2272 is now validated for correct formatting of multiple
2273 licenses.
2274 If the format is invalid (e.g. multiple licenses are
2275 specified with no operators to specify how the multiple
2276 licenses interact), then a warning will be shown.
2277 </para></listitem>
2278 </itemizedlist>
2279 </para>
2280 </section>
2281
2282 <section id='migration-1.8-miscellaneous-changes'>
2283 <title>Miscellaneous Changes</title>
2284
2285 <para>
2286 The following miscellaneous changes have occurred:
2287 <itemizedlist>
2288 <listitem><para>
2289 The <filename>send-error-report</filename> script now
2290 expects a "-s" option to be specified before the server
2291 address.
2292 This assumes a server address is being specified.
2293 </para></listitem>
2294 <listitem><para>
2295 The <filename>oe-pkgdata-util</filename> script now
2296 expects a "-p" option to be specified before the
2297 <filename>pkgdata</filename> directory, which is now
2298 optional.
2299 If the <filename>pkgdata</filename> directory is not
2300 specified, the script will run BitBake to query
2301 <link linkend='var-PKGDATA_DIR'><filename>PKGDATA_DIR</filename></link>
2302 from the build environment.
2303 </para></listitem>
2304 </itemizedlist>
2305 </para>
2306 </section>
2307</section>
2308
Patrick Williamsf1e5d692016-03-30 15:21:19 -05002309<section id='moving-to-the-yocto-project-2.0-release'>
2310 <title>Moving to the Yocto Project 2.0 Release</title>
2311
2312 <para>
2313 This section provides migration information for moving to the
2314 Yocto Project 2.0 Release from the prior release.
2315 </para>
2316
2317 <section id='migration-2.0-gcc-5'>
2318 <title>GCC 5</title>
2319
2320 <para>
2321 The default compiler is now GCC 5.2.
2322 This change has required fixes for compilation errors in a number
2323 of other recipes.
2324 </para>
2325
2326 <para>
2327 One important example is a fix for when the Linux kernel freezes at
2328 boot time on ARM when built with GCC 5.
2329 If you are using your own kernel recipe or source tree and
2330 building for ARM, you will likely need to apply this
2331 <ulink url='https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit?id=a077224fd35b2f7fbc93f14cf67074fc792fbac2'>patch</ulink>.
2332 The standard <filename>linux-yocto</filename> kernel source tree
2333 already has a workaround for the same issue.
2334 </para>
2335
2336 <para>
2337 For further details, see
2338 <ulink url='https://gcc.gnu.org/gcc-5/changes.html'></ulink> and
2339 the porting guide at
2340 <ulink url='https://gcc.gnu.org/gcc-5/porting_to.html'></ulink>.
2341 </para>
2342
2343 <para>
2344 Alternatively, you can switch back to GCC 4.9 or 4.8 by
2345 setting <filename>GCCVERSION</filename> in your configuration,
2346 as follows:
2347 <literallayout class='monospaced'>
2348 GCCVERSION = "4.9%"
2349 </literallayout>
2350 </para>
2351 </section>
2352
2353 <section id='migration-2.0-Gstreamer-0.10-removed'>
2354 <title>Gstreamer 0.10 Removed</title>
2355
2356 <para>
2357 Gstreamer 0.10 has been removed in favor of Gstreamer 1.x.
2358 As part of the change, recipes for Gstreamer 0.10 and related
2359 software are now located
2360 in <filename>meta-multimedia</filename>.
2361 This change results in Qt4 having Phonon and Gstreamer
2362 support in QtWebkit disabled by default.
2363 </para>
2364 </section>
2365
2366 <section id='migration-2.0-removed-recipes'>
2367 <title>Removed Recipes</title>
2368
2369 <para>
2370 The following recipes have been moved or removed:
2371 <itemizedlist>
2372 <listitem><para>
2373 <filename>bluez4</filename>: The recipe is obsolete and
2374 has been moved due to <filename>bluez5</filename>
2375 becoming fully integrated.
2376 The <filename>bluez4</filename> recipe now resides in
2377 <filename>meta-oe</filename>.
2378 </para></listitem>
2379 <listitem><para>
2380 <filename>gamin</filename>: The recipe is obsolete and
2381 has been removed.
2382 </para></listitem>
2383 <listitem><para>
2384 <filename>gnome-icon-theme</filename>: The recipe's
2385 functionally has been replaced by
2386 <filename>adwaita-icon-theme</filename>.
2387 </para></listitem>
2388 <listitem><para>
2389 Gstreamer 0.10 Recipes: Recipes for Gstreamer 0.10 have
2390 been removed in favor of the recipes for Gstreamer 1.x.
2391 </para></listitem>
2392 <listitem><para>
2393 <filename>insserv</filename>: The recipe is obsolete and
2394 has been removed.
2395 </para></listitem>
2396 <listitem><para>
2397 <filename>libunique</filename>: The recipe is no longer
2398 used and has been moved to <filename>meta-oe</filename>.
2399 </para></listitem>
2400 <listitem><para>
2401 <filename>midori</filename>: The recipe's functionally
2402 has been replaced by <filename>epiphany</filename>.
2403 </para></listitem>
2404 <listitem><para>
2405 <filename>python-gst</filename>: The recipe is obsolete
2406 and has been removed since it only contains bindings for
2407 Gstreamer 0.10.
2408 </para></listitem>
2409 <listitem><para>
2410 <filename>qt-mobility</filename>: The recipe is obsolete and
2411 has been removed since it requires
2412 <filename>Gstreamer 0.10</filename>, which has been
2413 replaced.
2414 </para></listitem>
2415 <listitem><para>
2416 <filename>subversion</filename>: All 1.6.x versions of this
2417 recipe have been removed.
2418 </para></listitem>
2419 <listitem><para>
2420 <filename>webkit-gtk</filename>: The older 1.8.3 version
2421 of this recipe has been removed in favor of
2422 <filename>webkitgtk</filename>.
2423 </para></listitem>
2424 </itemizedlist>
2425 </para>
2426 </section>
2427
2428 <section id='migration-2.0-bitbake-datastore-improvements'>
2429 <title>BitBake datastore improvements</title>
2430
2431 <para>
2432 The method by which BitBake's datastore handles overrides has
2433 changed.
2434 Overrides are now applied dynamically and
2435 <filename>bb.data.update_data()</filename> is now a no-op.
2436 Thus, <filename>bb.data.update_data()</filename> is no longer
2437 required in order to apply the correct overrides.
2438 In practice, this change is unlikely to require any changes to
2439 Metadata.
2440 However, these minor changes in behavior exist:
2441 <itemizedlist>
2442 <listitem><para>
2443 All potential overrides are now visible in the variable
2444 history as seen when you run the following:
2445 <literallayout class='monospaced'>
2446 $ bitbake -e
2447 </literallayout>
2448 </para></listitem>
2449 <listitem><para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -06002450 <filename>d.delVar('</filename><replaceable>VARNAME</replaceable><filename>')</filename> and
2451 <filename>d.setVar('</filename><replaceable>VARNAME</replaceable><filename>', None)</filename>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002452 result in the variable and all of its overrides being
2453 cleared out.
Patrick Williamsf1e5d692016-03-30 15:21:19 -05002454 Before the change, only the non-overridden values
2455 were cleared.
2456 </para></listitem>
2457 </itemizedlist>
2458 </para>
2459 </section>
2460
2461 <section id='migration-2.0-shell-message-function-changes'>
2462 <title>Shell Message Function Changes</title>
2463
2464 <para>
2465 The shell versions of the BitBake message functions (i.e.
2466 <filename>bbdebug</filename>, <filename>bbnote</filename>,
2467 <filename>bbwarn</filename>, <filename>bbplain</filename>,
2468 <filename>bberror</filename>, and <filename>bbfatal</filename>)
2469 are now connected through to their BitBake equivalents
2470 <filename>bb.debug()</filename>, <filename>bb.note()</filename>,
2471 <filename>bb.warn()</filename>, <filename>bb.plain()</filename>,
2472 <filename>bb.error()</filename>, and
2473 <filename>bb.fatal()</filename>, respectively.
2474 Thus, those message functions that you would expect to be printed
2475 by the BitBake UI are now actually printed.
2476 In practice, this change means two things:
2477 <itemizedlist>
2478 <listitem><para>
2479 If you now see messages on the console that you did not
2480 previously see as a result of this change, you might
2481 need to clean up the calls to
2482 <filename>bbwarn</filename>, <filename>bberror</filename>,
2483 and so forth.
2484 Or, you might want to simply remove the calls.
2485 </para></listitem>
2486 <listitem><para>
2487 The <filename>bbfatal</filename> message function now
2488 suppresses the full error log in the UI, which means any
2489 calls to <filename>bbfatal</filename> where you still
2490 wish to see the full error log should be replaced by
2491 <filename>die</filename> or
2492 <filename>bbfatal_log</filename>.
2493 </para></listitem>
2494 </itemizedlist>
2495 </para>
2496 </section>
2497
2498 <section id='migration-2.0-extra-development-debug-package-cleanup'>
2499 <title>Extra Development/Debug Package Cleanup</title>
2500
2501 <para>
2502 The following recipes have had extra
2503 <filename>dev/dbg</filename> packages removed:
2504 <itemizedlist>
2505 <listitem><para>
2506 <filename>acl</filename>
2507 </para></listitem>
2508 <listitem><para>
2509 <filename>apmd</filename>
2510 </para></listitem>
2511 <listitem><para>
2512 <filename>aspell</filename>
2513 </para></listitem>
2514 <listitem><para>
2515 <filename>attr</filename>
2516 </para></listitem>
2517 <listitem><para>
2518 <filename>augeas</filename>
2519 </para></listitem>
2520 <listitem><para>
2521 <filename>bzip2</filename>
2522 </para></listitem>
2523 <listitem><para>
2524 <filename>cogl</filename>
2525 </para></listitem>
2526 <listitem><para>
2527 <filename>curl</filename>
2528 </para></listitem>
2529 <listitem><para>
2530 <filename>elfutils</filename>
2531 </para></listitem>
2532 <listitem><para>
2533 <filename>gcc-target</filename>
2534 </para></listitem>
2535 <listitem><para>
2536 <filename>libgcc</filename>
2537 </para></listitem>
2538 <listitem><para>
2539 <filename>libtool</filename>
2540 </para></listitem>
2541 <listitem><para>
2542 <filename>libxmu</filename>
2543 </para></listitem>
2544 <listitem><para>
2545 <filename>opkg</filename>
2546 </para></listitem>
2547 <listitem><para>
2548 <filename>pciutils</filename>
2549 </para></listitem>
2550 <listitem><para>
2551 <filename>rpm</filename>
2552 </para></listitem>
2553 <listitem><para>
2554 <filename>sysfsutils</filename>
2555 </para></listitem>
2556 <listitem><para>
2557 <filename>tiff</filename>
2558 </para></listitem>
2559 <listitem><para>
2560 <filename>xz</filename>
2561 </para></listitem>
2562 </itemizedlist>
2563 All of the above recipes now conform to the standard packaging
2564 scheme where a single <filename>-dev</filename>,
2565 <filename>-dbg</filename>, and <filename>-staticdev</filename>
2566 package exists per recipe.
2567 </para>
2568 </section>
2569
2570 <section id='migration-2.0-recipe-maintenance-tracking-data-moved-to-oe-core'>
2571 <title>Recipe Maintenance Tracking Data Moved to OE-Core</title>
2572
2573 <para>
2574 Maintenance tracking data for recipes that was previously part
Brad Bishopd7bf8c12018-02-25 22:55:05 -05002575 of <filename>meta-yocto</filename> has been moved to
2576 <link linkend='oe-core'>OE-Core</link>.
Patrick Williamsf1e5d692016-03-30 15:21:19 -05002577 The change includes <filename>package_regex.inc</filename> and
2578 <filename>distro_alias.inc</filename>, which are typically enabled
2579 when using the
2580 <link linkend='ref-classes-distrodata'><filename>distrodata</filename></link>
2581 class.
2582 Additionally, the contents of
2583 <filename>upstream_tracking.inc</filename> has now been split out
2584 to the relevant recipes.
2585 </para>
2586 </section>
2587
2588 <section id='migration-2.0-automatic-stale-sysroot-file-cleanup'>
2589 <title>Automatic Stale Sysroot File Cleanup</title>
2590
2591 <para>
2592 Stale files from recipes that no longer exist in the current
2593 configuration are now automatically removed from
2594 sysroot as well as removed from
2595 any other place managed by shared state.
2596 This automatic cleanup means that the build system now properly
2597 handles situations such as renaming the build system side of
2598 recipes, removal of layers from
2599 <filename>bblayers.conf</filename>, and
2600 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
2601 changes.
2602 </para>
2603
2604 <para>
2605 Additionally, work directories for old versions of recipes are
2606 now pruned.
2607 If you wish to disable pruning old work directories, you can set
2608 the following variable in your configuration:
2609 <literallayout class='monospaced'>
2610 SSTATE_PRUNE_OBSOLETEWORKDIR = "0"
2611 </literallayout>
2612 </para>
2613 </section>
2614
2615 <section id='migration-2.0-linux-yocto-kernel-metadata-repository-now-split-from-source'>
2616 <title><filename>linux-yocto</filename> Kernel Metadata Repository Now Split from Source</title>
2617
2618 <para>
2619 The <filename>linux-yocto</filename> tree has up to now been a
2620 combined set of kernel changes and configuration (meta) data
2621 carried in a single tree.
2622 While this format is effective at keeping kernel configuration and
2623 source modifications synchronized, it is not always obvious to
2624 developers how to manipulate the Metadata as compared to the
2625 source.
2626 </para>
2627
2628 <para>
2629 Metadata processing has now been removed from the
2630 <link linkend='ref-classes-kernel-yocto'><filename>kernel-yocto</filename></link>
2631 class and the external Metadata repository
2632 <filename>yocto-kernel-cache</filename>, which has always been used
2633 to seed the <filename>linux-yocto</filename> "meta" branch.
2634 This separate <filename>linux-yocto</filename> cache repository
2635 is now the primary location for this data.
2636 Due to this change, <filename>linux-yocto</filename> is no longer
2637 able to process combined trees.
2638 Thus, if you need to have your own combined kernel repository,
2639 you must do the split there as well and update your recipes
2640 accordingly.
2641 See the <filename>meta/recipes-kernel/linux/linux-yocto_4.1.bb</filename>
2642 recipe for an example.
2643 </para>
2644 </section>
2645
2646 <section id='migration-2.0-additional-qa-checks'>
2647 <title>Additional QA checks</title>
2648
2649 <para>
2650 The following QA checks have been added:
2651 <itemizedlist>
2652 <listitem><para>
2653 Added a "host-user-contaminated" check for ownership
2654 issues for packaged files outside of
2655 <filename>/home</filename>.
2656 The check looks for files that are incorrectly owned by the
2657 user that ran BitBake instead of owned by a valid user in
2658 the target system.
2659 </para></listitem>
2660 <listitem><para>
2661 Added an "invalid-chars" check for invalid (non-UTF8)
2662 characters in recipe metadata variable values
2663 (i.e.
2664 <link linkend='var-DESCRIPTION'><filename>DESCRIPTION</filename></link>,
2665 <link linkend='var-SUMMARY'><filename>SUMMARY</filename></link>,
2666 <link linkend='var-LICENSE'><filename>LICENSE</filename></link>,
2667 and
2668 <link linkend='var-SECTION'><filename>SECTION</filename></link>).
2669 Some package managers do not support these characters.
2670 </para></listitem>
2671 <listitem><para>
2672 Added an "invalid-packageconfig" check for any options
2673 specified in
2674 <link linkend='var-PACKAGECONFIG'><filename>PACKAGECONFIG</filename></link>
2675 that do not match any <filename>PACKAGECONFIG</filename>
2676 option defined for the recipe.
2677 </para></listitem>
2678 </itemizedlist>
2679 </para>
2680 </section>
2681
2682 <section id='migration-2.0-miscellaneous'>
2683 <title>Miscellaneous Changes</title>
2684
2685 <para>
2686 These additional changes exist:
2687 <itemizedlist>
2688 <listitem><para>
2689 <filename>gtk-update-icon-cache</filename> has been
2690 renamed to <filename>gtk-icon-utils</filename>.
2691 </para></listitem>
2692 <listitem><para>
2693 The <filename>tools-profile</filename>
2694 <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>
2695 item as well as its corresponding packagegroup and
2696 <filename>packagegroup-core-tools-profile</filename> no
2697 longer bring in <filename>oprofile</filename>.
2698 Bringing in <filename>oprofile</filename> was originally
2699 added to aid compilation on resource-constrained
2700 targets.
2701 However, this aid has not been widely used and is not
2702 likely to be used going forward due to the more powerful
2703 target platforms and the existence of better
2704 cross-compilation tools.
2705 </para></listitem>
2706 <listitem><para>
2707 The
2708 <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
2709 variable's default value now specifies
2710 <filename>ext4</filename> instead of
2711 <filename>ext3</filename>.
2712 </para></listitem>
2713 <listitem><para>
2714 All support for the <filename>PRINC</filename>
2715 variable has been removed.
2716 </para></listitem>
2717 <listitem><para>
2718 The <filename>packagegroup-core-full-cmdline</filename>
2719 packagegroup no longer brings in
2720 <filename>lighttpd</filename> due to the fact that
2721 bringing in <filename>lighttpd</filename> is not really in
2722 line with the packagegroup's purpose, which is to add full
2723 versions of command-line tools that by default are
2724 provided by <filename>busybox</filename>.
2725 </para></listitem>
2726 </itemizedlist>
2727 </para>
2728 </section>
2729</section>
2730
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002731<section id='moving-to-the-yocto-project-2.1-release'>
2732 <title>Moving to the Yocto Project 2.1 Release</title>
2733
2734 <para>
2735 This section provides migration information for moving to the
2736 Yocto Project 2.1 Release from the prior release.
2737 </para>
2738
2739 <section id='migration-2.1-variable-expansion-in-python-functions'>
2740 <title>Variable Expansion in Python Functions</title>
2741
2742 <para>
2743 Variable expressions, such as
Patrick Williamsc0f7c042017-02-23 20:41:17 -06002744 <filename>${</filename><replaceable>VARNAME</replaceable><filename>}</filename>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002745 no longer expand automatically within Python functions.
2746 Suppressing expansion was done to allow Python functions to
2747 construct shell scripts or other code for situations in which you
2748 do not want such expressions expanded.
2749 For any existing code that relies on these expansions, you need to
Patrick Williamsc0f7c042017-02-23 20:41:17 -06002750 change the expansions to expand the value of individual
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002751 variables through <filename>d.getVar()</filename>.
2752 To alternatively expand more complex expressions,
2753 use <filename>d.expand()</filename>.
2754 </para>
2755 </section>
2756
2757 <section id='migration-2.1-overrides-must-now-be-lower-case'>
2758 <title>Overrides Must Now be Lower-Case</title>
2759
2760 <para>
2761 The convention for overrides has always been for them to be
2762 lower-case characters.
2763 This practice is now a requirement as BitBake's datastore now
2764 assumes lower-case characters in order to give a slight performance
2765 boost during parsing.
2766 In practical terms, this requirement means that anything that ends
2767 up in
2768 <link linkend='var-OVERRIDES'><filename>OVERRIDES</filename></link>
2769 must now appear in lower-case characters (e.g. values for
2770 <filename>MACHINE</filename>, <filename>TARGET_ARCH</filename>,
2771 <filename>DISTRO</filename>, and also recipe names if
2772 <filename>_pn-</filename><replaceable>recipename</replaceable>
2773 overrides are to be effective).
2774 </para>
2775 </section>
2776
2777 <section id='migration-2.1-expand-parameter-to-getvar-and-getvarflag-now-mandatory'>
2778 <title>Expand Parameter to <filename>getVar()</filename> and
2779 <filename>getVarFlag()</filename> is Now Mandatory</title>
2780
2781 <para>
2782 The expand parameter to <filename>getVar()</filename> and
2783 <filename>getVarFlag()</filename> previously defaulted to
2784 False if not specified.
2785 Now, however, no default exists so one must be specified.
2786 You must change any <filename>getVar()</filename> calls that
2787 do not specify the final expand parameter to calls that do specify
2788 the parameter.
2789 You can run the following <filename>sed</filename> command at the
2790 base of a layer to make this change:
2791 <literallayout class='monospaced'>
2792 sed -e 's:\(\.getVar([^,()]*\)):\1, False):g' -i `grep -ril getVar *`
2793 sed -e 's:\(\.getVarFlag([^,()]*, [^,()]*\)):\1, False):g' -i `grep -ril getVarFlag *`
2794 </literallayout>
2795 <note>
2796 The reason for this change is that it prepares the way for
2797 changing the default to True in a future Yocto Project release.
2798 This future change is a much more sensible default than False.
2799 However, the change needs to be made gradually as a sudden
2800 change of the default would potentially cause side-effects
2801 that would be difficult to detect.
2802 </note>
2803 </para>
2804 </section>
2805
2806 <section id='migration-2.1-makefile-environment-changes'>
2807 <title>Makefile Environment Changes</title>
2808
2809 <para>
2810 <link linkend='var-EXTRA_OEMAKE'><filename>EXTRA_OEMAKE</filename></link>
2811 now defaults to "" instead of "-e MAKEFLAGS=".
2812 Setting <filename>EXTRA_OEMAKE</filename> to "-e MAKEFLAGS=" by
2813 default was a historical accident that has required many classes
2814 (e.g. <filename>autotools</filename>, <filename>module</filename>)
2815 and recipes to override this default in order to work with
2816 sensible build systems.
2817 When upgrading to the release, you must edit any recipe that
2818 relies upon this old default by either setting
2819 <filename>EXTRA_OEMAKE</filename> back to "-e MAKEFLAGS=" or by
2820 explicitly setting any required variable value overrides using
2821 <filename>EXTRA_OEMAKE</filename>, which is typically only needed
2822 when a Makefile sets a default value for a variable that is
2823 inappropriate for cross-compilation using the "=" operator rather
2824 than the "?=" operator.
2825 </para>
2826 </section>
2827
2828 <section id='migration-2.1-libexecdir-reverted-to-prefix-libexec'>
2829 <title><filename>libexecdir</filename> Reverted to <filename>${prefix}/libexec</filename></title>
2830
2831 <para>
2832 The use of <filename>${libdir}/${BPN}</filename> as
2833 <filename>libexecdir</filename> is different as compared to all
2834 other mainstream distributions, which either uses
2835 <filename>${prefix}/libexec</filename> or
2836 <filename>${libdir}</filename>.
2837 The use is also contrary to the GNU Coding Standards
2838 (i.e. <ulink url='https://www.gnu.org/prep/standards/html_node/Directory-Variables.html'></ulink>)
2839 that suggest <filename>${prefix}/libexec</filename> and also
2840 notes that any package-specific nesting should be done by the
2841 package itself.
2842 Finally, having <filename>libexecdir</filename> change between
2843 recipes makes it very difficult for different recipes to invoke
2844 binaries that have been installed into
2845 <filename>libexecdir</filename>.
2846 The Filesystem Hierarchy Standard
2847 (i.e. <ulink url='http://refspecs.linuxfoundation.org/FHS_3.0/fhs/ch04s07.html'></ulink>)
2848 now recognizes the use of <filename>${prefix}/libexec/</filename>,
2849 giving distributions the choice between
2850 <filename>${prefix}/lib</filename> or
2851 <filename>${prefix}/libexec</filename> without breaking FHS.
2852 </para>
2853 </section>
2854
2855 <section id='migration-2.1-ac-cv-sizeof-off-t-no-longer-cached-in-site-files'>
2856 <title><filename>ac_cv_sizeof_off_t</filename> is No Longer Cached in Site Files</title>
2857
2858 <para>
2859 For recipes inheriting the
2860 <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
2861 class, <filename>ac_cv_sizeof_off_t</filename> is no longer cached
2862 in the site files for <filename>autoconf</filename>.
2863 The reason for this change is because the
2864 <filename>ac_cv_sizeof_off_t</filename> value is not necessarily
2865 static per architecture as was previously assumed.
2866 Rather, the value changes based on whether large file support is
2867 enabled.
2868 For most software that uses <filename>autoconf</filename>, this
2869 change should not be a problem.
2870 However, if you have a recipe that bypasses the standard
2871 <link linkend='ref-tasks-configure'><filename>do_configure</filename></link>
2872 task from the <filename>autotools</filename> class and the software
2873 the recipe is building uses a very old version of
2874 <filename>autoconf</filename>, the recipe might be incapable of
2875 determining the correct size of <filename>off_t</filename> during
2876 <filename>do_configure</filename>.
2877 </para>
2878
2879 <para>
2880 The best course of action is to patch the software as necessary
2881 to allow the default implementation from the
2882 <filename>autotools</filename> class to work such that
2883 <filename>autoreconf</filename> succeeds and produces a working
Patrick Williamsc0f7c042017-02-23 20:41:17 -06002884 configure script, and to remove the
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002885 overridden <filename>do_configure</filename> task such that the
2886 default implementation does get used.
2887 </para>
2888 </section>
2889
2890 <section id='migration-2.1-image-generation-split-out-from-filesystem-generation'>
2891 <title>Image Generation is Now Split Out from Filesystem Generation</title>
2892
2893 <para>
2894 Previously, for image recipes the
2895 <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
2896 task assembled the filesystem and then from that filesystem
2897 generated images.
2898 With this Yocto Project release, image generation is split into
2899 separate
2900 <link linkend='ref-tasks-image'><filename>do_image_*</filename></link>
2901 tasks for clarity both in operation and in the code.
2902 </para>
2903
2904 <para>
2905 For most cases, this change does not present any problems.
2906 However, if you have made customizations that directly modify the
2907 <filename>do_rootfs</filename> task or that mention
2908 <filename>do_rootfs</filename>, you might need to update those
2909 changes.
2910 In particular, if you had added any tasks after
2911 <filename>do_rootfs</filename>, you should make edits so that
2912 those tasks are after the
2913 <link linkend='ref-tasks-image-complete'><filename>do_image_complete</filename></link>
Patrick Williamsc0f7c042017-02-23 20:41:17 -06002914 task rather than after <filename>do_rootfs</filename>
2915 so that the your added tasks
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05002916 run at the correct time.
2917 </para>
2918
2919 <para>
2920 A minor part of this restructuring is that the post-processing
2921 definitions and functions have been moved from the
2922 <link linkend='ref-classes-image'><filename>image</filename></link>
2923 class to the
2924 <link linkend='ref-classes-rootfs*'><filename>rootfs-postcommands</filename></link>
2925 class.
2926 Functionally, however, they remain unchanged.
2927 </para>
2928 </section>
2929
2930 <section id='migration-2.1-removed-recipes'>
2931 <title>Removed Recipes</title>
2932
2933 <para>
2934 The following recipes have been removed in the 2.1 release:
2935 <itemizedlist>
2936 <listitem><para><filename>gcc</filename> version 4.8:
2937 Versions 4.9 and 5.3 remain.
2938 </para></listitem>
2939 <listitem><para><filename>qt4</filename>:
2940 All support for Qt 4.x has been moved out to a separate
2941 <filename>meta-qt4</filename> layer because Qt 4 is no
2942 longer supported upstream.
2943 </para></listitem>
2944 <listitem><para><filename>x11vnc</filename>:
2945 Moved to the <filename>meta-oe</filename> layer.
2946 </para></listitem>
2947 <listitem><para><filename>linux-yocto-3.14</filename>:
2948 No longer supported.
2949 </para></listitem>
2950 <listitem><para><filename>linux-yocto-3.19</filename>:
2951 No longer supported.
2952 </para></listitem>
2953 <listitem><para><filename>libjpeg</filename>:
2954 Replaced by the <filename>libjpeg-turbo</filename> recipe.
2955 </para></listitem>
2956 <listitem><para><filename>pth</filename>:
2957 Became obsolete.
2958 </para></listitem>
2959 <listitem><para><filename>liboil</filename>:
2960 Recipe is no longer needed and has been moved to the
2961 <filename>meta-multimedia</filename> layer.
2962 </para></listitem>
2963 <listitem><para><filename>gtk-theme-torturer</filename>:
2964 Recipe is no longer needed and has been moved to the
2965 <filename>meta-gnome</filename> layer.
2966 </para></listitem>
2967 <listitem><para><filename>gnome-mime-data</filename>:
2968 Recipe is no longer needed and has been moved to the
2969 <filename>meta-gnome</filename> layer.
2970 </para></listitem>
2971 <listitem><para><filename>udev</filename>:
2972 Replaced by the <filename>eudev</filename> recipe for
2973 compatibility when using <filename>sysvinit</filename>
2974 with newer kernels.
2975 </para></listitem>
2976 <listitem><para><filename>python-pygtk</filename>:
2977 Recipe became obsolete.
2978 </para></listitem>
2979 <listitem><para><filename>adt-installer</filename>:
2980 Recipe became obsolete.
2981 See the
2982 "<link linkend='migration-2.1-adt-removed'>ADT Removed</link>"
2983 section for more information.
2984 </para></listitem>
2985 </itemizedlist>
2986 </para>
2987 </section>
2988
2989 <section id='migration-2.1-class-changes'>
2990 <title>Class Changes</title>
2991
2992 <para>
2993 The following classes have changed:
2994 <itemizedlist>
2995 <listitem><para><filename>autotools_stage</filename>:
2996 Removed because the
2997 <link linkend='ref-classes-autotools'><filename>autotools</filename></link>
2998 class now provides its functionality.
2999 Recipes that inherited from
3000 <filename>autotools_stage</filename> should now inherit
3001 from <filename>autotools</filename> instead.
3002 </para></listitem>
3003 <listitem><para><filename>boot-directdisk</filename>:
Brad Bishopd7bf8c12018-02-25 22:55:05 -05003004 Merged into the <filename>image-vm</filename>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003005 class.
3006 The <filename>boot-directdisk</filename> class was rarely
3007 directly used.
3008 Consequently, this change should not cause any issues.
3009 </para></listitem>
3010 <listitem><para><filename>bootimg</filename>:
3011 Merged into the
3012 <link linkend='ref-classes-image-live'><filename>image-live</filename></link>
3013 class.
3014 The <filename>bootimg</filename> class was rarely
3015 directly used.
3016 Consequently, this change should not cause any issues.
3017 </para></listitem>
3018 <listitem><para><filename>packageinfo</filename>:
3019 Removed due to its limited use by the Hob UI, which has
3020 itself been removed.
3021 </para></listitem>
3022 </itemizedlist>
3023 </para>
3024 </section>
3025
3026 <section id='migration-2.1-build-system-ui-changes'>
3027 <title>Build System User Interface Changes</title>
3028
3029 <para>
3030 The following changes have been made to the build system user
3031 interface:
3032 <itemizedlist>
3033 <listitem><para><emphasis>Hob GTK+-based UI</emphasis>:
3034 Removed because it is unmaintained and based on the
3035 outdated GTK+ 2 library.
3036 The Toaster web-based UI is much more capable and is
3037 actively maintained.
3038 See the
3039 "<ulink url='&YOCTO_DOCS_TOAST_URL;#using-the-toaster-web-interface'>Using the Toaster Web Interface</ulink>"
3040 section in the Yocto Project Toaster User Manual for more
3041 information on this interface.
3042 </para></listitem>
3043 <listitem><para><emphasis>"puccho" BitBake UI</emphasis>:
3044 Removed because is unmaintained and no longer useful.
3045 </para></listitem>
3046 </itemizedlist>
3047 </para>
3048 </section>
3049
3050 <section id='migration-2.1-adt-removed'>
3051 <title>ADT Removed</title>
3052
3053 <para>
3054 The Application Development Toolkit (ADT) has been removed
3055 because its functionality almost completely overlapped with the
3056 <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-using-the-standard-sdk'>standard SDK</ulink>
3057 and the
3058 <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-extensible'>extensible SDK</ulink>.
3059 For information on these SDKs and how to build and use them, see the
3060 <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-intro'>Yocto Project Software Development Kit (SDK) Developer's Guide</ulink>.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003061 <note>
3062 The Yocto Project Eclipse IDE Plug-in is still supported and
3063 is not affected by this change.
3064 </note>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003065 </para>
3066 </section>
3067
3068 <section id='migration-2.1-poky-reference-distribution-changes'>
3069 <title>Poky Reference Distribution Changes</title>
3070
3071 <para>
3072 The following changes have been made for the Poky distribution:
3073 <itemizedlist>
3074 <listitem><para>
3075 The <filename>meta-yocto</filename> layer has been renamed
3076 to <filename>meta-poky</filename> to better match its
3077 purpose, which is to provide the Poky reference
3078 distribution.
3079 The <filename>meta-yocto-bsp</filename> layer retains its
3080 original name since it provides reference machines for
3081 the Yocto Project and it is otherwise unrelated to Poky.
3082 References to <filename>meta-yocto</filename> in your
3083 <filename>conf/bblayers.conf</filename> should
3084 automatically be updated, so you should not need to change
3085 anything unless you are relying on this naming elsewhere.
3086 </para></listitem>
3087 <listitem><para>
3088 The
3089 <link linkend='ref-classes-uninative'><filename>uninative</filename></link>
3090 class is now enabled by default in Poky.
3091 This class attempts to isolate the build system from the
3092 host distribution's C library and makes re-use of native
3093 shared state artifacts across different host distributions
3094 practical.
3095 With this class enabled, a tarball containing a pre-built
3096 C library is downloaded at the start of the build.</para>
3097
3098 <para>The <filename>uninative</filename> class is enabled
3099 through the
3100 <filename>meta/conf/distro/include/yocto-uninative.inc</filename>
3101 file, which for those not using the Poky distribution, can
3102 include to easily enable the same functionality.</para>
3103
3104 <para>Alternatively, if you wish to build your own
3105 <filename>uninative</filename> tarball, you can do so by
3106 building the <filename>uninative-tarball</filename> recipe,
3107 making it available to your build machines
3108 (e.g. over HTTP/HTTPS) and setting a similar configuration
3109 as the one set by <filename>yocto-uninative.inc</filename>.
3110 </para></listitem>
3111 <listitem><para>
3112 Static library generation, for most cases, is now disabled
3113 by default in the Poky distribution.
3114 Disabling this generation saves some build time as well
3115 as the size used for build output artifacts.</para>
3116
3117 <para>Disabling this library generation is accomplished
3118 through a
3119 <filename>meta/conf/distro/include/no-static-libs.inc</filename>,
3120 which for those not using the Poky distribution can
3121 easily include to enable the same functionality.</para>
3122
3123 <para>Any recipe that needs to opt-out of having the
3124 "--disable-static" option specified on the configure
3125 command line either because it is not a supported option
3126 for the configure script or because static libraries are
3127 needed should set the following variable:
3128 <literallayout class='monospaced'>
3129 DISABLE_STATIC = ""
3130 </literallayout>
3131 </para></listitem>
3132 <listitem><para>
3133 The separate <filename>poky-tiny</filename> distribution
3134 now uses the musl C library instead of a heavily pared
3135 down <filename>glibc</filename>.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003136 Using musl results in a smaller
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003137 distribution and facilitates much greater maintainability
3138 because musl is designed to have a small footprint.</para>
3139
3140 <para>If you have used <filename>poky-tiny</filename> and
3141 have customized the <filename>glibc</filename>
3142 configuration you will need to redo those customizations
3143 with musl when upgrading to the new release.
3144 </para></listitem>
3145 </itemizedlist>
3146 </para>
3147 </section>
3148
3149 <section id='migration-2.1-packaging-changes'>
3150 <title>Packaging Changes</title>
3151
3152 <para>
3153 The following changes have been made to packaging:
3154 <itemizedlist>
3155 <listitem><para>
3156 The <filename>runuser</filename> and
3157 <filename>mountpoint</filename> binaries, which were
3158 previously in the main <filename>util-linux</filename>
3159 package, have been split out into the
3160 <filename>util-linux-runuser</filename> and
3161 <filename>util-linux-mountpoint</filename> packages,
3162 respectively.
3163 </para></listitem>
3164 <listitem><para>
3165 The <filename>python-elementtree</filename> package has
3166 been merged into the <filename>python-xml</filename>
3167 package.
3168 </para></listitem>
3169 </itemizedlist>
3170 </para>
3171 </section>
3172
3173 <section id='migration-2.1-tuning-file-changes'>
3174 <title>Tuning File Changes</title>
3175
3176 <para>
3177 The following changes have been made to the tuning files:
3178 <itemizedlist>
3179 <listitem><para>
3180 The "no-thumb-interwork" tuning feature has been dropped
3181 from the ARM tune include files.
3182 Because interworking is required for ARM EABI, attempting
3183 to disable it through a tuning feature no longer makes
3184 sense.
3185 <note>
3186 Support for ARM OABI was deprecated in gcc 4.7.
3187 </note>
3188 </para></listitem>
3189 <listitem><para>
3190 The <filename>tune-cortexm*.inc</filename> and
3191 <filename>tune-cortexr4.inc</filename> files have been
3192 removed because they are poorly tested.
3193 Until the OpenEmbedded build system officially gains
3194 support for CPUs without an MMU, these tuning files would
3195 probably be better maintained in a separate layer
3196 if needed.
3197 </para></listitem>
3198 </itemizedlist>
3199 </para>
3200 </section>
3201
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003202 <section id='migration-2.1-supporting-gobject-introspection'>
3203 <title>Supporting GObject Introspection</title>
3204
3205 <para>
3206 This release supports generation of GLib Introspective
3207 Repository (GIR) files through GObject introspection, which is
3208 the standard mechanism for accessing GObject-based software from
3209 runtime environments.
3210 You can enable, disable, and test the generation of this data.
3211 See the
3212 "<ulink url='&YOCTO_DOCS_DEV_URL;#enabling-gobject-introspection-support'>Enabling GObject Introspection Support</ulink>"
Brad Bishopd7bf8c12018-02-25 22:55:05 -05003213 section in the Yocto Project Development Tasks Manual
3214 for more information.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003215 </para>
3216 </section>
3217
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003218 <section id='migration-2.1-miscellaneous-changes'>
3219 <title>Miscellaneous Changes</title>
3220
3221 <para>
3222 These additional changes exist:
3223 <itemizedlist>
3224 <listitem><para>
3225 The minimum Git version has been increased to 1.8.3.1.
3226 If your host distribution does not provide a sufficiently
3227 recent version, you can install the buildtools, which
3228 will provide it.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003229 See the
3230 "<link linkend='required-git-tar-and-python-versions'>Required Git, tar, and Python Versions</link>"
3231 section for more information on the buildtools tarball.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003232 </para></listitem>
3233 <listitem><para>
3234 The buggy and incomplete support for the RPM version 4
3235 package manager has been removed.
3236 The well-tested and maintained support for RPM version 5
3237 remains.
3238 </para></listitem>
3239 <listitem><para>
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003240 Previously, the following list of packages were removed
3241 if package-management was not in
3242 <link linkend='var-IMAGE_FEATURES'><filename>IMAGE_FEATURES</filename></link>,
3243 regardless of any dependencies:
3244 <literallayout class='monospaced'>
3245 update-rc.d
3246 base-passwd
3247 shadow
3248 update-alternatives
3249 run-postinsts
3250 </literallayout>
3251 With the Yocto Project 2.1 release, these packages are only
3252 removed if "read-only-rootfs" is in
3253 <filename>IMAGE_FEATURES</filename>, since they might
3254 still be needed for a read-write image even in the absence
3255 of a package manager (e.g. if users need to be added,
3256 modified, or removed at runtime).
3257 </para></listitem>
3258 <listitem><para>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003259 The
3260 <ulink url='&YOCTO_DOCS_SDK_URL;#sdk-devtool-use-devtool-modify-to-modify-the-source-of-an-existing-component'><filename>devtool modify</filename></ulink>
3261 command now defaults to extracting the source since that
3262 is most commonly expected.
3263 The "-x" or "--extract" options are now no-ops.
3264 If you wish to provide your own existing source tree, you
3265 will now need to specify either the "-n" or
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003266 "--no-extract" options when running
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003267 <filename>devtool modify</filename>.
3268 </para></listitem>
3269 <listitem><para>
3270 If the formfactor for a machine is either not supplied
3271 or does not specify whether a keyboard is attached, then
3272 the default is to assume a keyboard is attached rather
3273 than assume no keyboard.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003274 This change primarily affects the Sato UI.
3275 </para></listitem>
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003276 <listitem><para>
3277 The <filename>.debug</filename> directory packaging is
3278 now automatic.
3279 If your recipe builds software that installs binaries into
3280 directories other than the standard ones, you no longer
3281 need to take care of setting
3282 <filename>FILES_${PN}-dbg</filename> to pick up the
3283 resulting <filename>.debug</filename> directories as these
3284 directories are automatically found and added.
3285 </para></listitem>
3286 <listitem><para>
3287 Inaccurate disk and CPU percentage data has been dropped
3288 from <filename>buildstats</filename> output.
3289 This data has been replaced with
3290 <filename>getrusage()</filename> data and corrected IO
3291 statistics.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003292 You will probably need to update any custom code that reads
3293 the <filename>buildstats</filename> data.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003294 </para></listitem>
3295 <listitem><para>
3296 The
3297 <filename>meta/conf/distro/include/package_regex.inc</filename>
3298 is now deprecated.
3299 The contents of this file have been moved to individual
3300 recipes.
3301 <note><title>Tip</title>
3302 Because this file will likely be removed in a future
3303 Yocto Project release, it is suggested that you remove
3304 any references to the file that might be in your
3305 configuration.
3306 </note>
3307 </para></listitem>
3308 <listitem><para>
3309 The <filename>v86d/uvesafb</filename> has been removed from
3310 the <filename>genericx86</filename> and
3311 <filename>genericx86-64</filename> reference machines,
3312 which are provided by the
3313 <filename>meta-yocto-bsp</filename> layer.
3314 Most modern x86 boards do not rely on this file and it only
3315 adds kernel error messages during startup.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003316 If you do still need to support
3317 <filename>uvesafb</filename>, you can
3318 simply add <filename>v86d</filename> to your image.
3319 </para></listitem>
3320 <listitem><para>
3321 Build sysroot paths are now removed from debug symbol
3322 files.
3323 Removing these paths means that remote GDB using an
3324 unstripped build system sysroot will no longer work
3325 (although this was never documented to work).
3326 The supported method to accomplish something similar is
3327 to set <filename>IMAGE_GEN_DEBUGFS</filename> to "1",
3328 which will generate a companion debug image
3329 containing unstripped binaries and associated debug
3330 sources alongside the image.
3331 </para></listitem>
3332 </itemizedlist>
3333 </para>
3334 </section>
3335</section>
3336
3337<section id='moving-to-the-yocto-project-2.2-release'>
3338 <title>Moving to the Yocto Project 2.2 Release</title>
3339
3340 <para>
3341 This section provides migration information for moving to the
3342 Yocto Project 2.2 Release from the prior release.
3343 </para>
3344
3345 <section id='migration-2.2-minimum-kernel-version'>
3346 <title>Minimum Kernel Version</title>
3347
3348 <para>
3349 The minimum kernel version for the target system and for SDK
3350 is now 3.2.0, due to the upgrade
3351 to <filename>glibc 2.24</filename>.
3352 Specifically, for AArch64-based targets the version is
3353 3.14.
3354 For Nios II-based targets, the minimum kernel version is 3.19.
3355 <note>
3356 For x86 and x86_64, you can reset
3357 <link linkend='var-OLDEST_KERNEL'><filename>OLDEST_KERNEL</filename></link>
3358 to anything down to 2.6.32 if desired.
3359 </note>
3360 </para>
3361 </section>
3362
3363 <section id='migration-2.2-staging-directories-in-sysroot-simplified'>
3364 <title>Staging Directories in Sysroot Has Been Simplified</title>
3365
3366 <para>
3367 The way directories are staged in sysroot has been simplified and
3368 introduces the new
3369 <link linkend='var-SYSROOT_DIRS'><filename>SYSROOT_DIRS</filename></link>,
3370 <link linkend='var-SYSROOT_DIRS_NATIVE'><filename>SYSROOT_DIRS_NATIVE</filename></link>,
3371 and
3372 <link linkend='var-SYSROOT_DIRS_BLACKLIST'><filename>SYSROOT_DIRS_BLACKLIST</filename></link>.
3373 See the
3374 <ulink url='http://lists.openembedded.org/pipermail/openembedded-core/2016-May/121365.html'>v2 patch series on the OE-Core Mailing List</ulink>
3375 for additional information.
3376 </para>
3377 </section>
3378
3379 <section id='migration-2.2-removal-of-old-images-from-tmp-deploy-now-enabled'>
3380 <title>Removal of Old Images and Other Files in <filename>tmp/deploy</filename> Now Enabled</title>
3381
3382 <para>
3383 Removal of old images and other files in
3384 <filename>tmp/deploy/</filename> is now enabled by default due
3385 to a new staging method used for those files.
3386 As a result of this change, the
3387 <filename>RM_OLD_IMAGE</filename> variable is now redundant.
3388 </para>
3389 </section>
3390
3391 <section id='migration-2.2-python-changes'>
3392 <title>Python Changes</title>
3393
3394 <para>
3395 The following changes for Python occurred:
3396 </para>
3397
3398 <section id='migration-2.2-bitbake-now-requires-python-3.4'>
3399 <title>BitBake Now Requires Python 3.4+</title>
3400
3401 <para>
3402 BitBake requires Python 3.4 or greater.
3403 </para>
3404 </section>
3405
3406 <section id='migration-2.2-utf-8-locale-required-on-build-host'>
3407 <title>UTF-8 Locale Required on Build Host</title>
3408
3409 <para>
3410 A UTF-8 locale is required on the build host due to Python 3.
3411 Since C.UTF-8 is not a standard, the default is en_US.UTF-8.
3412 </para>
3413 </section>
3414
3415 <section id='migration-2.2-metadata-now-must-use-python-3-syntax'>
3416 <title>Metadata Must Now Use Python 3 Syntax</title>
3417
3418 <para>
3419 The metadata is now required to use Python 3 syntax.
3420 For help preparing metadata, see any of the many Python 3 porting
3421 guides available.
3422 Alternatively, you can reference the conversion commits for Bitbake
Brad Bishopd7bf8c12018-02-25 22:55:05 -05003423 and you can use
3424 <link linkend='oe-core'>OE-Core</link> as a guide for changes.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003425 Following are particular areas of interest:
3426 <literallayout class='monospaced'>
3427 * subprocess command-line pipes needing locale decoding
3428 * the syntax for octal values changed
3429 * the <filename>iter*()</filename> functions changed name
3430 * iterators now return views, not lists
3431 * changed names for Python modules
3432 </literallayout>
3433 </para>
3434 </section>
3435
3436 <section id='migration-2.2-target-python-recipes-switched-to-python-3'>
3437 <title>Target Python Recipes Switched to Python 3</title>
3438
3439 <para>
3440 Most target Python recipes have now been switched to Python 3.
3441 Unfortunately, systems using RPM as a package manager and
3442 providing online package-manager support through SMART still
3443 require Python 2.
3444 <note>
3445 Python 2 and recipes that use it can still be built for the
3446 target as with previous versions.
3447 </note>
3448 </para>
3449 </section>
3450
3451 <section id='migration-2.2-buildtools-tarball-includes-python-3'>
3452 <title><filename>buildtools-tarball</filename> Includes Python 3</title>
3453
3454 <para>
3455 <filename>buildtools-tarball</filename> now includes Python 3.
3456 </para>
3457 </section>
3458 </section>
3459
3460 <section id='migration-2.2-uclibc-replaced-by-musl'>
3461 <title>uClibc Replaced by musl</title>
3462
3463 <para>
3464 uClibc has been removed in favor of musl.
3465 Musl has matured, is better maintained, and is compatible with a
3466 wider range of applications as compared to uClibc.
3467 </para>
3468 </section>
3469
3470 <section id='migration-2.2-B-no-longer-default-working-directory-for-tasks'>
3471 <title><filename>${B}</filename> No Longer Default Working Directory for Tasks</title>
3472
3473 <para>
3474 <filename>${</filename><link linkend='var-B'><filename>B</filename></link><filename>}</filename>
3475 is no longer the default working directory for tasks.
3476 Consequently, any custom tasks you define now need to either
3477 have the
3478 <filename>[</filename><ulink url='&YOCTO_DOCS_BB_URL;#variable-flags'><filename>dirs</filename></ulink><filename>]</filename> flag set, or the task needs to change into the
3479 appropriate working directory manually (e.g using
3480 <filename>cd</filename> for a shell task).
3481 <note>
3482 The preferred method is to use the
3483 <filename>[dirs]</filename> flag.
3484 </note>
3485 </para>
3486 </section>
3487
3488 <section id='migration-2.2-runqemu-ported-to-python'>
3489 <title><filename>runqemu</filename> Ported to Python</title>
3490
3491 <para>
3492 <filename>runqemu</filename> has been ported to Python and has
3493 changed behavior in some cases.
Brad Bishop37a0e4d2017-12-04 01:01:44 -05003494 Previous usage patterns continue to be supported.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003495 </para>
3496
3497 <para>
3498 The new <filename>runqemu</filename> is a Python script.
3499 Machine knowledge is no longer hardcoded into
3500 <filename>runqemu</filename>.
3501 You can choose to use the <filename>qemuboot</filename>
3502 configuration file to define the BSP's own arguments and to make
3503 it bootable with <filename>runqemu</filename>.
3504 If you use a configuration file, use the following form:
3505 <literallayout class='monospaced'>
3506 <replaceable>image-name</replaceable>-<replaceable>machine</replaceable>.qemuboot.conf
3507 </literallayout>
3508 The configuration file enables fine-grained tuning of options
3509 passed to QEMU without the <filename>runqemu</filename> script
3510 hard-coding any knowledge about different machines.
3511 Using a configuration file is particularly convenient when trying
3512 to use QEMU with machines other than the
Brad Bishopd7bf8c12018-02-25 22:55:05 -05003513 <filename>qemu*</filename> machines in
3514 <link linkend='oe-core'>OE-Core</link>.
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003515 The <filename>qemuboot.conf</filename> file is generated by the
3516 <filename>qemuboot</filename>
3517 class when the root filesystem is being build (i.e.
3518 build rootfs).
3519 QEMU boot arguments can be set in BSP's configuration file and
3520 the <filename>qemuboot</filename> class will save them to
3521 <filename>qemuboot.conf</filename>.
3522 </para>
3523
3524
3525 <para>
3526 If you want to use <filename>runqemu</filename> without a
3527 configuration file, use the following command form:
3528 <literallayout class='monospaced'>
3529 $ runqemu <replaceable>machine</replaceable> <replaceable>rootfs</replaceable> <replaceable>kernel</replaceable> [<replaceable>options</replaceable>]
3530 </literallayout>
3531 Supported <replaceable>machines</replaceable> are as follows:
3532 <literallayout class='monospaced'>
3533 qemuarm
3534 qemuarm64
3535 qemux86
3536 qemux86-64
3537 qemuppc
3538 qemumips
3539 qemumips64
3540 qemumipsel
3541 qemumips64el
3542 </literallayout>
3543 Consider the following example, which uses the
3544 <filename>qemux86-64</filename> machine,
3545 provides a root filesystem, provides an image, and uses
3546 the <filename>nographic</filename> option:
3547 <literallayout class='monospaced'>
3548$ runqemu qemux86-64 tmp/deploy/images/qemux86-64/core-image-minimal-qemux86-64.ext4 tmp/deploy/images/qemux86-64/bzImage nographic
3549 </literallayout>
3550 </para>
3551
3552 <para>
3553 Following is a list of variables that can be set in configuration
3554 files such as <filename>bsp.conf</filename> to enable the BSP
3555 to be booted by <filename>runqemu</filename>:
3556 <note>
3557 "QB" means "QEMU Boot".
3558 </note>
3559 <literallayout class='monospaced'>
3560 QB_SYSTEM_NAME: QEMU name (e.g. "qemu-system-i386")
3561 QB_OPT_APPEND: Options to append to QEMU (e.g. "-show-cursor")
3562 QB_DEFAULT_KERNEL: Default kernel to boot (e.g. "bzImage")
3563 QB_DEFAULT_FSTYPE: Default FSTYPE to boot (e.g. "ext4")
3564 QB_MEM: Memory (e.g. "-m 512")
3565 QB_MACHINE: QEMU machine (e.g. "-machine virt")
3566 QB_CPU: QEMU cpu (e.g. "-cpu qemu32")
3567 QB_CPU_KVM: Similar to QB_CPU except used for kvm support (e.g. "-cpu kvm64")
3568 QB_KERNEL_CMDLINE_APPEND: Options to append to the kernel's -append
3569 option (e.g. "console=ttyS0 console=tty")
3570 QB_DTB: QEMU dtb name
3571 QB_AUDIO_DRV: QEMU audio driver (e.g. "alsa", set it when support audio)
3572 QB_AUDIO_OPT: QEMU audio option (e.g. "-soundhw ac97,es1370"), which is used
3573 when QB_AUDIO_DRV is set.
3574 QB_KERNEL_ROOT: Kernel's root (e.g. /dev/vda)
3575 QB_TAP_OPT: Network option for 'tap' mode (e.g.
3576 "-netdev tap,id=net0,ifname=@TAP@,script=no,downscript=no -device virtio-net-device,netdev=net0").
3577 runqemu will replace "@TAP@" with the one that is used, such as tap0, tap1 ...
3578 QB_SLIRP_OPT: Network option for SLIRP mode (e.g. "-netdev user,id=net0 -device virtio-net-device,netdev=net0")
3579 QB_ROOTFS_OPT: Used as rootfs (e.g.
3580 "-drive id=disk0,file=@ROOTFS@,if=none,format=raw -device virtio-blk-device,drive=disk0").
3581 runqemu will replace "@ROOTFS@" with the one which is used, such as
3582 core-image-minimal-qemuarm64.ext4.
3583 QB_SERIAL_OPT: Serial port (e.g. "-serial mon:stdio")
3584 QB_TCPSERIAL_OPT: tcp serial port option (e.g.
3585 " -device virtio-serial-device -chardev socket,id=virtcon,port=@PORT@,host=127.0.0.1 -device virtconsole,chardev=virtcon"
3586 runqemu will replace "@PORT@" with the port number which is used.
3587 </literallayout>
3588 </para>
3589
3590 <para>
3591 To use <filename>runqemu</filename>, set
3592 <link linkend='var-IMAGE_CLASSES'><filename>IMAGE_CLASSES</filename></link>
3593 as follows and run <filename>runqemu</filename>:
3594 <note>
3595 For command-line syntax, use
3596 <filename>runqemu help</filename>.
3597 </note>
3598 <literallayout class='monospaced'>
3599 IMAGE_CLASSES += "qemuboot"
3600 </literallayout>
3601 </para>
3602 </section>
3603
3604 <section id='migration-2.2-default-linker-hash-style-changed'>
3605 <title>Default Linker Hash Style Changed</title>
3606
3607 <para>
3608 The default linker hash style for <filename>gcc-cross</filename>
3609 is now "sysv" in order to catch recipes that are building software
3610 without using the OpenEmbedded
3611 <link linkend='var-LDFLAGS'><filename>LDFLAGS</filename></link>.
3612 This change could result in seeing some "No GNU_HASH in the elf
3613 binary" QA issues when building such recipes.
3614 You need to fix these recipes so that they use the expected
3615 <filename>LDFLAGS</filename>.
3616 Depending on how the software is built, the build system used by
3617 the software (e.g. a Makefile) might need to be patched.
3618 However, sometimes making this fix is as simple as adding the
3619 following to the recipe:
3620 <literallayout class='monospaced'>
3621 TARGET_CC_ARCH += "${LDFLAGS}"
3622 </literallayout>
3623 </para>
3624 </section>
3625
Brad Bishop37a0e4d2017-12-04 01:01:44 -05003626 <section id='migration-2.2-kernel-image-base-name-no-longer-uses-kernel-imagetype'>
3627 <title><filename>KERNEL_IMAGE_BASE_NAME</filename> no Longer Uses <filename>KERNEL_IMAGETYPE</filename></title>
3628
3629 <para>
3630 The
3631 <link linkend='var-KERNEL_IMAGE_BASE_NAME'><filename>KERNEL_IMAGE_BASE_NAME</filename></link>
3632 variable no longer uses the
3633 <link linkend='var-KERNEL_IMAGETYPE'><filename>KERNEL_IMAGETYPE</filename></link>
3634 variable to create the image's base name.
3635 Because the OpenEmbedded build system can now build multiple kernel
3636 image types, this part of the kernel image base name as been
3637 removed leaving only the following:
3638 <literallayout class='monospaced'>
3639 KERNEL_IMAGE_BASE_NAME ?= "${PKGE}-${PKGV}-${PKGR}-${MACHINE}-${DATETIME}
3640 </literallayout>
3641 If you have recipes or classes that use
3642 <filename>KERNEL_IMAGE_BASE_NAME</filename> directly, you might
3643 need to update the references to ensure they continue to work.
3644 </para>
3645 </section>
3646
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003647 <section id='migration-2.2-bitbake-changes'>
3648 <title>BitBake Changes</title>
3649
3650 <para>
3651 The following changes took place for BitBake:
3652 <itemizedlist>
3653 <listitem><para>
3654 The "goggle" UI and standalone image-writer tool have
3655 been removed as they both require GTK+ 2.0 and
3656 were not being maintained.
3657 </para></listitem>
3658 <listitem><para>
3659 The Perforce fetcher now supports
3660 <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
3661 for specifying the source revision to use, be it
3662 <filename>${</filename><link linkend='var-AUTOREV'><filename>AUTOREV</filename></link><filename>}</filename>,
3663 changelist number, p4date, or label, in preference to
3664 separate
3665 <link linkend='var-SRC_URI'><filename>SRC_URI</filename></link>
3666 parameters to specify these.
3667 This change is more in-line with how the other fetchers
3668 work for source control systems.
3669 Recipes that fetch from Perforce will need to be updated
3670 to use <filename>SRCREV</filename> in place of specifying
3671 the source revision within
3672 <filename>SRC_URI</filename>.
3673 </para></listitem>
3674 <listitem><para>
3675 Some of BitBake's internal code structures for accessing
3676 the recipe cache needed to be changed to support the new
3677 multi-configuration functionality.
3678 These changes will affect external tools that use BitBake's
3679 tinfoil module.
3680 For information on these changes, see the changes made to
3681 the scripts supplied with OpenEmbedded-Core:
3682 <ulink url='http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=189371f8393971d00bca0fceffd67cc07784f6ee'>1</ulink>
3683 and
3684 <ulink url='http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=4a5aa7ea4d07c2c90a1654b174873abb018acc67'>2</ulink>.
3685 </para></listitem>
3686 <listitem><para>
3687 The task management code has been rewritten to avoid using
3688 ID indirection in order to improve performance.
3689 This change is unlikely to cause any problems for most
3690 users.
3691 However, the setscene verification function as pointed to
3692 by <filename>BB_SETSCENE_VERIFY_FUNCTION</filename>
3693 needed to change signature.
3694 Consequently, a new variable named
Brad Bishop6e60e8b2018-02-01 10:27:11 -05003695 <filename>BB_SETSCENE_VERIFY_FUNCTION2</filename>
Patrick Williamsc0f7c042017-02-23 20:41:17 -06003696 has been added allowing multiple versions of BitBake
3697 to work with suitably written metadata, which includes
3698 OpenEmbedded-Core and Poky.
3699 Anyone with custom BitBake task scheduler code might also
3700 need to update the code to handle the new structure.
3701 </para></listitem>
3702 </itemizedlist>
3703 </para>
3704 </section>
3705
3706 <section id='migration-2.2-swabber-has-been-removed'>
3707 <title>Swabber has Been Removed</title>
3708
3709 <para>
3710 Swabber, a tool that was intended to detect host contamination in
3711 the build process, has been removed, as it has been unmaintained
3712 and unused for some time and was never particularly effective.
3713 The OpenEmbedded build system has since incorporated a number of
3714 mechanisms including enhanced QA checks that mean that there is
3715 less of a need for such a tool.
3716 </para>
3717 </section>
3718
3719 <section id='migration-2.2-removed-recipes'>
3720 <title>Removed Recipes</title>
3721
3722 <para>
3723 The following recipes have been removed:
3724 <itemizedlist>
3725 <listitem><para>
3726 <filename>augeas</filename>:
3727 No longer needed and has been moved to
3728 <filename>meta-oe</filename>.
3729 </para></listitem>
3730 <listitem><para>
3731 <filename>directfb</filename>:
3732 Unmaintained and has been moved to
3733 <filename>meta-oe</filename>.
3734 </para></listitem>
3735 <listitem><para>
3736 <filename>gcc</filename>:
3737 Removed 4.9 version.
3738 Versions 5.4 and 6.2 are still present.
3739 </para></listitem>
3740 <listitem><para>
3741 <filename>gnome-doc-utils</filename>:
3742 No longer needed.
3743 </para></listitem>
3744 <listitem><para>
3745 <filename>gtk-doc-stub</filename>:
3746 Replaced by <filename>gtk-doc</filename>.
3747 </para></listitem>
3748 <listitem><para>
3749 <filename>gtk-engines</filename>:
3750 No longer needed and has been moved to
3751 <filename>meta-gnome</filename>.
3752 </para></listitem>
3753 <listitem><para>
3754 <filename>gtk-sato-engine</filename>:
3755 Became obsolete.
3756 </para></listitem>
3757 <listitem><para>
3758 <filename>libglade</filename>:
3759 No longer needed and has been moved to
3760 <filename>meta-oe</filename>.
3761 </para></listitem>
3762 <listitem><para>
3763 <filename>libmad</filename>:
3764 Unmaintained and functionally replaced by
3765 <filename>libmpg123</filename>.
3766 <filename>libmad</filename> has been moved to
3767 <filename>meta-oe</filename>.
3768 </para></listitem>
3769 <listitem><para>
3770 <filename>libowl</filename>:
3771 Became obsolete.
3772 </para></listitem>
3773 <listitem><para>
3774 <filename>libxsettings-client</filename>:
3775 No longer needed.
3776 </para></listitem>
3777 <listitem><para>
3778 <filename>oh-puzzles</filename>:
3779 Functionally replaced by
3780 <filename>puzzles</filename>.
3781 </para></listitem>
3782 <listitem><para>
3783 <filename>oprofileui</filename>:
3784 Became obsolete.
3785 OProfile has been largely supplanted by perf.
3786 </para></listitem>
3787 <listitem><para>
3788 <filename>packagegroup-core-directfb.bb</filename>:
3789 Removed.
3790 </para></listitem>
3791 <listitem><para>
3792 <filename>core-image-directfb.bb</filename>:
3793 Removed.
3794 </para></listitem>
3795 <listitem><para>
3796 <filename>pointercal</filename>:
3797 No longer needed and has been moved to
3798 <filename>meta-oe</filename>.
3799 </para></listitem>
3800 <listitem><para>
3801 <filename>python-imaging</filename>:
3802 No longer needed and moved to
3803 <filename>meta-python</filename>
3804 </para></listitem>
3805 <listitem><para>
3806 <filename>python-pyrex</filename>:
3807 No longer needed and moved to
3808 <filename>meta-python</filename>.
3809 </para></listitem>
3810 <listitem><para>
3811 <filename>sato-icon-theme</filename>:
3812 Became obsolete.
3813 </para></listitem>
3814 <listitem><para>
3815 <filename>swabber-native</filename>:
3816 Swabber has been removed.
3817 See the
3818 <link linkend='migration-2.2-swabber-has-been-removed'>entry on Swabber</link>.
3819 </para></listitem>
3820 <listitem><para>
3821 <filename>tslib</filename>:
3822 No longer needed and has been moved to
3823 <filename>meta-oe</filename>.
3824 </para></listitem>
3825 <listitem><para>
3826 <filename>uclibc</filename>:
3827 Removed in favor of musl.
3828 </para></listitem>
3829 <listitem><para>
3830 <filename>xtscal</filename>:
3831 No longer needed and moved to
3832 <filename>meta-oe</filename>
3833 </para></listitem>
3834 </itemizedlist>
3835 </para>
3836 </section>
3837
3838 <section id='migration-2.2-removed-classes'>
3839 <title>Removed Classes</title>
3840
3841 <para>
3842 The following classes have been removed:
3843 <itemizedlist>
3844 <listitem><para>
3845 <filename>distutils-native-base</filename>:
3846 No longer needed.
3847 </para></listitem>
3848 <listitem><para>
3849 <filename>distutils3-native-base</filename>:
3850 No longer needed.
3851 </para></listitem>
3852 <listitem><para>
3853 <filename>sdl</filename>:
3854 Only set
3855 <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>
3856 and
3857 <link linkend='var-SECTION'><filename>SECTION</filename></link>,
3858 which are better set within the recipe instead.
3859 </para></listitem>
3860 <listitem><para>
3861 <filename>sip</filename>:
3862 Mostly unused.
3863 </para></listitem>
3864 <listitem><para>
3865 <filename>swabber</filename>:
3866 See the
3867 <link linkend='migration-2.2-swabber-has-been-removed'>entry on Swabber</link>.
3868 </para></listitem>
3869 </itemizedlist>
3870 </para>
3871 </section>
3872
3873 <section id='migration-2.2-minor-packaging-changes'>
3874 <title>Minor Packaging Changes</title>
3875
3876 <para>
3877 The following minor packaging changes have occurred:
3878 <itemizedlist>
3879 <listitem><para>
3880 <filename>grub</filename>:
3881 Split <filename>grub-editenv</filename> into its own
3882 package.
3883 </para></listitem>
3884 <listitem><para>
3885 <filename>systemd</filename>:
3886 Split container and vm related units into a new package,
3887 systemd-container.
3888 </para></listitem>
3889 <listitem><para>
3890 <filename>util-linux</filename>:
3891 Moved <filename>prlimit</filename> to a separate
3892 <filename>util-linux-prlimit</filename> package.
3893 </para></listitem>
3894 </itemizedlist>
3895 </para>
3896 </section>
3897
3898 <section id='migration-2.2-miscellaneous-changes'>
3899 <title>Miscellaneous Changes</title>
3900
3901 <para>
3902 The following miscellaneous changes have occurred:
3903 <itemizedlist>
3904 <listitem><para>
3905 <filename>package_regex.inc</filename>:
3906 Removed because the definitions
3907 <filename>package_regex.inc</filename> previously contained
3908 have been moved to their respective recipes.
3909 </para></listitem>
3910 <listitem><para>
3911 Both <filename>devtool add</filename> and
3912 <filename>recipetool create</filename> now use a fixed
3913 <link linkend='var-SRCREV'><filename>SRCREV</filename></link>
3914 by default when fetching from a Git repository.
3915 You can override this in either case to use
3916 <filename>${</filename><link linkend='var-AUTOREV'><filename>AUTOREV</filename></link><filename>}</filename>
3917 instead by using the <filename>-a</filename> or
3918 <filename>&dash;&dash;autorev</filename> command-line
3919 option
3920 </para></listitem>
3921 <listitem><para>
3922 <filename>distcc</filename>:
3923 GTK+ UI is now disabled by default.
3924 </para></listitem>
3925 <listitem><para>
3926 <filename>packagegroup-core-tools-testapps</filename>:
3927 Removed Piglit.
3928 </para></listitem>
3929 <listitem><para>
3930 <filename>image.bbclass</filename>:
3931 Renamed COMPRESS(ION) to CONVERSION.
3932 This change means that
3933 <filename>COMPRESSIONTYPES</filename>,
3934 <filename>COMPRESS_DEPENDS</filename> and
3935 <filename>COMPRESS_CMD</filename> are deprecated in favor
3936 of <filename>CONVERSIONTYPES</filename>,
3937 <filename>CONVERSION_DEPENDS</filename> and
3938 <filename>CONVERSION_CMD</filename>.
3939 The <filename>COMPRESS*</filename> variable names will
3940 still work in the 2.2 release but metadata that does not
3941 need to be backwards-compatible should be changed to
3942 use the new names as the <filename>COMPRESS*</filename>
3943 ones will be removed in a future release.
3944 </para></listitem>
3945 <listitem><para>
3946 <filename>gtk-doc</filename>:
3947 A full version of <filename>gtk-doc</filename> is now
3948 made available.
3949 However, some old software might not be capable of using
3950 the current version of <filename>gtk-doc</filename>
3951 to build documentation.
3952 You need to change recipes that build such software so that
3953 they explicitly disable building documentation with
3954 <filename>gtk-doc</filename>.
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05003955 </para></listitem>
3956 </itemizedlist>
3957 </para>
3958 </section>
3959</section>
Patrick Williamsf1e5d692016-03-30 15:21:19 -05003960
Brad Bishop6e60e8b2018-02-01 10:27:11 -05003961<section id='moving-to-the-yocto-project-2.3-release'>
3962 <title>Moving to the Yocto Project 2.3 Release</title>
3963
3964 <para>
3965 This section provides migration information for moving to the
3966 Yocto Project 2.3 Release from the prior release.
3967 </para>
3968
3969 <section id='migration-2.3-recipe-specific-sysroots'>
3970 <title>Recipe-specific Sysroots</title>
3971
3972 <para>
3973 The OpenEmbedded build system now uses one sysroot per
3974 recipe to resolve long-standing issues with configuration
3975 script auto-detection of undeclared dependencies.
3976 Consequently, you might find that some of your previously
3977 written custom recipes are missing declared dependencies,
3978 particularly those dependencies that are incidentally built
3979 earlier in a typical build process and thus are already likely
3980 to be present in the shared sysroot in previous releases.
3981 </para>
3982
3983 <para>
3984 Consider the following:
3985 <itemizedlist>
3986 <listitem><para>
3987 <emphasis>Declare Build-Time Dependencies:</emphasis>
3988 Because of this new feature, you must explicitly
3989 declare all build-time dependencies for your recipe.
3990 If you do not declare these dependencies, they are not
3991 populated into the sysroot for the recipe.
3992 </para></listitem>
3993 <listitem><para>
3994 <emphasis>Specify Pre-Installation and Post-Installation
3995 Native Tool Dependencies:</emphasis>
3996 You must specifically specify any special native tool
3997 dependencies of <filename>pkg_preinst</filename> and
3998 <filename>pkg_postinst</filename> scripts by using the
3999 <link linkend='var-PACKAGE_WRITE_DEPS'><filename>PACKAGE_WRITE_DEPS</filename></link>
4000 variable.
4001 Specifying these dependencies ensures that these tools
4002 are available if these scripts need to be run on the
4003 build host during the
4004 <link linkend='ref-tasks-rootfs'><filename>do_rootfs</filename></link>
4005 task.</para>
4006
4007 <para>As an example, see the <filename>dbus</filename>
4008 recipe.
4009 You will see that this recipe has a
4010 <filename>pkg_postinst</filename> that calls
4011 <filename>systemctl</filename> if "systemd" is in
4012 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
4013 In the example,
4014 <filename>systemd-systemctl-native</filename> is added to
4015 <filename>PACKAGE_WRITE_DEPS</filename>, which is also
4016 conditional on "systemd" being in
4017 <filename>DISTRO_FEATURES</filename>.
4018 </para></listitem>
4019 <listitem><para>
4020 <emphasis>Examine Recipes that Use
4021 <filename>SSTATEPOSTINSTFUNCS</filename>:</emphasis>
4022 You need to examine any recipe that uses
4023 <filename>SSTATEPOSTINSTFUNCS</filename> and determine
4024 steps to take.</para>
4025
4026 <para>Functions added to
4027 <filename>SSTATEPOSTINSTFUNCS</filename> are still
4028 called as they were in previous Yocto Project releases.
4029 However, since a separate sysroot is now being populated
4030 for every recipe and if existing functions being called
4031 through <filename>SSTATEPOSTINSTFUNCS</filename> are
4032 doing relocation, then you will need to change these
4033 to use a post-installation script that is installed by a
4034 function added to
4035 <link linkend='var-SYSROOT_PREPROCESS_FUNCS'><filename>SYSROOT_PREPROCESS_FUNCS</filename></link>.
4036 </para>
4037
4038 <para>For an example, see the
4039 <filename>pixbufcache</filename> class in
4040 <filename>meta/classes/</filename> in the Yocto Project
Brad Bishopd7bf8c12018-02-25 22:55:05 -05004041 <link linkend='source-repositories'>Source Repositories</link>.
Brad Bishop6e60e8b2018-02-01 10:27:11 -05004042 <note>
4043 The <filename>SSTATEPOSTINSTFUNCS</filename> variable
4044 itself is now deprecated in favor of the
4045 <filename>do_populate_sysroot[postfuncs]</filename>
4046 task.
4047 Consequently, if you do still have any function or
4048 functions that need to be called after the sysroot
4049 component is created for a recipe, then you would be
4050 well advised to take steps to use a post installation
4051 script as described previously.
4052 Taking these steps prepares your code for when
4053 <filename>SSTATEPOSTINSTFUNCS</filename> is
4054 removed in a future Yocto Project release.
4055 </note>
4056 </para></listitem>
4057 <listitem><para>
4058 <emphasis>Specify the Sysroot when Using Certain
4059 External Scripts:</emphasis>
4060 Because the shared sysroot is now gone, the scripts
4061 <filename>oe-find-native-sysroot</filename> and
4062 <filename>oe-run-native</filename> have been changed such
4063 that you need to specify which recipe's
4064 <link linkend='var-STAGING_DIR_NATIVE'><filename>STAGING_DIR_NATIVE</filename></link>
4065 is used.
4066 </para></listitem>
4067 </itemizedlist>
4068 <note>
4069 You can find more information on how recipe-specific sysroots
4070 work in the
4071 "<link linkend='ref-classes-staging'><filename>staging.bbclass</filename></link>"
4072 section.
4073 </note>
4074 </para>
4075 </section>
4076
4077 <section id='migration-2.3-path-variable'>
4078 <title><filename>PATH</filename> Variable</title>
4079
4080 <para>
4081 Within the environment used to run build tasks, the environment
4082 variable <filename>PATH</filename> is now sanitized such that
4083 the normal native binary paths
4084 (<filename>/bin</filename>, <filename>/sbin</filename>,
4085 <filename>/usr/bin</filename> and so forth) are
4086 removed and a directory containing symbolic links linking only
4087 to the binaries from the host mentioned in the
4088 <link linkend='var-HOSTTOOLS'><filename>HOSTTOOLS</filename></link>
4089 and
4090 <link linkend='var-HOSTTOOLS_NONFATAL'><filename>HOSTTOOLS_NONFATAL</filename></link>
4091 variables is added to <filename>PATH</filename>.
4092 </para>
4093
4094 <para>
4095 Consequently, any native binaries provided by the host that you
4096 need to call needs to be in one of these two variables at
4097 the configuration level.
4098 </para>
4099
4100 <para>
4101 Alternatively, you can add a native recipe (i.e.
4102 <filename>-native</filename>) that provides the
4103 binary to the recipe's
4104 <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>
4105 value.
4106 <note>
4107 <filename>PATH</filename> is not sanitized in the same way
4108 within <filename>devshell</filename>.
4109 If it were, you would have difficulty running host tools for
4110 development and debugging within the shell.
4111 </note>
4112 </para>
4113 </section>
4114
4115 <section id='migration-2.3-scripts'>
4116 <title>Changes to Scripts</title>
4117
4118 <para>
4119 The following changes to scripts took place:
4120 <itemizedlist>
4121 <listitem><para>
4122 <emphasis><filename>oe-find-native-sysroot</filename>:</emphasis>
4123 The usage for the
4124 <filename>oe-find-native-sysroot</filename> script has
4125 changed to the following:
4126 <literallayout class='monospaced'>
4127 $ . oe-find-native-sysroot <replaceable>recipe</replaceable>
4128 </literallayout>
4129 You must now supply a recipe for
4130 <replaceable>recipe</replaceable> as part of the command.
4131 Prior to the Yocto Project &DISTRO; release, it was not
4132 necessary to provide the script with the command.
4133 </para></listitem>
4134 <listitem><para>
4135 <emphasis><filename>oe-run-native</filename>:</emphasis>
4136 The usage for the
4137 <filename>oe-run-native</filename> script has changed
4138 to the following:
4139 <literallayout class='monospaced'>
4140 $ oe-run-native <replaceable>native_recipe</replaceable> <replaceable>tool</replaceable>
4141 </literallayout>
4142 You must supply the name of the native recipe and the tool
4143 you want to run as part of the command.
4144 Prior to the Yocto Project &DISTRO; release, it was not
4145 necessary to provide the native recipe with the command.
4146 </para></listitem>
4147 <listitem><para>
4148 <emphasis><filename>cleanup-workdir</filename>:</emphasis>
4149 The <filename>cleanup-workdir</filename> script has been
4150 removed because the script was found to be deleting
4151 files it should not have, which lead to broken build
4152 trees.
4153 Rather than trying to delete portions of
4154 <link linkend='var-TMPDIR'><filename>TMPDIR</filename></link>
4155 and getting it wrong, it is recommended that you
4156 delete <filename>TMPDIR</filename> and have it restored
4157 from shared state (sstate) on subsequent builds.
4158 </para></listitem>
4159 <listitem><para>
4160 <emphasis><filename>wipe-sysroot</filename>:</emphasis>
4161 The <filename>wipe-sysroot</filename> script has been
4162 removed as it is no longer needed with recipe-specific
4163 sysroots.
4164 </para></listitem>
4165 </itemizedlist>
4166 </para>
4167 </section>
4168
4169 <section id='migration-2.3-functions'>
4170 <title>Changes to Functions</title>
4171
4172 <para>
4173 The previously deprecated
4174 <filename>bb.data.getVar()</filename>,
4175 <filename>bb.data.setVar()</filename>, and
4176 related functions have been removed in favor of
4177 <filename>d.getVar()</filename>,
4178 <filename>d.setVar()</filename>, and so forth.
4179 </para>
4180
4181 <para>
4182 You need to fix any references to these old functions.
4183 </para>
4184 </section>
4185
4186 <section id='migration-2.3-bitbake-changes'>
4187 <title>BitBake Changes</title>
4188
4189 <para>
4190 The following changes took place for BitBake:
4191 <itemizedlist>
4192 <listitem><para>
4193 <emphasis>BitBake's Graphical Dependency Explorer UI Replaced:</emphasis>
4194 BitBake's graphical dependency explorer UI
4195 <filename>depexp</filename> was replaced by
4196 <filename>taskexp</filename> ("Task Explorer"), which
4197 provides a graphical way of exploring the
4198 <filename>task-depends.dot</filename> file.
4199 The data presented by Task Explorer is much more
4200 accurate than the data that was presented by
4201 <filename>depexp</filename>.
4202 Being able to visualize the data is an often requested
4203 feature as standard <filename>*.dot</filename> file
4204 viewers cannot usual cope with the size of
4205 the <filename>task-depends.dot</filename> file.
4206 </para></listitem>
4207 <listitem><para>
4208 <emphasis>BitBake "-g" Output Changes:</emphasis>
4209 The <filename>package-depends.dot</filename> and
4210 <filename>pn-depends.dot</filename> files as previously
4211 generated using the <filename>bitbake -g</filename> command
4212 have been removed.
4213 A <filename>recipe-depends.dot</filename> file
4214 is now generated as a collapsed version of
4215 <filename>task-depends.dot</filename> instead.
4216 </para>
4217
4218 <para>The reason for this change is because
4219 <filename>package-depends.dot</filename> and
4220 <filename>pn-depends.dot</filename> largely date back
4221 to a time before task-based execution and do not take
4222 into account task-level dependencies between recipes,
4223 which could be misleading.
4224 </para></listitem>
4225 <listitem><para>
4226 <emphasis>Mirror Variable Splitting Changes:</emphasis>
4227 Mirror variables including
4228 <link linkend='var-MIRRORS'><filename>MIRRORS</filename></link>,
4229 <link linkend='var-PREMIRRORS'><filename>PREMIRRORS</filename></link>,
4230 and
4231 <link linkend='var-SSTATE_MIRRORS'><filename>SSTATE_MIRRORS</filename></link>
4232 can now separate values entirely with spaces.
4233 Consequently, you no longer need "\\n".
4234 BitBake looks for pairs of values, which simplifies usage.
4235 There should be no change required to existing mirror
4236 variable values themselves.
4237 </para></listitem>
4238 <listitem><para>
4239 <emphasis>The Subversion (SVN) Fetcher Uses an "ssh" Parameter and Not an "rsh" Parameter:</emphasis>
4240 The SVN fetcher now takes an "ssh" parameter instead of an
4241 "rsh" parameter.
4242 This new optional parameter is used when the "protocol"
4243 parameter is set to "svn+ssh".
4244 You can only use the new parameter to specify the
4245 <filename>ssh</filename> program used by SVN.
4246 The SVN fetcher passes the new parameter through the
4247 <filename>SVN_SSH</filename> environment variable during
4248 the
4249 <link linkend='ref-tasks-fetch'><filename>do_fetch</filename></link>
4250 task.</para>
4251
4252 <para>See the
4253 "<ulink url='&YOCTO_DOCS_BB_URL;#svn-fetcher'>Subversion (SVN) Fetcher (svn://)</ulink>"
4254 section in the Yocto Project BitBake User Manual for
4255 additional information.
4256 </para></listitem>
4257 <listitem><para>
4258 <emphasis><filename>BB_SETSCENE_VERIFY_FUNCTION</filename>
4259 and <filename>BB_SETSCENE_VERIFY_FUNCTION2</filename>
4260 Removed:</emphasis>
4261 Because the mechanism they were part of is no longer
4262 necessary with recipe-specific sysroots, the
4263 <filename>BB_SETSCENE_VERIFY_FUNCTION</filename> and
4264 <filename>BB_SETSCENE_VERIFY_FUNCTION2</filename>
4265 variables have been removed.
4266 </para></listitem>
4267 </itemizedlist>
4268 </para>
4269 </section>
4270
4271 <section id='migration-2.3-absolute-symlinks'>
4272 <title>Absolute Symbolic Links</title>
4273
4274 <para>
4275 Absolute symbolic links (symlinks) within staged files are no
4276 longer permitted and now trigger an error.
4277 Any explicit creation of symlinks can use the
4278 <filename>lnr</filename> script, which is a replacement for
4279 <filename>ln -r</filename>.
4280 </para>
4281
4282 <para>
4283 If the build scripts in the software that the recipe is building
4284 are creating a number of absolute symlinks that need to be
4285 corrected, you can inherit
4286 <filename>relative_symlinks</filename> within the recipe to turn
4287 those absolute symlinks into relative symlinks.
4288 </para>
4289 </section>
4290
4291 <section id='migration-2.3-gplv2-and-gplv3-moves'>
4292 <title>GPLv2 Versions of GPLv3 Recipes Moved</title>
4293
4294 <para>
4295 Older GPLv2 versions of GPLv3 recipes have moved to a
4296 separate <filename>meta-gplv2</filename> layer.
4297 </para>
4298
4299 <para>
4300 If you use
4301 <link linkend='var-INCOMPATIBLE_LICENSE'><filename>INCOMPATIBLE_LICENSE</filename></link>
4302 to exclude GPLv3 or set
4303 <link linkend='var-PREFERRED_VERSION'><filename>PREFERRED_VERSION</filename></link>
4304 to substitute a GPLv2 version of a GPLv3 recipe, then you must add
4305 the <filename>meta-gplv2</filename> layer to your configuration.
4306 <note>
4307 You can find <filename>meta-gplv2</filename> layer in the
4308 OpenEmbedded layer index at
4309 <ulink url='https://layers.openembedded.org/layerindex/branch/master/layer/meta-gplv2/'></ulink>.
4310 </note>
4311 </para>
4312
4313 <para>
4314 These relocated GPLv2 recipes do not receive the same level of
4315 maintenance as other core recipes.
4316 The recipes do not get security fixes and upstream no longer
4317 maintains them.
4318 In fact, the upstream community is actively hostile towards people
4319 that use the old versions of the recipes.
4320 Moving these recipes into a separate layer both makes the different
4321 needs of the recipes clearer and clearly identifies the number of
4322 these recipes.
4323 <note>
4324 The long-term solution might be to move to BSD-licensed
4325 replacements of the GPLv3 components for those that need to
4326 exclude GPLv3-licensed components from the target system.
4327 This solution will be investigated for future Yocto
4328 Project releases.
4329 </note>
4330 </para>
4331 </section>
4332
4333 <section id='migration-2.3-package-management-changes'>
4334 <title>Package Management Changes</title>
4335
4336 <para>
4337 The following package management changes took place:
4338 <itemizedlist>
4339 <listitem><para>
4340 Smart package manager is replaced by DNF package manager.
4341 Smart has become unmaintained upstream, is not ported
4342 to Python 3.x.
4343 Consequently, Smart needed to be replaced.
4344 DNF is the only feasible candidate.</para>
4345 <para>The change in functionality is that the on-target
4346 runtime package management from remote package feeds is
4347 now done with a different tool that has a
4348 different set of command-line options.
4349 If you have scripts that call the
4350 tool directly, or use its API, they need to be fixed.</para>
4351 <para>For more information, see the
4352 <ulink url='http://dnf.readthedocs.io/en/latest/'>DNF Documentation</ulink>.
4353 </para></listitem>
4354 <listitem><para>
4355 Rpm 5.x is replaced with Rpm 4.x.
4356 This is done for two major reasons:
4357 <itemizedlist>
4358 <listitem><para>
4359 DNF is API-incompatible with Rpm 5.x and porting
4360 it and maintaining the port is non-trivial.
4361 </para></listitem>
4362 <listitem><para>
4363 Rpm 5.x itself has limited maintenance upstream,
4364 and the Yocto Project is one of the very few
4365 remaining users.
4366 </para></listitem>
4367 </itemizedlist>
4368 </para></listitem>
4369 <listitem><para>
4370 Berkeley DB 6.x is removed and Berkeley DB 5.x becomes
4371 the default:
4372 <itemizedlist>
4373 <listitem><para>
4374 Version 6.x of Berkeley DB has largely been
4375 rejected by the open source community due to its
4376 AGPLv3 license.
4377 As a result, most mainstream open source projects
4378 that require DB are still developed and tested with
4379 DB 5.x.
4380 </para></listitem>
4381 <listitem><para>
4382 In OE-core, the only thing that was requiring
4383 DB 6.x was Rpm 5.x.
4384 Thus, no reason exists to continue carrying DB 6.x
4385 in OE-core.
4386 </para></listitem>
4387 </itemizedlist>
4388 </para></listitem>
4389 <listitem><para>
4390 <filename>createrepo</filename> is replaced with
4391 <filename>createrepo_c</filename>.</para>
4392 <para><filename>createrepo_c</filename> is the current
4393 incarnation of the tool that generates remote repository
4394 metadata.
4395 It is written in C as compared to
4396 <filename>createrepo</filename>, which is written in
4397 Python.
4398 <filename>createrepo_c</filename> is faster and is
4399 maintained.
4400 </para></listitem>
4401 <listitem><para>
4402 Architecture-independent RPM packages are "noarch"
4403 instead of "all".</para>
4404 <para>This change was made because too many places in
4405 DNF/RPM4 stack already make that assumption.
4406 Only the filenames and the architecture tag has changed.
4407 Nothing else has changed in OE-core system, particularly
4408 in the
4409 <link linkend='ref-classes-allarch'><filename>allarch.bbclass</filename></link>
4410 class.
4411 </para></listitem>
4412 <listitem><para>
4413 Signing of remote package feeds using
4414 <filename>PACKAGE_FEED_SIGN</filename>
4415 is not currently supported.
4416 This issue will be fully addressed in a future
4417 Yocto Project release.
4418 See <ulink url='https://bugzilla.yoctoproject.org/show_bug.cgi?id=11209'>defect 11209</ulink>
4419 for more information on a solution to package feed
4420 signing with RPM in the Yocto Project 2.3 release.
4421 </para></listitem>
4422 <listitem><para>
4423 OPKG now uses the libsolv backend for resolving package
4424 dependencies by default.
4425 This is vastly superior to OPKG's internal ad-hoc solver
4426 that was previously used.
4427 This change does have a small impact on disk (around
4428 500 KB) and memory footprint.
4429 <note>
4430 For further details on this change, see the
4431 <ulink url='http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?
4432id=f4d4f99cfbc2396e49c1613a7d237b9e57f06f81'>commit message</ulink>.
4433 </note>
4434 </para></listitem>
4435 </itemizedlist>
4436 </para>
4437 </section>
4438
4439 <section id='migration-2.3-removed-recipes'>
4440 <title>Removed Recipes</title>
4441
4442 <para>
4443 The following recipes have been removed:
4444 <itemizedlist>
4445 <listitem><para>
4446 <emphasis><filename>linux-yocto 4.8:</filename></emphasis>
4447 Version 4.8 has been removed.
4448 Versions 4.1 (LTSI), 4.4 (LTS), 4.9 (LTS/LTSI) and 4.10
4449 are now present.
4450 </para></listitem>
4451 <listitem><para>
4452 <emphasis><filename>python-smartpm:</filename></emphasis>
4453 Functionally replaced by <filename>dnf</filename>.
4454 </para></listitem>
4455 <listitem><para>
4456 <emphasis><filename>createrepo:</filename></emphasis>
4457 Replaced by the <filename>createrepo-c</filename> recipe.
4458 </para></listitem>
4459 <listitem><para>
4460 <emphasis><filename>rpmresolve:</filename></emphasis>
4461 No longer needed with the move to RPM 4 as RPM itself is
4462 used instead.
4463 </para></listitem>
4464 <listitem><para>
4465 <emphasis><filename>gstreamer:</filename></emphasis>
4466 Removed the GStreamer Git version recipes as they have
4467 been stale.
4468 <filename>1.10.</filename><replaceable>x</replaceable>
4469 recipes are still present.
4470 </para></listitem>
4471 <listitem><para>
4472 <emphasis><filename>alsa-conf-base:</filename></emphasis>
4473 Merged into <filename>alsa-conf</filename> since
4474 <filename>libasound</filename> depended on both.
4475 Essentially, no way existed to install only one of these.
4476 </para></listitem>
4477 <listitem><para>
4478 <emphasis><filename>tremor:</filename></emphasis>
4479 Moved to <filename>meta-multimedia</filename>.
4480 Fixed-integer Vorbis decoding is not
4481 needed by current hardware.
4482 Thus, GStreamer's ivorbis plugin has been disabled
4483 by default eliminating the need for the
Brad Bishopd7bf8c12018-02-25 22:55:05 -05004484 <filename>tremor</filename> recipe in
4485 <link linkend='oe-core'>OE-Core</link>.
Brad Bishop6e60e8b2018-02-01 10:27:11 -05004486 </para></listitem>
4487 <listitem><para>
4488 <emphasis><filename>gummiboot:</filename></emphasis>
4489 Replaced by <filename>systemd-boot</filename>.
4490 </para></listitem>
4491 </itemizedlist>
4492 </para>
4493 </section>
4494
4495 <section id='migration-2.3-wic-changes'>
4496 <title>Wic Changes</title>
4497
4498 <para>
4499 The following changes have been made to Wic:
4500 <note>
4501 For more information on Wic, see the
Brad Bishopd7bf8c12018-02-25 22:55:05 -05004502 "<ulink url='&YOCTO_DOCS_DEV_URL;#creating-partitioned-images-using-wic'>Creating Partitioned Images Using Wic</ulink>"
4503 section in the Yocto Project Development Tasks Manual.
Brad Bishop6e60e8b2018-02-01 10:27:11 -05004504 </note>
4505 <itemizedlist>
4506 <listitem><para>
4507 <emphasis>Default Output Directory Changed:</emphasis>
4508 Wic's default output directory is now the current directory
4509 by default instead of the unusual
4510 <filename>/var/tmp/wic</filename>.</para>
4511
4512 <para>The "-o" and "--outdir" options remain unchanged
4513 and are used to specify your preferred output directory
4514 if you do not want to use the default directory.
4515 </para></listitem>
4516 <listitem><para>
4517 <emphasis>fsimage Plug-in Removed:</emphasis>
4518 The Wic fsimage plug-in has been removed as it duplicates
4519 functionality of the rawcopy plug-in.
4520 </para></listitem>
4521 </itemizedlist>
4522 </para>
4523 </section>
4524
4525 <section id='migration-2.3-qa-changes'>
4526 <title>QA Changes</title>
4527
4528 <para>
4529 The following QA checks have changed:
4530 <itemizedlist>
4531 <listitem><para>
4532 <emphasis><filename>unsafe-references-in-binaries</filename>:</emphasis>
4533 The <filename>unsafe-references-in-binaries</filename>
4534 QA check, which was disabled by default, has now been
4535 removed.
4536 This check was intended to detect binaries in
4537 <filename>/bin</filename> that link to libraries in
4538 <filename>/usr/lib</filename> and have the case where
4539 the user has <filename>/usr</filename> on a separate
4540 filesystem to <filename>/</filename>.</para>
4541
4542 <para>The removed QA check was buggy.
4543 Additionally, <filename>/usr</filename> residing on a
4544 separate partition from <filename>/</filename> is now
4545 a rare configuration.
4546 Consequently,
4547 <filename>unsafe-references-in-binaries</filename> was
4548 removed.
4549 </para></listitem>
4550 <listitem><para>
4551 <emphasis><filename>file-rdeps</filename>:</emphasis>
4552 The <filename>file-rdeps</filename> QA check is now an
4553 error by default instead of a warning.
4554 Because it is an error instead of a warning, you need to
4555 address missing runtime dependencies.</para>
4556
4557 <para>For additional information, see the
4558 <link linkend='ref-classes-insane'><filename>insane</filename></link>
4559 class and the
4560 "<link linkend='qa-errors-and-warnings'>Errors and Warnings</link>"
4561 section.
4562 </para></listitem>
4563 </itemizedlist>
4564 </para>
4565 </section>
4566
4567 <section id='migration-2.3-miscellaneous-changes'>
4568 <title>Miscellaneous Changes</title>
4569
4570 <para>
4571 The following miscellaneous changes have occurred:
4572 <itemizedlist>
4573 <listitem><para>
4574 In this release, a number of recipes have been changed to
4575 ignore the <filename>largefile</filename>
4576 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
4577 item, enabling large file support unconditionally.
4578 This feature has always been enabled by default.
4579 Disabling the feature has not been widely tested.
4580 <note>
4581 Future releases of the Yocto Project will remove
4582 entirely the ability to disable the
4583 <filename>largefile</filename> feature,
4584 which would make it unconditionally enabled everywhere.
4585 </note>
4586 </para></listitem>
4587 <listitem><para>
4588 If the
4589 <link linkend='var-DISTRO_VERSION'><filename>DISTRO_VERSION</filename></link>
4590 value contains the value of the
4591 <link linkend='var-DATE'><filename>DATE</filename></link>
4592 variable, which is the default between Poky releases,
4593 the <filename>DATE</filename> value is explicitly excluded
4594 from <filename>/etc/issue</filename> and
4595 <filename>/etc/issue.net</filename>, which is displayed at
4596 the login prompt, in order to avoid conflicts with
4597 Multilib enabled.
4598 Regardless, the <filename>DATE</filename> value is
4599 inaccurate if the <filename>base-files</filename>
4600 recipe is restored from shared state (sstate) rather
4601 than rebuilt.</para>
4602
4603 <para>If you need the build date recorded in
4604 <filename>/etc/issue*</filename> or anywhere else in your
4605 image, a better method is to define a post-processing
4606 function to do it and have the function called from
4607 <link linkend='var-ROOTFS_POSTPROCESS_COMMAND'><filename>ROOTFS_POSTPROCESS_COMMAND</filename></link>.
4608 Doing so ensures the value is always up-to-date with the
4609 created image.
4610 </para></listitem>
4611 <listitem><para>
4612 Dropbear's <filename>init</filename> script now disables
4613 DSA host keys by default.
4614 This change is in line with the systemd service
4615 file, which supports RSA keys only, and with recent
4616 versions of OpenSSH, which deprecates DSA host keys.
4617 </para></listitem>
4618 <listitem><para>
4619 The
4620 <link linkend='ref-classes-buildhistory'><filename>buildhistory</filename></link>
4621 class now correctly uses tabs as separators between all
4622 columns in <filename>installed-package-sizes.txt</filename>
4623 in order to aid import into other tools.
4624 </para></listitem>
4625 <listitem><para>
4626 The <filename>USE_LDCONFIG</filename> variable has been
4627 replaced with the "ldconfig"
4628 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
4629 feature.
4630 Distributions that previously set:
4631 <literallayout class='monospaced'>
4632 USE_LDCONFIG = "0"
4633 </literallayout>
4634 should now instead use the following:
4635 <literallayout class='monospaced'>
4636 DISTRO_FEATURES_BACKFILL_CONSIDERED_append = " ldconfig"
4637 </literallayout>
4638 </para></listitem>
4639 <listitem><para>
4640 The default value of
4641 <link linkend='var-COPYLEFT_LICENSE_INCLUDE'><filename>COPYLEFT_LICENSE_INCLUDE</filename></link>
4642 now includes all versions of AGPL licenses in addition
4643 to GPL and LGPL.
4644 <note>
4645 The default list is not intended to be guaranteed
4646 as a complete safe list.
4647 You should seek legal advice based on what you are
4648 distributing if you are unsure.
4649 </note>
4650 </para></listitem>
4651 <listitem><para>
4652 Kernel module packages are now suffixed with the kernel
4653 version in order to allow module packages from multiple
4654 kernel versions to co-exist on a target system.
4655 If you wish to return to the previous naming scheme
4656 that does not include the version suffix, use the
4657 following:
4658 <literallayout class='monospaced'>
4659 KERNEL_MODULE_PACKAGE_SUFFIX to ""
4660 </literallayout>
4661 </para></listitem>
4662 <listitem><para>
4663 Removal of <filename>libtool</filename>
4664 <filename>*.la</filename> files is now enabled by default.
4665 The <filename>*.la</filename> files are not actually
4666 needed on Linux and relocating them is an unnecessary
4667 burden.</para>
4668
4669 <para>If you need to preserve these
4670 <filename>.la</filename> files (e.g. in a custom
4671 distribution), you must change
4672 <link linkend='var-INHERIT_DISTRO'><filename>INHERIT_DISTRO</filename></link>
4673 such that "remove-libtool" is not included in the value.
4674 </para></listitem>
4675 <listitem><para>
4676 Extensible SDKs built for GCC 5+ now refuse to install on a
4677 distribution where the host GCC version is 4.8 or 4.9.
4678 This change resulted from the fact that the installation
4679 is known to fail due to the way the
4680 <filename>uninative</filename> shared state (sstate)
4681 package is built.
4682 See the
4683 <link linkend='ref-classes-uninative'><filename>uninative</filename></link>
4684 class for additional information.
4685 </para></listitem>
4686 <listitem><para>
4687 All native and nativesdk recipes now use a separate
4688 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
4689 value instead of sharing the value used by recipes for the
4690 target, in order to avoid unnecessary rebuilds.</para>
4691
4692 <para>The <filename>DISTRO_FEATURES</filename> for
4693 <filename>native</filename> recipes is
4694 <link linkend='var-DISTRO_FEATURES_NATIVE'><filename>DISTRO_FEATURES_NATIVE</filename></link>
4695 added to an intersection of
4696 <filename>DISTRO_FEATURES</filename> and
4697 <link linkend='var-DISTRO_FEATURES_FILTER_NATIVE'><filename>DISTRO_FEATURES_FILTER_NATIVE</filename></link>.
4698 </para>
4699
4700 <para>For nativesdk recipes, the
4701 corresponding variables are
4702 <link linkend='var-DISTRO_FEATURES_NATIVESDK'><filename>DISTRO_FEATURES_NATIVESDK</filename></link>
4703 and
4704 <link linkend='var-DISTRO_FEATURES_FILTER_NATIVESDK'><filename>DISTRO_FEATURES_FILTER_NATIVESDK</filename></link>.
4705 </para></listitem>
4706 <listitem><para>
4707 The <filename>FILESDIR</filename>
4708 variable, which was previously deprecated and rarely used,
4709 has now been removed.
4710 You should change any recipes that set
4711 <filename>FILESDIR</filename> to set
4712 <link linkend='var-FILESPATH'><filename>FILESPATH</filename></link>
4713 instead.
4714 </para></listitem>
4715 <listitem><para>
4716 The <filename>MULTIMACH_HOST_SYS</filename>
4717 variable has been removed as it is no longer needed
4718 with recipe-specific sysroots.
4719 </para></listitem>
4720 </itemizedlist>
4721 </para>
4722 </section>
4723</section>
Brad Bishopd7bf8c12018-02-25 22:55:05 -05004724
4725<section id='moving-to-the-yocto-project-2.4-release'>
4726 <title>Moving to the Yocto Project 2.4 Release</title>
4727
4728 <para>
4729 This section provides migration information for moving to the
4730 Yocto Project 2.4 Release from the prior release.
4731 </para>
4732
4733 <section id='migration-2.4-memory-resident-mode'>
4734 <title>Memory Resident Mode</title>
4735
4736 <para>
4737 A persistent mode is now available in BitBake's default operation,
4738 replacing its previous "memory resident mode" (i.e.
4739 <filename>oe-init-build-env-memres</filename>).
4740 Now you only need to set
4741 <filename>BB_SERVER_TIMEOUT</filename> to a timeout
4742 (in seconds) and BitBake's server stays resident for that
4743 amount of time between invocations.
4744 The <filename>oe-init-build-env-memres</filename> script has been
4745 removed since a separate environment setup script is no longer
4746 needed.
4747 </para>
4748 </section>
4749
4750 <section id='migration-2.4-packaging-changes'>
4751 <title>Packaging Changes</title>
4752
4753 <para>
4754 This section provides information about packaging changes that have
4755 ocurred:
4756 <itemizedlist>
4757 <listitem><para>
4758 <emphasis><filename>python3</filename> Changes:</emphasis>
4759 <itemizedlist>
4760 <listitem><para>
4761 The main "python3" package now brings in all of the
4762 standard Python 3 distribution rather than a subset.
4763 This behavior matches what is expected based on
4764 traditional Linux distributions.
4765 If you wish to install a subset of Python 3, specify
4766 <filename>python-core</filename> plus one or more of
4767 the individual packages that are still produced.
4768 </para></listitem>
4769 <listitem><para>
4770 <emphasis><filename>python3</filename>:</emphasis>
4771 The <filename>bz2.py</filename>,
4772 <filename>lzma.py</filename>, and
4773 <filename>_compression.py</filename> scripts have
4774 been moved from the
4775 <filename>python3-misc</filename> package to
4776 the <filename>python3-compression</filename> package.
4777 </para></listitem>
4778 </itemizedlist>
4779 </para></listitem>
4780 <listitem><para>
4781 <emphasis><filename>binutils</filename>:</emphasis>
4782 The <filename>libbfd</filename> library is now packaged in
4783 a separate "libbfd" package.
4784 This packaging saves space when certain tools
4785 (e.g. <filename>perf</filename>) are installed.
4786 In such cases, the tools only need
4787 <filename>libbfd</filename> rather than all the packages in
4788 <filename>binutils</filename>.
4789 </para></listitem>
4790 <listitem><para>
4791 <emphasis><filename>util-linux</filename> Changes:</emphasis>
4792 <itemizedlist>
4793 <listitem><para>
4794 The <filename>su</filename> program is now packaged
4795 in a separate "util-linux-su" package, which is only
4796 built when "pam" is listed in the
4797 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>
4798 variable.
4799 <filename>util-linux</filename> should not be
4800 installed unless it is needed because
4801 <filename>su</filename> is normally provided through
4802 the shadow file format.
4803 The main <filename>util-linux</filename> package has
4804 runtime dependencies (i.e.
4805 <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>)
4806 on the <filename>util-linux-su</filename> package
4807 when "pam" is in
4808 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
4809 </para></listitem>
4810 <listitem><para>
4811 The <filename>switch_root</filename> program is now
4812 packaged in a separate "util-linux-switch-root"
4813 package for small initramfs images that do not need
4814 the whole <filename>util-linux</filename> package or
4815 the busybox binary, which are both much larger than
4816 <filename>switch_root</filename>.
4817 The main <filename>util-linux</filename> package has
4818 a recommended runtime dependency (i.e.
4819 <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
4820 on the <filename>util-linux-switch-root</filename> package.
4821 </para></listitem>
4822 <listitem><para>
4823 The <filename>ionice</filename> program is now
4824 packaged in a separate "util-linux-ionice" package.
4825 The main <filename>util-linux</filename> package has
4826 a recommended runtime dependency (i.e.
4827 <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
4828 on the <filename>util-linux-ionice</filename> package.
4829 </para></listitem>
4830 </itemizedlist>
4831 </para></listitem>
4832 <listitem><para>
4833 <emphasis><filename>initscripts</filename>:</emphasis>
4834 The <filename>sushell</filename> program is now packaged in
4835 a separate "initscripts-sushell" package.
4836 This packaging change allows systems to pull
4837 <filename>sushell</filename> in when
4838 <filename>selinux</filename> is enabled.
4839 The change also eliminates needing to pull in the entire
4840 <filename>initscripts</filename> package.
4841 The main <filename>initscripts</filename> package has a
4842 runtime dependency (i.e.
4843 <link linkend='var-RDEPENDS'><filename>RDEPENDS</filename></link>)
4844 on the <filename>sushell</filename> package when
4845 "selinux" is in
4846 <link linkend='var-DISTRO_FEATURES'><filename>DISTRO_FEATURES</filename></link>.
4847 </para></listitem>
4848 <listitem><para>
4849 <emphasis><filename>glib-2.0</filename>:</emphasis>
4850 The <filename>glib-2.0</filename> package now has a
4851 recommended runtime dependency (i.e.
4852 <link linkend='var-RRECOMMENDS'><filename>RRECOMMENDS</filename></link>)
4853 on the
4854 <filename>shared-mime-info</filename> package, since large
4855 portions of GIO are not useful without the MIME database.
4856 You can remove the dependency by using the
4857 <link linkend='var-BAD_RECOMMENDATIONS'><filename>BAD_RECOMMENDATIONS</filename></link>
4858 variable if <filename>shared-mime-info</filename> is too
4859 large and is not required.
4860 </para></listitem>
4861 <listitem><para>
4862 <emphasis>Go Standard Runtime:</emphasis>
4863 The Go standard runtime has been split out from the main
4864 <filename>go</filename> recipe into a separate
4865 <filename>go-runtime</filename> recipe.
4866 </para></listitem>
4867 </itemizedlist>
4868 </para>
4869 </section>
4870
4871 <section id='migration-2.4-removed-recipes'>
4872 <title>Removed Recipes</title>
4873
4874 <para>
4875 The following recipes have been removed:
4876 <itemizedlist>
4877 <listitem><para>
4878 <emphasis><filename>acpitests</filename>:</emphasis>
4879 This recipe is not maintained.
4880 </para></listitem>
4881 <listitem><para>
4882 <emphasis><filename>autogen-native</filename>:</emphasis>
4883 No longer required by Grub, oe-core, or meta-oe.
4884 </para></listitem>
4885 <listitem><para>
4886 <emphasis><filename>bdwgc</filename>:</emphasis>
4887 Nothing in OpenEmbedded-Core requires this recipe.
4888 It has moved to meta-oe.
4889 </para></listitem>
4890 <listitem><para>
4891 <emphasis><filename>byacc</filename>:</emphasis>
4892 This recipe was only needed by rpm 5.x and has moved to
4893 meta-oe.
4894 </para></listitem>
4895 <listitem><para>
4896 <emphasis><filename>gcc (5.4)</filename>:</emphasis>
4897 The 5.4 series dropped the recipe in favor of 6.3 / 7.2.
4898 </para></listitem>
4899 <listitem><para>
4900 <emphasis><filename>gnome-common</filename>:</emphasis>
4901 Deprecated upstream and no longer needed.
4902 </para></listitem>
4903 <listitem><para>
4904 <emphasis><filename>go-bootstrap-native</filename>:</emphasis>
4905 Go 1.9 does its own bootstrapping so this recipe has been
4906 removed.
4907 </para></listitem>
4908 <listitem><para>
4909 <emphasis><filename>guile</filename>:</emphasis>
4910 This recipe was only needed by
4911 <filename>autogen-native</filename> and
4912 <filename>remake</filename>.
4913 The recipe is no longer needed by either of these programs.
4914 </para></listitem>
4915 <listitem><para>
4916 <emphasis><filename>libclass-isa-perl</filename>:</emphasis>
4917 This recipe was previously needed for LSB 4, no longer
4918 needed.
4919 </para></listitem>
4920 <listitem><para>
4921 <emphasis><filename>libdumpvalue-perl</filename>:</emphasis>
4922 This recipe was previously needed for LSB 4, no longer
4923 needed.
4924 </para></listitem>
4925 <listitem><para>
4926 <emphasis><filename>libenv-perl</filename>:</emphasis>
4927 This recipe was previously needed for LSB 4, no longer
4928 needed.
4929 </para></listitem>
4930 <listitem><para>
4931 <emphasis><filename>libfile-checktree-perl</filename>:</emphasis>
4932 This recipe was previously needed for LSB 4, no longer
4933 needed.
4934 </para></listitem>
4935 <listitem><para>
4936 <emphasis><filename>libi18n-collate-perl</filename>:</emphasis>
4937 This recipe was previously needed for LSB 4, no longer
4938 needed.
4939 </para></listitem>
4940 <listitem><para>
4941 <emphasis><filename>libiconv</filename>:</emphasis>
4942 This recipe was only needed for <filename>uclibc</filename>,
4943 which was removed in the previous release.
4944 <filename>glibc</filename> and <filename>musl</filename>
4945 have their own implementations.
4946 <filename>meta-mingw</filename> still needs
4947 <filename>libiconv</filename>, so it has
4948 been moved to <filename>meta-mingw</filename>.
4949 </para></listitem>
4950 <listitem><para>
4951 <emphasis><filename>libpng12</filename>:</emphasis>
4952 This recipe was previously needed for LSB. The current
4953 <filename>libpng</filename> is 1.6.x.
4954 </para></listitem>
4955 <listitem><para>
4956 <emphasis><filename>libpod-plainer-perl</filename>:</emphasis>
4957 This recipe was previously needed for LSB 4, no longer
4958 needed.
4959 </para></listitem>
4960 <listitem><para>
4961 <emphasis><filename>linux-yocto (4.1)</filename>:</emphasis>
4962 This recipe was removed in favor of 4.4, 4.9, 4.10 and 4.12.
4963 </para></listitem>
4964 <listitem><para>
4965 <emphasis><filename>mailx</filename>:</emphasis>
4966 This recipe was previously only needed for LSB
4967 compatibility, and upstream is defunct.
4968 </para></listitem>
4969 <listitem><para>
4970 <emphasis><filename>mesa (git version only)</filename>:</emphasis>
4971 The git version recipe was stale with respect to the release
4972 version.
4973 </para></listitem>
4974 <listitem><para>
4975 <emphasis><filename>ofono (git version only)</filename>:</emphasis>
4976 The git version recipe was stale with respect to the release
4977 version.
4978 </para></listitem>
4979 <listitem><para>
4980 <emphasis><filename>portmap</filename>:</emphasis>
4981 This recipe is obsolete and is superseded by
4982 <filename>rpcbind</filename>.
4983 </para></listitem>
4984 <listitem><para>
4985 <emphasis><filename>python3-pygpgme</filename>:</emphasis>
4986 This recipe is old and unmaintained. It was previously
4987 required by <filename>dnf</filename>, which has switched
4988 to official <filename>gpgme</filename> Python bindings.
4989 </para></listitem>
4990 <listitem><para>
4991 <emphasis><filename>python-async</filename>:</emphasis>
4992 This recipe has been removed in favor of the Python 3
4993 version.
4994 </para></listitem>
4995 <listitem><para>
4996 <emphasis><filename>python-gitdb</filename>:</emphasis>
4997 This recipe has been removed in favor of the Python 3
4998 version.
4999 </para></listitem>
5000 <listitem><para>
5001 <emphasis><filename>python-git</filename>:</emphasis>
5002 This recipe was removed in favor of the Python 3
5003 version.
5004 </para></listitem>
5005 <listitem><para>
5006 <emphasis><filename>python-mako</filename>:</emphasis>
5007 This recipe was removed in favor of the Python 3
5008 version.
5009 </para></listitem>
5010 <listitem><para>
5011 <emphasis><filename>python-pexpect</filename>:</emphasis>
5012 This recipe was removed in favor of the Python 3 version.
5013 </para></listitem>
5014 <listitem><para>
5015 <emphasis><filename>python-ptyprocess</filename>:</emphasis>
5016 This recipe was removed in favor of Python the 3 version.
5017 </para></listitem>
5018 <listitem><para>
5019 <emphasis><filename>python-pycurl</filename>:</emphasis>
5020 Nothing is using this recipe in OpenEmbedded-Core
5021 (i.e. <filename>meta-oe</filename>).
5022 </para></listitem>
5023 <listitem><para>
5024 <emphasis><filename>python-six</filename>:</emphasis>
5025 This recipe was removed in favor of the Python 3 version.
5026 </para></listitem>
5027 <listitem><para>
5028 <emphasis><filename>python-smmap</filename>:</emphasis>
5029 This recipe was removed in favor of the Python 3 version.
5030 </para></listitem>
5031 <listitem><para>
5032 <emphasis><filename>remake</filename>:</emphasis>
5033 Using <filename>remake</filename> as the provider of
5034 <filename>virtual/make</filename> is broken.
5035 Consequently, this recipe is not needed in OpenEmbedded-Core.
5036 </para></listitem>
5037 </itemizedlist>
5038 </para>
5039 </section>
5040
5041 <section id='migration-2.4-kernel-device-tree-move'>
5042 <title>Kernel Device Tree Move</title>
5043
5044 <para>
5045 Kernel Device Tree support is now easier to enable in a kernel
5046 recipe.
5047 The Device Tree code has moved to a
5048 <filename>kernel-devicetree</filename> class.
5049 Functionality is automatically enabled for any recipe that inherits
5050 the
5051 <link linkend='ref-classes-kernel'><filename>kernel</filename></link>
5052 class and sets the
5053 <link linkend='var-KERNEL_DEVICETREE'><filename>KERNEL_DEVICETREE</filename></link>
5054 variable.
5055 The previous mechanism for doing this,
5056 <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>,
5057 is still available to avoid breakage, but triggers a
5058 deprecation warning.
5059 Future releases of the Yocto Project will remove
5060 <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>.
5061 It is advisable to remove any <filename>require</filename>
5062 statements that request
5063 <filename>meta/recipes-kernel/linux/linux-dtb.inc</filename>
5064 from any custom kernel recipes you might have.
5065 This will avoid breakage in post 2.4 releases.
5066 </para>
5067 </section>
5068
5069 <section id='migration-2.4-package-qa-changes'>
5070 <title>Package QA Changes</title>
5071
5072 <para>
5073 The following package QA changes took place:
5074 <itemizedlist>
5075 <listitem><para>
5076 The "unsafe-references-in-scripts" QA check has been
5077 removed.
5078 </para></listitem>
5079 <listitem><para>
5080 If you refer to <filename>${COREBASE}/LICENSE</filename>
5081 within
5082 <link linkend='var-LIC_FILES_CHKSUM'><filename>LIC_FILES_CHKSUM</filename></link>
5083 you receive a warning because this file is a description of
5084 the license for OE-Core.
5085 Use <filename>${COMMON_LICENSE_DIR}/MIT</filename>
5086 if your recipe is MIT-licensed and you cannot use the
5087 preferred method of referring to a file within the source
5088 tree.
5089 </para></listitem>
5090 </itemizedlist>
5091 </para>
5092 </section>
5093
5094 <section id='migration-2.4-readme-changes'>
5095 <title><filename>README</filename> File Changes</title>
5096
5097 <para>
5098 The following are changes to <filename>README</filename> files:
5099 <itemizedlist>
5100 <listitem><para>
5101 The main Poky <filename>README</filename> file has been
5102 moved to the <filename>meta-poky</filename> layer and
5103 has been renamed <filename>README.poky</filename>.
5104 A symlink has been created so that references to the old
5105 location work.
5106 </para></listitem>
5107 <listitem><para>
5108 The <filename>README.hardware</filename> file has been moved
5109 to <filename>meta-yocto-bsp</filename>.
5110 A symlink has been created so that references to the old
5111 location work.
5112 </para></listitem>
5113 <listitem><para>
5114 A <filename>README.qemu</filename> file has been created
5115 with coverage of the <filename>qemu*</filename> machines.
5116 </para></listitem>
5117 </itemizedlist>
5118 </para>
5119 </section>
5120
5121 <section id='migration-2.4-miscellaneous-changes'>
5122 <title>Miscellaneous Changes</title>
5123
5124 <para>
5125 The following are additional changes:
5126 <itemizedlist>
5127 <listitem><para>
5128 The <filename>ROOTFS_PKGMANAGE_BOOTSTRAP</filename>
5129 variable and any references to it have been removed.
5130 You should remove this variable from any custom recipes.
5131 </para></listitem>
5132 <listitem><para>
5133 The <filename>meta-yocto</filename> directory has been
5134 removed.
5135 <note>
5136 In the Yocto Project 2.1 release
5137 <filename>meta-yocto</filename> was renamed to
5138 <filename>meta-poky</filename> and the
5139 <filename>meta-yocto</filename> subdirectory remained
5140 to avoid breaking existing configurations.
5141 </note>
5142 </para></listitem>
5143 <listitem><para>
5144 The <filename>maintainers.inc</filename> file, which tracks
5145 maintainers by listing a primary person responsible for each
5146 recipe in OE-Core, has been moved from
5147 <filename>meta-poky</filename> to OE-Core (i.e. from
5148 <filename>meta-poky/conf/distro/include</filename> to
5149 <filename>meta/conf/distro/include</filename>).
5150 </para></listitem>
5151 <listitem><para>
5152 The
5153 <link linkend='ref-classes-buildhistory'><filename>buildhistory</filename></link>
5154 class now makes a single commit per build rather than one
5155 commit per subdirectory in the repository.
5156 This behavior assumes the commits are enabled with
5157 <link linkend='var-BUILDHISTORY_COMMIT'><filename>BUILDHISTORY_COMMIT</filename></link>
5158 = "1", which is typical.
5159 Previously, the <filename>buildhistory</filename> class made
5160 one commit per subdirectory in the repository in order to
5161 make it easier to see the changes for a particular
5162 subdirectory.
5163 To view a particular change, specify that subdirectory as
5164 the last parameter on the <filename>git show</filename>
5165 or <filename>git diff</filename> commands.
5166 </para></listitem>
5167 <listitem><para>
5168 The <filename>x86-base.inc</filename> file, which is
5169 included by all x86-based machine configurations, now sets
5170 <link linkend='var-IMAGE_FSTYPES'><filename>IMAGE_FSTYPES</filename></link>
5171 using <filename>?=</filename> to "live" rather than
5172 appending with <filename>+=</filename>.
5173 This change makes the default easier to override.
5174 </para></listitem>
5175 <listitem><para>
5176 BitBake fires multiple "BuildStarted" events when
5177 multiconfig is enabled (one per configuration).
5178 For more information, see the
5179 "<ulink url='&YOCTO_DOCS_BB_URL;#events'>Events</ulink>"
5180 in the BitBake User Manual.
5181 </para></listitem>
5182 <listitem><para>
5183 By default, the <filename>security_flags.inc</filename> file
5184 sets a <filename>GCCPIE</filename> variable with an option
5185 to enable Position Independent Executables (PIE) within
5186 <filename>gcc</filename>.
5187 Enabling PIE in the GNU C Compiler (GCC), makes Return
5188 Oriented Programming (ROP) attacks much more difficult to
5189 execute.
5190 </para></listitem>
5191 <listitem><para>
5192 OE-Core now provides a
5193 <filename>bitbake-layers</filename> plugin that implements
5194 a "create-layer" subcommand.
5195 The implementation of this subcommand has resulted in the
5196 <filename>yocto-layer</filename> script being deprecated and
5197 will likely be removed in the next Yocto Project release.
5198 </para></listitem>
5199 <listitem><para>
5200 The <filename>vmdk</filename>, <filename>vdi</filename>,
5201 and <filename>qcow2</filename> image file types are now
5202 used in conjunction with the "wic" image type through
5203 <filename>CONVERSION_CMD</filename>.
5204 Consequently, the equivalent image types are now
5205 <filename>wic.vmdk</filename>, <filename>wic.vdi</filename>,
5206 and <filename>wic.qcow2</filename>, respectively.
5207 </para></listitem>
5208 <listitem><para>
5209 <filename>do_image_&lt;type&gt;[depends]</filename> has
5210 replaced <filename>IMAGE_DEPENDS_&lt;type&gt;</filename>.
5211 If you have your own classes that implement custom image
5212 types, then you need to update them.
5213 </para></listitem>
5214 <listitem><para>
5215 OpenSSL 1.1 has been introduced.
5216 However, the default is still 1.0.x through the
5217 <link linkend='var-PREFERRED_VERSION'><filename>PREFERRED_VERSION</filename></link>
5218 variable.
5219 This preference is set is due to the remaining compatibility
5220 issues with other software.
5221 The
5222 <link linkend='var-PROVIDES'><filename>PROVIDES</filename></link>
5223 variable in the openssl 1.0 recipe now includes "openssl10"
5224 as a marker that can be used in
5225 <link linkend='var-DEPENDS'><filename>DEPENDS</filename></link>
5226 within recipes that build software that still depend on
5227 OpenSSL 1.0.
5228 </para></listitem>
5229 <listitem><para>
5230 To ensure consistent behavior, BitBake's "-r" and "-R"
5231 options (i.e. prefile and postfile), which are used to
5232 read or post-read additional configuration files from the
5233 command line, now only affect the current BitBake command.
5234 Before these BitBake changes, these options would "stick"
5235 for future executions.
5236 </para></listitem>
5237 </itemizedlist>
5238 </para>
5239 </section>
5240</section>
Patrick Williamsc124f4f2015-09-15 14:41:29 -05005241</chapter>
5242<!--
5243vim: expandtab tw=80 ts=4
5244-->