blob: 86721b9873d0b50d1f4b76889060957a5be6657e [file] [log] [blame]
Andrew Geissler517393d2023-01-13 08:55:19 -06001.. SPDX-License-Identifier: CC-BY-SA-2.0-UK
2
Patrick Williams975a06f2022-10-21 14:42:47 -05003Release 4.1 (langdale)
4======================
5
6Migration notes for 4.1 (langdale)
7-----------------------------------
8
9This section provides migration information for moving to the Yocto
10Project 4.1 Release (codename "langdale") from the prior release.
11
12
13.. _migration-4.1-make-4.0:
14
15make 4.0 is now the minimum required make version
16~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
17
18glibc now requires ``make`` 4.0 to build, thus it is now the version required to
Andrew Geissler517393d2023-01-13 08:55:19 -060019be installed on the build host. A new :term:`buildtools-make` tarball has been
Patrick Williams975a06f2022-10-21 14:42:47 -050020introduced to provide just make 4.0 for host distros without a current/working
21make 4.x version; if you also need other tools you can use the updated
Andrew Geissler517393d2023-01-13 08:55:19 -060022:term:`buildtools` tarball. For more information see
Patrick Williams975a06f2022-10-21 14:42:47 -050023:ref:`ref-manual/system-requirements:required packages for the build host`.
24
25
26.. _migration-4.1-complementary-deps:
27
28Complementary package installation ignores recommends
29~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
30
31When installing complementary packages (e.g. ``-dev`` and ``-dbg`` packages when
32building an SDK, or if you have added ``dev-deps`` to :term:`IMAGE_FEATURES`),
33recommends (as defined by :term:`RRECOMMENDS`) are no longer installed.
34
35If you wish to double-check the contents of your images after this change, see
36:ref:`Checking Image / SDK Changes <migration-general-buildhistory>`. If needed
37you can explicitly install items by adding them to :term:`IMAGE_INSTALL` in
38image recipes or :term:`TOOLCHAIN_TARGET_TASK` for the SDK.
39
40
41.. _migration-4.1-dev-recommends:
42
43dev dependencies are now recommends
44~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
45
46The default for ``${PN}-dev`` package is now to use :term:`RRECOMMENDS` instead
47of :term:`RDEPENDS` to pull in the main package. This takes advantage of a
48change to complimentary package installation to not follow :term:`RRECOMMENDS`
49(as mentioned above) and for example means an SDK for an image with both openssh
50and dropbear components will now build successfully.
51
52
53.. _migration-4.1-dropbear-sftp:
54
55dropbear now recommends openssh-sftp-server
56~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
57
58openssh has switched the scp client to use the sftp protocol instead of scp to
59move files. This means scp from Fedora 36 and other current distributions will
60no longer be able to move files to/from a system running dropbear with no sftp
61server installed.
62
63The sftp server from openssh is small (200kb uncompressed) and standalone, so
64adding it to the packagegroup seems to be the best way to preserve the
65functionality for user sanity. However, if you wish to avoid this dependency,
66you can either:
67
68 A. Use ``dropbear`` in :term:`IMAGE_INSTALL` instead of
69 ``packagegroup-core-ssh-dropbear`` (or ``ssh-server-dropbear`` in
70 :term:`IMAGE_FEATURES`), or
71 B. Add ``openssh-sftp-server`` to :term:`BAD_RECOMMENDATIONS`.
72
73
74.. _migration-4.1-classes-split:
75
76Classes now split by usage context
77~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
78
79A split directory structure has now been set up for ``.bbclass`` files - classes
80that are intended to be inherited only by recipes (e.g. ``inherit`` in a recipe
81file, :term:`IMAGE_CLASSES` or :term:`KERNEL_CLASSES`) should be in a
82``classes-recipe`` subdirectory and classes that are intended to be inherited
83globally (e.g. via ``INHERIT +=``, :term:`PACKAGE_CLASSES`, :term:`USER_CLASSES`
84or :term:`INHERIT_DISTRO`) should be in ``classes-global``. Classes in the
85existing ``classes`` subdirectory will continue to work in any context as before.
86
87Other than knowing where to look when manually browsing the class files, this is
88not likely to require any changes to your configuration. However, if in your
89configuration you were using some classes in the incorrect context, you will now
90receive an error during parsing. For example, the following in ``local.conf`` will
91now cause an error::
92
93 INHERIT += "testimage"
94
Andrew Geissler517393d2023-01-13 08:55:19 -060095Since :ref:`ref-classes-testimage` is a class intended solely to
Patrick Williams975a06f2022-10-21 14:42:47 -050096affect image recipes, this would be correctly specified as::
97
98 IMAGE_CLASSES += "testimage"
99
100
101.. _migration-4.1-local-file-error:
102
103Missing local files in SRC_URI now triggers an error
104~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
105
106If a file referenced in :term:`SRC_URI` does not exist, in 4.1 this will trigger
107an error at parse time where previously this only triggered a warning. In the past
108you could ignore these warnings for example if you have multiple build
109configurations (e.g. for several different target machines) and there were recipes
110that you were not building in one of the configurations. If you have this scenario
111you will now need to conditionally add entries to :term:`SRC_URI` where they are
112valid, or use :term:`COMPATIBLE_MACHINE` / :term:`COMPATIBLE_HOST` to prevent the
113recipe from being available (and therefore avoid it being parsed) in configurations
114where the files aren't available.
115
116
117.. _migration-4.1-qa-checks:
118
119QA check changes
120~~~~~~~~~~~~~~~~
121
122- The :ref:`buildpaths <qa-check-buildpaths>` QA check is now enabled by default
123 in :term:`WARN_QA`, and thus any build system paths found in output files will
124 trigger a warning. If you see these warnings for your own recipes, for full
125 binary reproducibility you should make the necessary changes to the recipe build
126 to remove these paths. If you wish to disable the warning for a particular
127 recipe you can use :term:`INSANE_SKIP`, or for the entire build you can adjust
128 :term:`WARN_QA`. For more information, see the :ref:`buildpaths QA check
129 <qa-check-buildpaths>` section.
130
131- ``do_qa_staging`` now checks shebang length in all directories specified by
132 :term:`SYSROOT_DIRS`, since there is a maximum length defined in the kernel. For
133 native recipes which write scripts to the sysroot, if the shebang line in one of
134 these scripts is too long you will get an error. This can be skipped using
135 :term:`INSANE_SKIP` if necessary, but the best course of action is of course to
136 fix the script. There is now also a ``create_cmdline_shebang_wrapper`` function
137 that you can call e.g. from ``do_install`` (or ``do_install:append``) within a
138 recipe to create a wrapper to fix such scripts - see the ``libcheck`` recipe
139 for an example usage.
140
141
142
143Miscellaneous changes
144~~~~~~~~~~~~~~~~~~~~~
145
146- ``mount.blacklist`` has been renamed to ``mount.ignorelist`` in
147 ``udev-extraconf``. If you are customising this file via ``udev-extraconf`` then
148 you will need to update your ``udev-extraconf`` ``.bbappend`` as appropriate.
149- ``help2man-native`` has been removed from implicit sysroot dependencies. If a
150 recipe needs ``help2man-native`` it should now be explicitly added to
151 :term:`DEPENDS` within the recipe.
152- For images using systemd, the reboot watchdog timeout has been set to 60
153 seconds (from the upstream default of 10 minutes). If you wish to override this
154 you can set :term:`WATCHDOG_TIMEOUT` to the desired timeout in seconds. Note
155 that the same :term:`WATCHDOG_TIMEOUT` variable also specifies the timeout used
156 for the ``watchdog`` tool (if that is being built).
Andrew Geissler517393d2023-01-13 08:55:19 -0600157- The :ref:`ref-classes-image-buildinfo` class now writes to
Patrick Williams975a06f2022-10-21 14:42:47 -0500158 ``${sysconfdir}/buildinfo`` instead of ``${sysconfdir}/build`` by default (i.e.
159 the default value of :term:`IMAGE_BUILDINFO_FILE` has been changed). If you have
160 code that reads this from images at build or runtime you will need to update it
161 or specify your own value for :term:`IMAGE_BUILDINFO_FILE`.
Andrew Geissler517393d2023-01-13 08:55:19 -0600162- In the :ref:`ref-classes-archiver` class, the default
Patrick Williams975a06f2022-10-21 14:42:47 -0500163 ``ARCHIVER_OUTDIR`` value no longer includes the :term:`MACHINE` value in order
164 to avoid the archive task running multiple times in a multiconfig setup. If you
165 have custom code that does something with the files archived by the
Andrew Geissler517393d2023-01-13 08:55:19 -0600166 :ref:`ref-classes-archiver` class then you may need to adjust it to
Patrick Williams975a06f2022-10-21 14:42:47 -0500167 the new structure.
168- If you are not using `systemd` then udev is now configured to use labels
169 (``LABEL`` or ``PARTLABEL``) to set the mount point for the device. For example::
170
171 /run/media/rootfs-sda2
172
173 instead of::
174
175 /run/media/sda2
176
177- ``icu`` no longer provides the ``icu-config`` configuration tool - upstream
178 have indicated ``icu-config`` is deprecated and should no longer be used. Code
179 with references to it will need to be updated, for example to use ``pkg-config``
180 instead.
181- The ``rng-tools`` systemd service name has changed from ``rngd`` to ``rng-tools``
182- The ``largefile`` :term:`DISTRO_FEATURES` item has been removed, large file
183 support is now always enabled where it was previously optional.
184- The Python ``zoneinfo`` module is now split out to its own ``python3-zoneinfo``
185 package.
186- The :term:`PACKAGECONFIG` option to enable wpa_supplicant in the ``connman``
Andrew Geissler517393d2023-01-13 08:55:19 -0600187 recipe has been renamed to "wpa-supplicant". If you have set :term:`PACKAGECONFIG` for
Patrick Williams975a06f2022-10-21 14:42:47 -0500188 the ``connman`` recipe to include this option you will need to update
189 your configuration. Related to this, the :term:`WIRELESS_DAEMON` variable
190 now expects the new ``wpa-supplicant`` naming and affects ``packagegroup-base``
191 as well as ``connman``.
192- The ``wpa-supplicant`` recipe no longer uses a static (and stale) ``defconfig``
193 file, instead it uses the upstream version with appropriate edits for the
194 :term:`PACKAGECONFIG`. If you are customising this file you will need to
195 update your customisations.
196- With the introduction of picobuild in
Andrew Geissler517393d2023-01-13 08:55:19 -0600197 :ref:`ref-classes-python_pep517`, The ``PEP517_BUILD_API``
Patrick Williams975a06f2022-10-21 14:42:47 -0500198 variable is no longer supported. If you have any references to this variable
199 you should remove them.
200
201
202.. _migration-4.1-removed-recipes:
203
204Removed recipes
205~~~~~~~~~~~~~~~
206
207The following recipes have been removed in this release:
208
209- ``alsa-utils-scripts``: merged into alsa-utils
210- ``cargo-cross-canadian``: optimised out
211- ``lzop``: obsolete, unmaintained upstream
212- ``linux-yocto (5.10)``: 5.15 and 5.19 are currently provided
213- ``rust-cross``: optimised out
214- ``rust-crosssdk``: optimised out
215- ``rust-tools-cross-canadian``: optimised out
216- ``xf86-input-keyboard``: obsolete (replaced by libinput/evdev)