summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbitbake/bin/bitbake2
-rwxr-xr-xbitbake/bin/bitbake-getvar5
-rw-r--r--bitbake/lib/bb/__init__.py2
-rw-r--r--bitbake/lib/bb/event.py10
-rw-r--r--bitbake/lib/bb/parse/ast.py25
-rw-r--r--bitbake/lib/bb/parse/parse_py/BBHandler.py10
-rw-r--r--documentation/ref-manual/index.rst1
-rw-r--r--documentation/ref-manual/yocto-project-supported-features.rst263
-rw-r--r--meta-selftest/recipes-test/images/wic-image-minimal.wks2
-rw-r--r--meta-selftest/wic/overlayfs_etc.wks.in2
-rw-r--r--meta-selftest/wic/test_biosplusefi_plugin.wks2
-rw-r--r--meta-selftest/wic/test_efi_plugin.wks2
-rw-r--r--meta-selftest/wic/test_efi_plugin_plain_systemd-boot.wks2
-rw-r--r--meta-selftest/wic/test_rawcopy_plugin.wks.in2
-rw-r--r--meta-selftest/wic/test_uefikernel.wks2
-rw-r--r--meta-yocto-bsp/wic/beaglebone-yocto.wks2
-rw-r--r--meta-yocto-bsp/wic/genericarm64.wks.in2
-rw-r--r--meta-yocto-bsp/wic/genericx86.wks.in2
-rw-r--r--meta/classes-global/base.bbclass26
-rw-r--r--meta/classes-global/insane.bbclass2
-rw-r--r--meta/classes-recipe/crosssdk.bbclass1
-rw-r--r--meta/classes/toaster.bbclass2
-rw-r--r--meta/classes/toolchain/clang.bbclass (renamed from meta/conf/toolchain/clang.inc)21
-rw-r--r--meta/classes/toolchain/gcc-native.bbclass (renamed from meta/conf/toolchain/build-gcc.inc)0
-rw-r--r--meta/classes/toolchain/gcc.bbclass33
-rw-r--r--meta/conf/bitbake.conf13
-rw-r--r--meta/conf/distro/include/default-distrovars.inc1
-rw-r--r--meta/conf/sanity.conf2
-rw-r--r--meta/conf/toolchain/gcc.inc27
-rw-r--r--meta/files/license-hashes.csv78
-rw-r--r--meta/lib/oe/bootfiles.py2
-rw-r--r--meta/lib/oe/license_finder.py179
-rw-r--r--meta/lib/oe/package.py3
-rw-r--r--meta/lib/oe/packagedata.py3
-rw-r--r--meta/lib/oe/path.py3
-rw-r--r--meta/lib/oe/sstatesig.py2
-rw-r--r--meta/lib/oe/utils.py5
-rw-r--r--meta/lib/oeqa/selftest/cases/fitimage.py8
-rw-r--r--meta/lib/oeqa/selftest/cases/wic.py10
-rw-r--r--meta/recipes-core/libxml/libxml2/CVE-2025-6021.patch59
-rw-r--r--meta/recipes-core/libxml/libxml2_2.14.3.bb1
-rw-r--r--meta/recipes-core/ovmf/ovmf/CVE-2024-38797-1.patch43
-rw-r--r--meta/recipes-core/ovmf/ovmf/CVE-2024-38797-2.patch63
-rw-r--r--meta/recipes-core/ovmf/ovmf/CVE-2024-38797-3.patch99
-rw-r--r--meta/recipes-core/ovmf/ovmf/CVE-2024-38797-4.patch97
-rw-r--r--meta/recipes-core/ovmf/ovmf_git.bb4
-rw-r--r--meta/recipes-core/packagegroups/packagegroup-base.bb2
-rw-r--r--meta/recipes-core/systemd/systemd-boot-native_257.6.bb (renamed from meta/recipes-core/systemd/systemd-boot-native_257.5.bb)0
-rw-r--r--meta/recipes-core/systemd/systemd-boot_257.6.bb (renamed from meta/recipes-core/systemd/systemd-boot_257.5.bb)0
-rw-r--r--meta/recipes-core/systemd/systemd-systemctl-native_257.6.bb (renamed from meta/recipes-core/systemd/systemd-systemctl-native_257.5.bb)0
-rw-r--r--meta/recipes-core/systemd/systemd.inc2
-rw-r--r--meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch2
-rw-r--r--meta/recipes-core/systemd/systemd/0012-do-not-disable-buffer-in-writing-files.patch14
-rw-r--r--meta/recipes-core/systemd/systemd/0014-Handle-missing-gshadow.patch4
-rw-r--r--meta/recipes-core/systemd/systemd/0019-errno-util-Make-STRERROR-portable-for-musl.patch7
-rw-r--r--meta/recipes-core/systemd/systemd_257.6.bb (renamed from meta/recipes-core/systemd/systemd_257.5.bb)0
-rw-r--r--meta/recipes-devtools/binutils/binutils-cross.inc2
-rw-r--r--meta/recipes-devtools/clang/clang-cross_git.bb1
-rw-r--r--meta/recipes-devtools/clang/clang-crosssdk_git.bb1
-rw-r--r--meta/recipes-devtools/meson/meson_1.8.2.bb (renamed from meta/recipes-devtools/meson/meson_1.8.1.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-cython_3.1.2.bb (renamed from meta/recipes-devtools/python/python3-cython_3.1.1.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-dtschema_2025.6.1.bb (renamed from meta/recipes-devtools/python/python3-dtschema_2025.2.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-hypothesis_6.135.9.bb (renamed from meta/recipes-devtools/python/python3-hypothesis_6.132.0.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-numpy_2.3.0.bb (renamed from meta/recipes-devtools/python/python3-numpy_2.2.6.bb)4
-rw-r--r--meta/recipes-devtools/python/python3-pdm_2.25.1.bb (renamed from meta/recipes-devtools/python/python3-pdm_2.24.2.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-requests_2.32.4.bb (renamed from meta/recipes-devtools/python/python3-requests_2.32.3.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-ruamel-yaml_0.18.14.bb (renamed from meta/recipes-devtools/python/python3-ruamel-yaml_0.18.12.bb)2
-rw-r--r--meta/recipes-devtools/python/python3-typing-extensions_4.14.0.bb (renamed from meta/recipes-devtools/python/python3-typing-extensions_4.13.2.bb)2
-rw-r--r--meta/recipes-devtools/repo/repo_2.55.2.bb (renamed from meta/recipes-devtools/repo/repo_2.55.bb)2
-rw-r--r--meta/recipes-extended/libsolv/libsolv_0.7.33.bb (renamed from meta/recipes-extended/libsolv/libsolv_0.7.32.bb)2
-rw-r--r--meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-01.patch91
-rw-r--r--meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-02.patch31
-rw-r--r--meta/recipes-extended/net-tools/net-tools_2.10.bb2
-rw-r--r--meta/recipes-gnome/gtk+/gtk4_4.18.6.bb (renamed from meta/recipes-gnome/gtk+/gtk4_4.18.5.bb)2
-rw-r--r--meta/recipes-graphics/drm/libdrm_2.4.125.bb (renamed from meta/recipes-graphics/drm/libdrm_2.4.124.bb)2
-rw-r--r--meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.1.bb (renamed from meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.0.bb)2
-rw-r--r--meta/recipes-graphics/libsdl2/libsdl2_2.32.8.bb (renamed from meta/recipes-graphics/libsdl2/libsdl2_2.32.6.bb)2
-rw-r--r--meta/recipes-graphics/mesa/mesa.inc13
-rw-r--r--meta/recipes-graphics/wayland/wayland-protocols_1.45.bb (renamed from meta/recipes-graphics/wayland/wayland-protocols_1.44.bb)2
-rw-r--r--meta/recipes-graphics/wayland/weston_14.0.2.bb (renamed from meta/recipes-graphics/wayland/weston_14.0.1.bb)4
-rw-r--r--meta/recipes-graphics/xorg-lib/pixman_0.46.2.bb (renamed from meta/recipes-graphics/xorg-lib/pixman_0.46.0.bb)2
-rw-r--r--meta/recipes-kernel/lttng/lttng-modules_2.13.19.bb (renamed from meta/recipes-kernel/lttng/lttng-modules_2.13.18.bb)2
-rw-r--r--meta/recipes-multimedia/libtheora/libtheora_1.2.0.bb5
-rw-r--r--meta/recipes-multimedia/mpg123/mpg123_1.33.0.bb (renamed from meta/recipes-multimedia/mpg123/mpg123_1.32.10.bb)2
-rw-r--r--meta/recipes-support/debianutils/debianutils_5.23.1.bb (renamed from meta/recipes-support/debianutils/debianutils_5.22.bb)2
-rw-r--r--meta/recipes-support/diffoscope/diffoscope_298.bb (renamed from meta/recipes-support/diffoscope/diffoscope_297.bb)2
-rw-r--r--meta/recipes-support/hwdata/hwdata_0.396.bb (renamed from meta/recipes-support/hwdata/hwdata_0.395.bb)2
-rw-r--r--meta/recipes-support/libcheck/libcheck_0.15.2.bb8
-rw-r--r--meta/recipes-support/libffi/libffi/not-win32.patch6
-rw-r--r--meta/recipes-support/libffi/libffi_3.5.1.bb (renamed from meta/recipes-support/libffi/libffi_3.4.8.bb)4
-rwxr-xr-xscripts/install-buildtools4
-rw-r--r--scripts/lib/devtool/ide_plugins/ide_code.py1
-rw-r--r--scripts/lib/recipetool/create.py225
-rw-r--r--scripts/lib/recipetool/create_npm.py3
-rw-r--r--scripts/lib/recipetool/licenses.csv37
-rw-r--r--scripts/lib/wic/canned-wks/common.wks.inc2
-rw-r--r--scripts/lib/wic/canned-wks/directdisk-gpt.wks2
-rw-r--r--scripts/lib/wic/canned-wks/directdisk-multi-rootfs.wks2
-rw-r--r--scripts/lib/wic/canned-wks/efi-uki-bootdisk.wks.in2
-rw-r--r--scripts/lib/wic/canned-wks/mkefidisk.wks2
-rw-r--r--scripts/lib/wic/canned-wks/mkhybridiso.wks2
-rw-r--r--scripts/lib/wic/canned-wks/sdimage-bootpart.wks2
-rw-r--r--scripts/lib/wic/canned-wks/systemd-bootdisk.wks2
-rw-r--r--scripts/lib/wic/engine.py2
-rw-r--r--scripts/lib/wic/help.py10
-rw-r--r--scripts/lib/wic/partition.py5
-rw-r--r--scripts/lib/wic/pluginbase.py2
-rw-r--r--scripts/lib/wic/plugins/imager/direct.py2
-rw-r--r--scripts/lib/wic/plugins/source/bootimg_biosplusefi.py (renamed from scripts/lib/wic/plugins/source/bootimg-biosplusefi.py)30
-rw-r--r--scripts/lib/wic/plugins/source/bootimg_efi.py (renamed from scripts/lib/wic/plugins/source/bootimg-efi.py)12
-rw-r--r--scripts/lib/wic/plugins/source/bootimg_partition.py (renamed from scripts/lib/wic/plugins/source/bootimg-partition.py)4
-rw-r--r--scripts/lib/wic/plugins/source/bootimg_pcbios.py (renamed from scripts/lib/wic/plugins/source/bootimg-pcbios.py)4
-rw-r--r--scripts/lib/wic/plugins/source/isoimage_isohybrid.py (renamed from scripts/lib/wic/plugins/source/isoimage-isohybrid.py)10
113 files changed, 1287 insertions, 450 deletions
diff --git a/bitbake/bin/bitbake b/bitbake/bin/bitbake
index 09cbb54e8c..c2d0ca7613 100755
--- a/bitbake/bin/bitbake
+++ b/bitbake/bin/bitbake
@@ -27,7 +27,7 @@ from bb.main import bitbake_main, BitBakeConfigParameters, BBMainException
27 27
28bb.utils.check_system_locale() 28bb.utils.check_system_locale()
29 29
30__version__ = "2.12.0" 30__version__ = "2.15.0"
31 31
32if __name__ == "__main__": 32if __name__ == "__main__":
33 if __version__ != bb.__version__: 33 if __version__ != bb.__version__:
diff --git a/bitbake/bin/bitbake-getvar b/bitbake/bin/bitbake-getvar
index 1719824d95..378fb13572 100755
--- a/bitbake/bin/bitbake-getvar
+++ b/bitbake/bin/bitbake-getvar
@@ -10,6 +10,7 @@ import io
10import os 10import os
11import sys 11import sys
12import warnings 12import warnings
13import logging
13warnings.simplefilter("default") 14warnings.simplefilter("default")
14 15
15bindir = os.path.dirname(__file__) 16bindir = os.path.dirname(__file__)
@@ -38,6 +39,10 @@ if __name__ == "__main__":
38 sys.exit("--flag only makes sense with --value") 39 sys.exit("--flag only makes sense with --value")
39 40
40 quiet = args.quiet or args.value 41 quiet = args.quiet or args.value
42 if quiet:
43 logger = logging.getLogger("BitBake")
44 logger.setLevel(logging.WARNING)
45
41 with bb.tinfoil.Tinfoil(tracking=True, setup_logging=not quiet) as tinfoil: 46 with bb.tinfoil.Tinfoil(tracking=True, setup_logging=not quiet) as tinfoil:
42 if args.recipe: 47 if args.recipe:
43 tinfoil.prepare(quiet=3 if quiet else 2) 48 tinfoil.prepare(quiet=3 if quiet else 2)
diff --git a/bitbake/lib/bb/__init__.py b/bitbake/lib/bb/__init__.py
index c95c91a4cb..62ceaaef6e 100644
--- a/bitbake/lib/bb/__init__.py
+++ b/bitbake/lib/bb/__init__.py
@@ -9,7 +9,7 @@
9# SPDX-License-Identifier: GPL-2.0-only 9# SPDX-License-Identifier: GPL-2.0-only
10# 10#
11 11
12__version__ = "2.12.0" 12__version__ = "2.15.0"
13 13
14import sys 14import sys
15if sys.version_info < (3, 9, 0): 15if sys.version_info < (3, 9, 0):
diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py
index a12adbc937..b29f0a5568 100644
--- a/bitbake/lib/bb/event.py
+++ b/bitbake/lib/bb/event.py
@@ -431,6 +431,16 @@ class RecipeEvent(Event):
431 self.fn = fn 431 self.fn = fn
432 Event.__init__(self) 432 Event.__init__(self)
433 433
434class RecipePreDeferredInherits(RecipeEvent):
435 """
436 Called before deferred inherits are processed so code can snoop on class extensions for example
437 Limitations: It won't see inherits of inherited classes and the data is unexpanded
438 """
439 def __init__(self, fn, inherits):
440 self.fn = fn
441 self.inherits = inherits
442 Event.__init__(self)
443
434class RecipePreFinalise(RecipeEvent): 444class RecipePreFinalise(RecipeEvent):
435 """ Recipe Parsing Complete but not yet finalised""" 445 """ Recipe Parsing Complete but not yet finalised"""
436 446
diff --git a/bitbake/lib/bb/parse/ast.py b/bitbake/lib/bb/parse/ast.py
index 290ed45048..ea1096f2de 100644
--- a/bitbake/lib/bb/parse/ast.py
+++ b/bitbake/lib/bb/parse/ast.py
@@ -340,9 +340,7 @@ class InheritDeferredNode(AstNode):
340 self.inherit = (classes, filename, lineno) 340 self.inherit = (classes, filename, lineno)
341 341
342 def eval(self, data): 342 def eval(self, data):
343 inherits = data.getVar('__BBDEFINHERITS', False) or [] 343 bb.parse.BBHandler.inherit_defer(*self.inherit, data)
344 inherits.append(self.inherit)
345 data.setVar('__BBDEFINHERITS', inherits)
346 344
347class AddFragmentsNode(AstNode): 345class AddFragmentsNode(AstNode):
348 def __init__(self, filename, lineno, fragments_path_prefix, fragments_variable, flagged_variables_list_variable): 346 def __init__(self, filename, lineno, fragments_path_prefix, fragments_variable, flagged_variables_list_variable):
@@ -471,6 +469,17 @@ def finalize(fn, d, variant = None):
471 if d.getVar("_FAILPARSINGERRORHANDLED", False) == True: 469 if d.getVar("_FAILPARSINGERRORHANDLED", False) == True:
472 raise bb.BBHandledException() 470 raise bb.BBHandledException()
473 471
472 inherits = [x[0] for x in (d.getVar('__BBDEFINHERITS', False) or [('',)])]
473 bb.event.fire(bb.event.RecipePreDeferredInherits(fn, inherits), d)
474
475 while True:
476 inherits = d.getVar('__BBDEFINHERITS', False) or []
477 if not inherits:
478 break
479 inherit, filename, lineno = inherits.pop(0)
480 d.setVar('__BBDEFINHERITS', inherits)
481 bb.parse.BBHandler.inherit(inherit, filename, lineno, d, deferred=True)
482
474 for var in d.getVar('__BBHANDLERS', False) or []: 483 for var in d.getVar('__BBHANDLERS', False) or []:
475 # try to add the handler 484 # try to add the handler
476 handlerfn = d.getVarFlag(var, "filename", False) 485 handlerfn = d.getVarFlag(var, "filename", False)
@@ -525,14 +534,6 @@ def multi_finalize(fn, d):
525 logger.debug("Appending .bbappend file %s to %s", append, fn) 534 logger.debug("Appending .bbappend file %s to %s", append, fn)
526 bb.parse.BBHandler.handle(append, d, True) 535 bb.parse.BBHandler.handle(append, d, True)
527 536
528 while True:
529 inherits = d.getVar('__BBDEFINHERITS', False) or []
530 if not inherits:
531 break
532 inherit, filename, lineno = inherits.pop(0)
533 d.setVar('__BBDEFINHERITS', inherits)
534 bb.parse.BBHandler.inherit(inherit, filename, lineno, d, deferred=True)
535
536 onlyfinalise = d.getVar("__ONLYFINALISE", False) 537 onlyfinalise = d.getVar("__ONLYFINALISE", False)
537 538
538 safe_d = d 539 safe_d = d
@@ -568,7 +569,7 @@ def multi_finalize(fn, d):
568 d.setVar("BBEXTENDVARIANT", variantmap[name]) 569 d.setVar("BBEXTENDVARIANT", variantmap[name])
569 else: 570 else:
570 d.setVar("PN", "%s-%s" % (pn, name)) 571 d.setVar("PN", "%s-%s" % (pn, name))
571 bb.parse.BBHandler.inherit(extendedmap[name], fn, 0, d) 572 bb.parse.BBHandler.inherit_defer(extendedmap[name], fn, 0, d)
572 573
573 safe_d.setVar("BBCLASSEXTEND", extended) 574 safe_d.setVar("BBCLASSEXTEND", extended)
574 _create_variants(datastores, extendedmap.keys(), extendfunc, onlyfinalise) 575 _create_variants(datastores, extendedmap.keys(), extendfunc, onlyfinalise)
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py
index 4bdb11994f..008fec2308 100644
--- a/bitbake/lib/bb/parse/parse_py/BBHandler.py
+++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py
@@ -42,12 +42,22 @@ def supports(fn, d):
42 """Return True if fn has a supported extension""" 42 """Return True if fn has a supported extension"""
43 return os.path.splitext(fn)[-1] in [".bb", ".bbclass", ".inc"] 43 return os.path.splitext(fn)[-1] in [".bb", ".bbclass", ".inc"]
44 44
45def inherit_defer(expression, fn, lineno, d):
46 inherit = (expression, fn, lineno)
47 inherits = d.getVar('__BBDEFINHERITS', False) or []
48 inherits.append(inherit)
49 d.setVar('__BBDEFINHERITS', inherits)
50
45def inherit(files, fn, lineno, d, deferred=False): 51def inherit(files, fn, lineno, d, deferred=False):
46 __inherit_cache = d.getVar('__inherit_cache', False) or [] 52 __inherit_cache = d.getVar('__inherit_cache', False) or []
47 #if "${" in files and not deferred: 53 #if "${" in files and not deferred:
48 # bb.warn("%s:%s has non deferred conditional inherit" % (fn, lineno)) 54 # bb.warn("%s:%s has non deferred conditional inherit" % (fn, lineno))
49 files = d.expand(files).split() 55 files = d.expand(files).split()
50 for file in files: 56 for file in files:
57 defer = (d.getVar("BB_DEFER_BBCLASSES") or "").split()
58 if not deferred and file in defer:
59 inherit_defer(file, fn, lineno, d)
60 continue
51 classtype = d.getVar("__bbclasstype", False) 61 classtype = d.getVar("__bbclasstype", False)
52 origfile = file 62 origfile = file
53 for t in ["classes-" + classtype, "classes"]: 63 for t in ["classes-" + classtype, "classes"]:
diff --git a/documentation/ref-manual/index.rst b/documentation/ref-manual/index.rst
index a746dde492..53fa98cc99 100644
--- a/documentation/ref-manual/index.rst
+++ b/documentation/ref-manual/index.rst
@@ -11,6 +11,7 @@ Yocto Project Reference Manual
11 :numbered: 11 :numbered:
12 12
13 system-requirements 13 system-requirements
14 yocto-project-supported-features
14 terms 15 terms
15 release-process 16 release-process
16 structure 17 structure
diff --git a/documentation/ref-manual/yocto-project-supported-features.rst b/documentation/ref-manual/yocto-project-supported-features.rst
new file mode 100644
index 0000000000..bc1a813938
--- /dev/null
+++ b/documentation/ref-manual/yocto-project-supported-features.rst
@@ -0,0 +1,263 @@
1.. SPDX-License-Identifier: CC-BY-SA-2.0-UK
2
3**************************************************
4Yocto Project Supported Architectures And Features
5**************************************************
6
7The Yocto Project is putting continuous efforts into testing the changes made to
8the :term:`OpenEmbedded-Core (OE-Core)` metadata and core tools. The details on
9how this test environment functions is described in the
10:doc:`/test-manual/index`.
11
12These tests are also run for stable and :term:`LTS` versions of the Yocto
13Project. See the :doc:`/ref-manual/release-process` section of the Yocto Project
14Reference Manual for more information on these types of releases.
15
16The infrastructure behind the test environment is the
17:ref:`Yocto Project Autobuilder <test-manual/intro:Yocto Project Autobuilder
18Overview>`. The Autobuilder contains a set of Builders that are associated to an
19architecture or a feature to test. For example, the ``qemuarm64`` builder
20corresponds to testing the ARM 64-bit architecture.
21
22Below is a comprehensive list of target architectures and features that are
23supported, as well as their level of support. For each architecture or feature,
24their corresponding builders are also listed.
25
26Primary Supported
27=================
28
29The term "primary" means that dedicated builds for these architectures or
30features are being run on a daily basis on the Yocto Project Autobuilder and
31also tested with incoming changes before they merge. These changes are usually
32on the "-next" Git branches of the :term:`OpenEmbedded-Core (OE-Core)`
33repositories.
34
35Below is a list of primary tested features, their maintainer(s) and builder(s):
36
37.. list-table::
38 :widths: 20 20 20 40
39 :header-rows: 1
40
41 * - Feature
42 - Description
43 - Maintainer(s)
44 - Builder(s)
45 * - :wikipedia:`ARM <ARM_architecture_family>`
46 - ARM architecture testing
47 - Collective effort
48 - genericarm64,
49 genericarm64-alt,
50 musl-qemuarm64,
51 qemuarm,
52 qemuarm-alt,
53 qemuarm-oecore,
54 qemuarm-tc,
55 qemuarm64,
56 qemuarm64-alt,
57 qemuarm64-armhost,
58 qemuarm64-ltp,
59 qemuarm64-ptest,
60 qemuarm64-tc,
61 qemuarmv5
62 * - :yocto_git:`Beaglebone </poky/tree/meta-yocto-bsp/conf/machine/beaglebone-yocto.conf>`
63 - Beaglebone image and SDK build testing
64 - Collective effort
65 - beaglebone,
66 beaglebone-alt
67 * - :doc:`Reproducible </test-manual/reproducible-builds>`
68 - reproducibility testing
69 - Collective effort
70 - reproducible
71 * - :term:`Buildtools`
72 - Buildtools generation
73 - Collective effort
74 - buildtools
75 * - `meta-agl-core <https://gerrit.automotivelinux.org/gerrit/AGL/meta-agl>`__
76 - meta-agl-core layer testing
77 - TBD
78 - meta-agl-core
79 * - `meta-arm <https://git.yoctoproject.org/meta-arm>`__
80 - meta-arm layer testing
81 - TBD
82 - meta-arm
83 * - `meta-aws <https://github.com/aws4embeddedlinux/meta-aws>`__
84 - meta-aws layer testing
85 - TBD
86 - meta-aws
87 * - `meta-intel <https://git.yoctoproject.org/meta-intel>`__
88 - meta-intel layer testing
89 - TBD
90 - meta-intel
91 * - `meta-virtualization <https://git.yoctoproject.org/meta-virtualization/>`__
92 - meta-virtualization layer testing
93 - TBD
94 - meta-virt
95 * - :ref:`Multilib <dev-manual/libraries:Combining Multiple Versions of Library Files into One Image>`
96 - Multilib feature testing
97 - Collective effort
98 - multilib
99 * - :term:`OpenEmbedded-Core selftest<OpenEmbedded-Core (OE-Core)>`
100 - OpenEmbedded-Core layers selftests
101 - Collective effort
102 - oe-selftest-fedora,
103 oe-selftest-debian,
104 oe-selftest-armhost
105 * - Package managers
106 - Package managers (RPM, DEB and IPK formats) testing in the
107 :term:`OpenEmbedded Build System` (different from the
108 ``package-management`` :term:`image feature <IMAGE_FEATURES>`)
109 - Collective effort
110 - pkgman-non-rpm (other builders use RPM by default)
111 * - :ref:`Patchtest <contributor-guide/submit-changes:Validating Patches with Patchtest>`
112 - Patchtest tool selftests
113 - TBD
114 - patchtest-selftest
115 * - :wikipedia:`RISC-V (64-bit) <RISC-V>`
116 - RISC-V architecture testing (64-bit)
117 - Collective effort
118 - qemuriscv64,
119 qemuriscv64-ptest,
120 qemuriscv64-tc
121 * - :wikipedia:`systemd <Systemd>`
122 - Systemd init manager testing
123 - Collective effort
124 - no-x11, qa-extras2
125 * - :term:`Toaster`
126 - Toaster web interface testing
127 - Collective effort
128 - toaster
129 * - :ref:`Wic <dev-manual/wic:creating partitioned images using wic>`
130 - WIC image creation testing
131 - Collective effort
132 - wic
133 * - :wikipedia:`X86 <X86>`
134 - X86 architecture testing
135 - Collective effort
136 - genericx86,
137 genericx86-64,
138 genericx86-64-alt,
139 genericx86-alt,
140 musl-qemux86,
141 musl-qemux86-64,
142 qemux86,
143 qemux86-64,
144 qemux86-64-alt,
145 qemux86-64-ltp,
146 qemux86-64-ptest,
147 qemux86-64-tc,
148 qemux86-64-x32,
149 qemux86-alt,
150 qemux86-tc,
151 qemux86-world,
152 qemux86-world-alt
153
154Secondary Supported
155===================
156
157The term "secondary" means that in some cases there is code/feature/support
158which is desired by people using the project and is in the project's interests
159to support, however there isn't wide enough interest and support to justify
160testing all incoming changes on it. There are however project member
161organisations and maintainers willing to run tests and review fixes.
162
163This category may be applicable as support/usage in an area develops and grows,
164or as support/usage fades but we continue to have tests. It can also apply where
165resourcing isn't available for full primary support but there is
166member/maintainer support for running tests.
167
168We therefore have the following criteria and policies for such items:
169
170- It can be clearly isolated and defined by specific configuration.
171
172- There is a clear documented group of maintainers agreeing to maintain it.
173
174- Those maintainers are active and responsive.
175
176- It is being actively and publicly tested (potentially using
177 the :ref:`Autobuilder <test-manual/intro:Yocto Project Autobuilder Overview>`
178 by agreement, or otherwise).
179
180- Testing would not be part of standard incoming change testing and regressions
181 would not block incoming patches.
182
183- The :yocto_wiki:`SWAT </Yocto_Build_Failure_Swat_Team>` team would not handle
184 any test builds on the Autobuilder.
185
186- Test results can be submitted as part of the release process if desired.
187
188The Yocto Project :oe_wiki:`Technical Steering Committee (TSC) </TSC>` makes
189decisions on features in this status and Autobuilder testing. Such support would
190be dropped if the maintainers/testing were inactive.
191
192If you are interested in providing resources for improving testing please
193contact the :oe_wiki:`Technical Steering Committee (TSC) </TSC>`.
194
195Below is a list of secondary tested features, their maintainer(s) and
196builder(s):
197
198.. list-table::
199 :widths: 20 20 20 40
200 :header-rows: 1
201
202 * - Feature
203 - Description
204 - Maintainer(s)
205 - Builder(s)
206 * - :wikipedia:`PowerPC (32-bit) <PowerPC>`
207 - PowerPC architecture testing (32-bit)
208 - TBD
209 - qemuppc,
210 qemuppc-alt,
211 qemuppc-tc
212 * - :oe_git:`meta-openembedded </meta-openembedded>`
213 - meta-openembedded layer testing
214 - TBD
215 - meta-oe
216 * - `meta-mingw <https://git.yoctoproject.org/meta-mingw>`__
217 - mingw based SDKs testing
218 - TBD
219 - meta-mingw
220 * - `meta-webosose <https://github.com/webosose/meta-webosose>`__
221 - meta-webosose layer testing
222 - TBD
223 - meta-webosose
224 * - :wikipedia:`RISC-V (32-bit) <RISC-V>`
225 - RISC-V architecture testing (32-bit)
226 - Collective effort
227 - qemuriscv32,
228 qemuriscv32,
229 qemuriscv32-tc
230
231Untested
232========
233
234"Untested" means that whilst the configurations are present in the project, we
235don't currently run the tests on any regular basis and new changes are not
236tested against them. We may take patches in these areas if they make sense but
237it is on a best effort only basis.
238
239.. list-table::
240 :widths: 20 20 20 40
241 :header-rows: 1
242
243 * - Feature
244 - Description
245 - Maintainer(s)
246 - Builder(s)
247 * - `meta-exein <https://github.com/exein-io/meta-exein>`__
248 - meta-exein layer testing
249 - TBD
250 - meta-exein
251 * - :wikipedia:`MIPS <MIPS_architecture>`
252 - MIPS architecture testing
253 - No maintainers
254 - qemumips,
255 qemumips64,
256 qemumips-alt,
257 qemumips-tc,
258 qemumips64-tc
259 * - :wikipedia:`PowerPC (64-bit) <PowerPC>`
260 - PowerPC architecture testing (64-bit)
261 - No maintainers
262 - qemuppc64,
263 qemuppc64-tc
diff --git a/meta-selftest/recipes-test/images/wic-image-minimal.wks b/meta-selftest/recipes-test/images/wic-image-minimal.wks
index ae69cb6e3c..4186b16517 100644
--- a/meta-selftest/recipes-test/images/wic-image-minimal.wks
+++ b/meta-selftest/recipes-test/images/wic-image-minimal.wks
@@ -2,7 +2,7 @@
2# long-description: This image contains boot partition and 3 rootfs partitions 2# long-description: This image contains boot partition and 3 rootfs partitions
3# created from core-image-minimal and wic-image-minimal image recipes. 3# created from core-image-minimal and wic-image-minimal image recipes.
4 4
5part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024 5part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
6part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid 6part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
7part /media --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label uuid-test --align 1024 --use-uuid --fsuuid 2c71ef06-a81d-4735-9d3a-379b69c6bdba 7part /media --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label uuid-test --align 1024 --use-uuid --fsuuid 2c71ef06-a81d-4735-9d3a-379b69c6bdba
8part /mnt --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label core --align 1024 8part /mnt --source rootfs --rootfs-dir=wic-image-minimal --ondisk sda --fstype=ext4 --label core --align 1024
diff --git a/meta-selftest/wic/overlayfs_etc.wks.in b/meta-selftest/wic/overlayfs_etc.wks.in
index 066cd35b15..8375d73a9c 100644
--- a/meta-selftest/wic/overlayfs_etc.wks.in
+++ b/meta-selftest/wic/overlayfs_etc.wks.in
@@ -1,4 +1,4 @@
1part /boot --active --source bootimg-biosplusefi --ondisk sda --sourceparams="loader=grub-efi" --align 1024 1part /boot --active --source bootimg_biosplusefi --ondisk sda --sourceparams="loader=grub-efi" --align 1024
2part / --source rootfs --ondisk sda --fstype=${OVERLAYFS_ROOTFS_TYPE} --use-uuid --align 1024 2part / --source rootfs --ondisk sda --fstype=${OVERLAYFS_ROOTFS_TYPE} --use-uuid --align 1024
3part --ondisk sda --fstype=ext4 --size=5 --align 1024 3part --ondisk sda --fstype=ext4 --size=5 --align 1024
4bootloader --ptable gpt --timeout=1 --append="rootfstype=${OVERLAYFS_ROOTFS_TYPE} console=ttyS0,115200 console=tty0 ${OVERLAYFS_INIT_OPTION}" 4bootloader --ptable gpt --timeout=1 --append="rootfstype=${OVERLAYFS_ROOTFS_TYPE} console=ttyS0,115200 console=tty0 ${OVERLAYFS_INIT_OPTION}"
diff --git a/meta-selftest/wic/test_biosplusefi_plugin.wks b/meta-selftest/wic/test_biosplusefi_plugin.wks
index 5a56c84518..4be6643a6f 100644
--- a/meta-selftest/wic/test_biosplusefi_plugin.wks
+++ b/meta-selftest/wic/test_biosplusefi_plugin.wks
@@ -1,6 +1,6 @@
1# short-description: This file is used in oe-selftest wic module to test biosplusefi plugin 1# short-description: This file is used in oe-selftest wic module to test biosplusefi plugin
2 2
3part /boot --source bootimg-biosplusefi --sourceparams="loader=grub-efi" --active --align 1024 --use-uuid 3part /boot --source bootimg_biosplusefi --sourceparams="loader=grub-efi" --active --align 1024 --use-uuid
4part / --source rootfs --fstype=ext4 --align 1024 --use-uuid 4part / --source rootfs --fstype=ext4 --align 1024 --use-uuid
5 5
6bootloader --timeout=0 --append="console=ttyS0,115200n8" 6bootloader --timeout=0 --append="console=ttyS0,115200n8"
diff --git a/meta-selftest/wic/test_efi_plugin.wks b/meta-selftest/wic/test_efi_plugin.wks
index e876a4be0e..f75e0f0e0b 100644
--- a/meta-selftest/wic/test_efi_plugin.wks
+++ b/meta-selftest/wic/test_efi_plugin.wks
@@ -1,5 +1,5 @@
1# short-description: This file is used in oe-selftest wic module to test efi plugin 1# short-description: This file is used in oe-selftest wic module to test efi plugin
2part /boot --source bootimg-efi --sourceparams="loader=systemd-boot" --active --align 1024 --use-uuid 2part /boot --source bootimg_efi --sourceparams="loader=systemd-boot" --active --align 1024 --use-uuid
3part / --source rootfs --fstype=ext4 --align 1024 --use-uuid --label root 3part / --source rootfs --fstype=ext4 --align 1024 --use-uuid --label root
4 4
5bootloader --timeout=0 --append="console=ttyS0,115200n8" 5bootloader --timeout=0 --append="console=ttyS0,115200n8"
diff --git a/meta-selftest/wic/test_efi_plugin_plain_systemd-boot.wks b/meta-selftest/wic/test_efi_plugin_plain_systemd-boot.wks
index 83f136ac15..3a58c8137c 100644
--- a/meta-selftest/wic/test_efi_plugin_plain_systemd-boot.wks
+++ b/meta-selftest/wic/test_efi_plugin_plain_systemd-boot.wks
@@ -1,5 +1,5 @@
1# short-description: This file is used in oe-selftest wic module to test efi plugin 1# short-description: This file is used in oe-selftest wic module to test efi plugin
2part /boot --source bootimg-efi --sourceparams="loader=systemd-boot,initrd=${INITRAMFS_IMAGE}-${MACHINE}.${INITRAMFS_FSTYPES}" --active --align 1024 --use-uuid 2part /boot --source bootimg_efi --sourceparams="loader=systemd-boot,initrd=${INITRAMFS_IMAGE}-${MACHINE}.${INITRAMFS_FSTYPES}" --active --align 1024 --use-uuid
3part / --source rootfs --fstype=ext4 --align 1024 --use-uuid 3part / --source rootfs --fstype=ext4 --align 1024 --use-uuid
4 4
5bootloader --timeout=0 5bootloader --timeout=0
diff --git a/meta-selftest/wic/test_rawcopy_plugin.wks.in b/meta-selftest/wic/test_rawcopy_plugin.wks.in
index a865dd1d32..ba324d9980 100644
--- a/meta-selftest/wic/test_rawcopy_plugin.wks.in
+++ b/meta-selftest/wic/test_rawcopy_plugin.wks.in
@@ -1,6 +1,6 @@
1# short-description: This file is used in oe-selftest wic module to test rawcopy plugin 1# short-description: This file is used in oe-selftest wic module to test rawcopy plugin
2 2
3part /boot --active --source bootimg-pcbios 3part /boot --active --source bootimg_pcbios
4part / --source rawcopy --sourceparams="file=${IMAGE_LINK_NAME_CORE_IMAGE_MINIMAL}.ext4" --use-uuid 4part / --source rawcopy --sourceparams="file=${IMAGE_LINK_NAME_CORE_IMAGE_MINIMAL}.ext4" --use-uuid
5 5
6bootloader --timeout=0 --append="console=ttyS0,115200n8" 6bootloader --timeout=0 --append="console=ttyS0,115200n8"
diff --git a/meta-selftest/wic/test_uefikernel.wks b/meta-selftest/wic/test_uefikernel.wks
index bede2288f6..9bc4813dfa 100644
--- a/meta-selftest/wic/test_uefikernel.wks
+++ b/meta-selftest/wic/test_uefikernel.wks
@@ -1,5 +1,5 @@
1# short-description: This file is used in oe-selftest wic module to test uefi-kernel loader 1# short-description: This file is used in oe-selftest wic module to test uefi-kernel loader
2 2
3part /boot --source bootimg-efi --sourceparams="loader=uefi-kernel" 3part /boot --source bootimg_efi --sourceparams="loader=uefi-kernel"
4part / --source rootfs --fstype=ext4 --align 1024 --use-uuid 4part / --source rootfs --fstype=ext4 --align 1024 --use-uuid
5 5
diff --git a/meta-yocto-bsp/wic/beaglebone-yocto.wks b/meta-yocto-bsp/wic/beaglebone-yocto.wks
index 7a28fb23dc..335e2b9bd5 100644
--- a/meta-yocto-bsp/wic/beaglebone-yocto.wks
+++ b/meta-yocto-bsp/wic/beaglebone-yocto.wks
@@ -2,6 +2,6 @@
2# long-description: Creates a partitioned SD card image for Beaglebone. 2# long-description: Creates a partitioned SD card image for Beaglebone.
3# Boot files are located in the first vfat partition. 3# Boot files are located in the first vfat partition.
4 4
5part /boot --source bootimg-partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --fixed-size 32 --sourceparams="loader=u-boot" --use-uuid 5part /boot --source bootimg_partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --fixed-size 32 --sourceparams="loader=u-boot" --use-uuid
6part / --source rootfs --ondisk mmcblk0 --fstype=ext4 --label root --align 4 --use-uuid 6part / --source rootfs --ondisk mmcblk0 --fstype=ext4 --label root --align 4 --use-uuid
7bootloader --append="console=ttyS0,115200" 7bootloader --append="console=ttyS0,115200"
diff --git a/meta-yocto-bsp/wic/genericarm64.wks.in b/meta-yocto-bsp/wic/genericarm64.wks.in
index ee7da87ded..52ee8147fa 100644
--- a/meta-yocto-bsp/wic/genericarm64.wks.in
+++ b/meta-yocto-bsp/wic/genericarm64.wks.in
@@ -2,7 +2,7 @@
2# long-description: Creates a partitioned EFI disk image that the user 2# long-description: Creates a partitioned EFI disk image that the user
3# can directly dd to boot media. 3# can directly dd to boot media.
4 4
5part /boot --source bootimg-efi --sourceparams="loader=${EFI_PROVIDER},initrd=${INITRAMFS_IMAGE}-${MACHINE}.${INITRAMFS_FSTYPES}" --label boot --active --align 1024 --use-uuid 5part /boot --source bootimg_efi --sourceparams="loader=${EFI_PROVIDER},initrd=${INITRAMFS_IMAGE}-${MACHINE}.${INITRAMFS_FSTYPES}" --label boot --active --align 1024 --use-uuid
6 6
7part swap --size 44 --label swap --fstype=swap --use-uuid 7part swap --size 44 --label swap --fstype=swap --use-uuid
8 8
diff --git a/meta-yocto-bsp/wic/genericx86.wks.in b/meta-yocto-bsp/wic/genericx86.wks.in
index 7c09ad00a1..f75ae9adac 100644
--- a/meta-yocto-bsp/wic/genericx86.wks.in
+++ b/meta-yocto-bsp/wic/genericx86.wks.in
@@ -1,6 +1,6 @@
1# short-description: Create an EFI disk image for genericx86* 1# short-description: Create an EFI disk image for genericx86*
2# long-description: Creates a partitioned EFI disk image for genericx86* machines 2# long-description: Creates a partitioned EFI disk image for genericx86* machines
3part /boot --source bootimg-efi --sourceparams="loader=${EFI_PROVIDER}" --ondisk sda --label msdos --active --align 1024 3part /boot --source bootimg_efi --sourceparams="loader=${EFI_PROVIDER}" --ondisk sda --label msdos --active --align 1024
4part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid 4part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
5part swap --ondisk sda --size 44 --label swap1 --fstype=swap 5part swap --ondisk sda --size 44 --label swap1 --fstype=swap
6 6
diff --git a/meta/classes-global/base.bbclass b/meta/classes-global/base.bbclass
index 8215969c7b..e55a538e36 100644
--- a/meta/classes-global/base.bbclass
+++ b/meta/classes-global/base.bbclass
@@ -19,6 +19,21 @@ PACKAGECONFIG_CONFARGS ??= ""
19 19
20inherit metadata_scm 20inherit metadata_scm
21 21
22PREFERRED_TOOLCHAIN_TARGET ??= "gcc"
23PREFERRED_TOOLCHAIN_NATIVE ??= "gcc"
24PREFERRED_TOOLCHAIN_SDK ??= "gcc"
25
26PREFERRED_TOOLCHAIN = "${PREFERRED_TOOLCHAIN_TARGET}"
27PREFERRED_TOOLCHAIN:class-native = "${PREFERRED_TOOLCHAIN_NATIVE}"
28PREFERRED_TOOLCHAIN:class-cross = "${PREFERRED_TOOLCHAIN_NATIVE}"
29PREFERRED_TOOLCHAIN:class-crosssdk = "${PREFERRED_TOOLCHAIN_SDK}"
30PREFERRED_TOOLCHAIN:class-nativesdk = "${PREFERRED_TOOLCHAIN_SDK}"
31
32TOOLCHAIN ??= "${PREFERRED_TOOLCHAIN}"
33
34inherit toolchain/gcc-native
35inherit_defer toolchain/${TOOLCHAIN}
36
22def lsb_distro_identifier(d): 37def lsb_distro_identifier(d):
23 adjust = d.getVar('LSB_DISTRO_ADJUST') 38 adjust = d.getVar('LSB_DISTRO_ADJUST')
24 adjust_func = None 39 adjust_func = None
@@ -267,10 +282,19 @@ def buildcfg_neededvars(d):
267 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser)) 282 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser))
268 283
269addhandler base_eventhandler 284addhandler base_eventhandler
270base_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.MultiConfigParsed bb.event.BuildStarted bb.event.RecipePreFinalise bb.event.RecipeParsed" 285base_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.MultiConfigParsed bb.event.BuildStarted bb.event.RecipePreFinalise bb.event.RecipeParsed bb.event.RecipePreDeferredInherits"
271python base_eventhandler() { 286python base_eventhandler() {
272 import bb.runqueue 287 import bb.runqueue
273 288
289 if isinstance(e, bb.event.RecipePreDeferredInherits):
290 # Use this to snoop on class extensions and set these up before the deferred inherits
291 # are processed which allows overrides on conditional variables.
292 for c in ['native', 'nativesdk', 'crosssdk', 'cross']:
293 if c in e.inherits:
294 d.setVar('CLASSOVERRIDE', 'class-' + c)
295 break
296 return
297
274 if isinstance(e, bb.event.ConfigParsed): 298 if isinstance(e, bb.event.ConfigParsed):
275 if not d.getVar("NATIVELSBSTRING", False): 299 if not d.getVar("NATIVELSBSTRING", False):
276 d.setVar("NATIVELSBSTRING", lsb_distro_identifier(d)) 300 d.setVar("NATIVELSBSTRING", lsb_distro_identifier(d))
diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass
index eb8591f624..c45650291f 100644
--- a/meta/classes-global/insane.bbclass
+++ b/meta/classes-global/insane.bbclass
@@ -832,7 +832,7 @@ def package_qa_check_rdepends(pkg, pkgdest, skip, taskdeps, packages, d):
832 return False 832 return False
833 833
834 for rdepend in rdepends: 834 for rdepend in rdepends:
835 if "-dbg" in rdepend and "debug-deps" not in skip: 835 if rdepend.endswith("-dbg") and "debug-deps" not in skip:
836 error_msg = "%s rdepends on %s" % (pkg,rdepend) 836 error_msg = "%s rdepends on %s" % (pkg,rdepend)
837 oe.qa.handle_error("debug-deps", error_msg, d) 837 oe.qa.handle_error("debug-deps", error_msg, d)
838 if (not "-dev" in pkg and not "-staticdev" in pkg) and rdepend.endswith("-dev") and "dev-deps" not in skip: 838 if (not "-dev" in pkg and not "-staticdev" in pkg) and rdepend.endswith("-dev") and "dev-deps" not in skip:
diff --git a/meta/classes-recipe/crosssdk.bbclass b/meta/classes-recipe/crosssdk.bbclass
index 824b1bcff4..3541c2c393 100644
--- a/meta/classes-recipe/crosssdk.bbclass
+++ b/meta/classes-recipe/crosssdk.bbclass
@@ -4,6 +4,7 @@
4# SPDX-License-Identifier: MIT 4# SPDX-License-Identifier: MIT
5# 5#
6 6
7BB_DEFER_BBCLASSES:remove = "cross"
7inherit cross 8inherit cross
8 9
9CLASSOVERRIDE = "class-crosssdk" 10CLASSOVERRIDE = "class-crosssdk"
diff --git a/meta/classes/toaster.bbclass b/meta/classes/toaster.bbclass
index 03c4f3a930..af7c457808 100644
--- a/meta/classes/toaster.bbclass
+++ b/meta/classes/toaster.bbclass
@@ -84,7 +84,7 @@ python toaster_layerinfo_dumpdata() {
84 84
85 llayerinfo = {} 85 llayerinfo = {}
86 86
87 for layer in { l for l in bblayers.strip().split(" ") if len(l) }: 87 for layer in { l for l in bblayers.strip().split() if len(l) }:
88 llayerinfo[layer] = _get_layer_dict(layer) 88 llayerinfo[layer] = _get_layer_dict(layer)
89 89
90 90
diff --git a/meta/conf/toolchain/clang.inc b/meta/classes/toolchain/clang.bbclass
index 8a0a2c315a..d7b8a3657c 100644
--- a/meta/conf/toolchain/clang.inc
+++ b/meta/classes/toolchain/clang.bbclass
@@ -14,15 +14,18 @@ STRINGS = "${HOST_PREFIX}llvm-strings"
14NM = "${HOST_PREFIX}llvm-nm" 14NM = "${HOST_PREFIX}llvm-nm"
15READELF = "${HOST_PREFIX}llvm-readelf" 15READELF = "${HOST_PREFIX}llvm-readelf"
16 16
17PREFERRED_PROVIDER_virtual/cross-cc = "${MLPREFIX}clang-cross-${TARGET_ARCH}" 17PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-cc = "${MLPREFIX}clang-cross-${TARGET_ARCH}"
18PREFERRED_PROVIDER_virtual/cross-c++ = "${MLPREFIX}clang-cross-${TARGET_ARCH}" 18PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-c++ = "${MLPREFIX}clang-cross-${TARGET_ARCH}"
19PREFERRED_PROVIDER_virtual/compilerlibs = "gcc-runtime" 19PREFERRED_PROVIDER_virtual/${MLPREFIX}compilerlibs = "${MLPREFIX}gcc-runtime"
20PREFERRED_PROVIDER_virtual/cross-cc:class-nativesdk = "clang-crosssdk-${SDK_SYS}" 20PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-cc:class-nativesdk = "clang-crosssdk-${SDK_SYS}"
21PREFERRED_PROVIDER_virtual/cross-c++:class-nativesdk = "clang-crosssdk-${SDK_SYS}" 21PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-c++:class-nativesdk = "clang-crosssdk-${SDK_SYS}"
22 22
23PREFERRED_PROVIDER_virtual/nativesdk-cross-cc = "clang-crosssdk-${SDK_SYS}" 23PREFERRED_PROVIDER_virtual/nativesdk-cross-cc:class-crosssdk = "clang-crosssdk-${SDK_SYS}"
24PREFERRED_PROVIDER_virtual/nativesdk-cross-c++ = "clang-crosssdk-${SDK_SYS}" 24PREFERRED_PROVIDER_virtual/nativesdk-cross-c++:class-crosssdk = "clang-crosssdk-${SDK_SYS}"
25PREFERRED_PROVIDER_virtual/nativesdk-compilerlibs = "nativesdk-gcc-runtime" 25
26PREFERRED_PROVIDER_virtual/nativesdk-cross-cc:class-cross-canadian = "clang-crosssdk-${SDK_SYS}"
27PREFERRED_PROVIDER_virtual/nativesdk-cross-c++:class-cross-canadian = "clang-crosssdk-${SDK_SYS}"
28
26 29
27BASE_DEFAULT_DEPS:append:class-target = " compiler-rt" 30BASE_DEFAULT_DEPS:append:class-target = " compiler-rt"
28 31
diff --git a/meta/conf/toolchain/build-gcc.inc b/meta/classes/toolchain/gcc-native.bbclass
index a708bd0389..a708bd0389 100644
--- a/meta/conf/toolchain/build-gcc.inc
+++ b/meta/classes/toolchain/gcc-native.bbclass
diff --git a/meta/classes/toolchain/gcc.bbclass b/meta/classes/toolchain/gcc.bbclass
new file mode 100644
index 0000000000..a5adb5ca37
--- /dev/null
+++ b/meta/classes/toolchain/gcc.bbclass
@@ -0,0 +1,33 @@
1CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
2CXX = "${CCACHE}${HOST_PREFIX}g++ ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
3FC = "${HOST_PREFIX}gfortran ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
4CPP = "${HOST_PREFIX}gcc -E${TOOLCHAIN_OPTIONS} ${HOST_CC_ARCH}"
5LD = "${HOST_PREFIX}ld${TOOLCHAIN_OPTIONS} ${HOST_LD_ARCH}"
6CCLD = "${CC}"
7AR = "${HOST_PREFIX}gcc-ar"
8AS = "${HOST_PREFIX}as ${HOST_AS_ARCH}"
9RANLIB = "${HOST_PREFIX}gcc-ranlib"
10STRIP = "${HOST_PREFIX}strip"
11OBJCOPY = "${HOST_PREFIX}objcopy"
12OBJDUMP = "${HOST_PREFIX}objdump"
13STRINGS = "${HOST_PREFIX}strings"
14NM = "${HOST_PREFIX}gcc-nm"
15READELF = "${HOST_PREFIX}readelf"
16
17PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-cc = "${MLPREFIX}gcc-cross-${TARGET_ARCH}"
18PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-c++ = "${MLPREFIX}gcc-cross-${TARGET_ARCH}"
19PREFERRED_PROVIDER_virtual/${MLPREFIX}compilerlibs = "${MLPREFIX}gcc-runtime"
20
21PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-cc:class-nativesdk = "gcc-crosssdk-${SDK_SYS}"
22PREFERRED_PROVIDER_virtual/${MLPREFIX}cross-c++:class-nativesdk = "gcc-crosssdk-${SDK_SYS}"
23PREFERRED_PROVIDER_virtual/${MLPREFIX}compilerlibs:class-nativesdk = "nativesdk-gcc-runtime"
24
25PREFERRED_PROVIDER_virtual/nativesdk-cross-cc:class-crosssdk = "gcc-crosssdk-${SDK_SYS}"
26PREFERRED_PROVIDER_virtual/nativesdk-cross-c++:class-crosssdk = "gcc-crosssdk-${SDK_SYS}"
27PREFERRED_PROVIDER_virtual/nativesdk-compilerlibs:class-crosssdk = "nativesdk-gcc-runtime"
28
29PREFERRED_PROVIDER_virtual/nativesdk-cross-cc:class-cross-canadian = "gcc-crosssdk-${SDK_SYS}"
30PREFERRED_PROVIDER_virtual/nativesdk-cross-c++:class-cross-canadian = "gcc-crosssdk-${SDK_SYS}"
31PREFERRED_PROVIDER_virtual/nativesdk-compilerlibs:class-cross-canadian = "nativesdk-gcc-runtime"
32
33TCOVERRIDE = "toolchain-gcc"
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index e600d9d774..54d6bebc39 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -834,9 +834,6 @@ include conf/licenses.conf
834require conf/sanity.conf 834require conf/sanity.conf
835include conf/bblock.conf 835include conf/bblock.conf
836 836
837require toolchain/gcc.inc
838require toolchain/build-gcc.inc
839
840################################################################## 837##################################################################
841# Weak variables (usually to retain backwards compatibility) 838# Weak variables (usually to retain backwards compatibility)
842################################################################## 839##################################################################
@@ -950,6 +947,8 @@ BB_DEFAULT_UMASK ??= "022"
950BB_CONSOLELOG ?= "${LOG_DIR}/cooker/${MACHINE}/${DATETIME}.log" 947BB_CONSOLELOG ?= "${LOG_DIR}/cooker/${MACHINE}/${DATETIME}.log"
951BB_DEFAULT_EVENTLOG ?= "${LOG_DIR}/eventlog/${DATETIME}.json" 948BB_DEFAULT_EVENTLOG ?= "${LOG_DIR}/eventlog/${DATETIME}.json"
952 949
950BB_DEFER_BBCLASSES = "native nativesdk cross crosssdk"
951
953# Setup our default hash policy 952# Setup our default hash policy
954BB_SIGNATURE_HANDLER ?= "OEBasicHash" 953BB_SIGNATURE_HANDLER ?= "OEBasicHash"
955BB_HASHEXCLUDE_COMMON ?= "TMPDIR FILE PATH PWD BB_TASKHASH BBPATH BBSERVER DL_DIR \ 954BB_HASHEXCLUDE_COMMON ?= "TMPDIR FILE PATH PWD BB_TASKHASH BBPATH BBSERVER DL_DIR \
@@ -987,11 +986,3 @@ MULTILIB_VARIANTS ??= ""
987# support unihashes. 986# support unihashes.
988BB_UNIHASH ?= "${BB_TASKHASH}" 987BB_UNIHASH ?= "${BB_TASKHASH}"
989 988
990oe.sstatesig.find_sstate_manifest[vardepsexclude] = "BBEXTENDCURR BBEXTENDVARIANT OVERRIDES PACKAGE_EXTRA_ARCHS"
991oe.utils.get_multilib_datastore[vardepsexclude] = "DEFAULTTUNE_MULTILIB_ORIGINAL OVERRIDES"
992oe.path.format_display[vardepsexclude] = "TOPDIR"
993oe.utils.get_bb_number_threads[vardepsexclude] = "BB_NUMBER_THREADS"
994oe.package.save_debugsources_info[vardepsexclude] = "BB_NUMBER_THREADS"
995oe.package.read_debugsources_info[vardepsexclude] = "BB_NUMBER_THREADS"
996oe.packagedata.emit_pkgdata[vardepsexclude] = "BB_NUMBER_THREADS"
997oe.packagedata.read_subpkgdata_extended[vardepsexclude] = "BB_NUMBER_THREADS"
diff --git a/meta/conf/distro/include/default-distrovars.inc b/meta/conf/distro/include/default-distrovars.inc
index 85835c4c61..9ea3b5414c 100644
--- a/meta/conf/distro/include/default-distrovars.inc
+++ b/meta/conf/distro/include/default-distrovars.inc
@@ -36,6 +36,7 @@ COMMERCIAL_VIDEO_PLUGINS ?= ""
36# COMMERCIAL_VIDEO_PLUGINS ?= "gst-plugins-ugly-mpeg2dec gst-plugins-ugly-mpegstream gst-plugins-bad-mpegvideoparse" 36# COMMERCIAL_VIDEO_PLUGINS ?= "gst-plugins-ugly-mpeg2dec gst-plugins-ugly-mpegstream gst-plugins-bad-mpegvideoparse"
37# Set of common licenses used for license.bbclass 37# Set of common licenses used for license.bbclass
38COMMON_LICENSE_DIR ??= "${COREBASE}/meta/files/common-licenses" 38COMMON_LICENSE_DIR ??= "${COREBASE}/meta/files/common-licenses"
39LICENSE_PATH ??= ""
39 40
40BB_GENERATE_MIRROR_TARBALLS ??= "0" 41BB_GENERATE_MIRROR_TARBALLS ??= "0"
41 42
diff --git a/meta/conf/sanity.conf b/meta/conf/sanity.conf
index 6d3911ff94..3692007e96 100644
--- a/meta/conf/sanity.conf
+++ b/meta/conf/sanity.conf
@@ -3,7 +3,7 @@
3# See sanity.bbclass 3# See sanity.bbclass
4# 4#
5# Expert users can confirm their sanity with "touch conf/sanity.conf" 5# Expert users can confirm their sanity with "touch conf/sanity.conf"
6BB_MIN_VERSION = "2.12.0" 6BB_MIN_VERSION = "2.15.0"
7 7
8SANITY_ABIFILE = "${TMPDIR}/abi_version" 8SANITY_ABIFILE = "${TMPDIR}/abi_version"
9 9
diff --git a/meta/conf/toolchain/gcc.inc b/meta/conf/toolchain/gcc.inc
deleted file mode 100644
index 75f9abe999..0000000000
--- a/meta/conf/toolchain/gcc.inc
+++ /dev/null
@@ -1,27 +0,0 @@
1CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
2CXX = "${CCACHE}${HOST_PREFIX}g++ ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
3FC = "${HOST_PREFIX}gfortran ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
4CPP = "${HOST_PREFIX}gcc -E${TOOLCHAIN_OPTIONS} ${HOST_CC_ARCH}"
5LD = "${HOST_PREFIX}ld${TOOLCHAIN_OPTIONS} ${HOST_LD_ARCH}"
6CCLD = "${CC}"
7AR = "${HOST_PREFIX}gcc-ar"
8AS = "${HOST_PREFIX}as ${HOST_AS_ARCH}"
9RANLIB = "${HOST_PREFIX}gcc-ranlib"
10STRIP = "${HOST_PREFIX}strip"
11OBJCOPY = "${HOST_PREFIX}objcopy"
12OBJDUMP = "${HOST_PREFIX}objdump"
13STRINGS = "${HOST_PREFIX}strings"
14NM = "${HOST_PREFIX}gcc-nm"
15READELF = "${HOST_PREFIX}readelf"
16
17PREFERRED_PROVIDER_virtual/cross-cc = "${MLPREFIX}gcc-cross-${TARGET_ARCH}"
18PREFERRED_PROVIDER_virtual/cross-c++ = "${MLPREFIX}gcc-cross-${TARGET_ARCH}"
19PREFERRED_PROVIDER_virtual/compilerlibs = "gcc-runtime"
20PREFERRED_PROVIDER_virtual/cross-cc:class-nativesdk = "gcc-crosssdk-${SDK_SYS}"
21PREFERRED_PROVIDER_virtual/cross-c++:class-nativesdk = "gcc-crosssdk-${SDK_SYS}"
22
23PREFERRED_PROVIDER_virtual/nativesdk-cross-cc = "gcc-crosssdk-${SDK_SYS}"
24PREFERRED_PROVIDER_virtual/nativesdk-cross-c++ = "gcc-crosssdk-${SDK_SYS}"
25PREFERRED_PROVIDER_virtual/nativesdk-compilerlibs = "nativesdk-gcc-runtime"
26
27TCOVERRIDE = "toolchain-gcc"
diff --git a/meta/files/license-hashes.csv b/meta/files/license-hashes.csv
new file mode 100644
index 0000000000..906660b85d
--- /dev/null
+++ b/meta/files/license-hashes.csv
@@ -0,0 +1,78 @@
1008c22318c8ea65928bf730ddd0273e3,BSD-3-Clause
202d4002e9171d41a8fad93aa7faf3956,BSD-3-Clause
30636e73ff0215e8d672dc4c32c317bb3,GPL-2.0-only
4063b5c3ebb5f3aa4c85a2ed18a31fbe7,GPL-2.0-only
50a97f8e4cbaf889d6fa51f84b89a79f6,ISC
60ceb9ff3b27d3a8cf451ca3785d73c71,BSD-3-Clause & MIT
70dd48ae8103725bd7b401261520cdfbb,BSD-3-Clause
80e46634a01bfef056892949acaea85b1,BSD-3-Clause
91034431802e57486b393d00c5d262b8a,Apache-2.0
1012f884d2ae1ff87c09e5b7ccc2c4ca7e,GPL-2.0-only
1118810669f13b87348459e611d31ab760,GPL-2.0-only
1219cbd64715b51267a47bf3750cc6a8a5,Apache-2.0
13201414b6610203caed355323b1ab3116,BSD-3-Clause
14252890d9eee26aab7b432e8b8a616475,LGPL-2.0-only
152b8c039b2b9a25f0feb4410c4542d346,BSD-2-Clause
162d5025d4aa3495befef8f17206a5b0a1,LGPL-2.1-only
173214f080875748938ba060314b4f727d,LGPL-2.0-only
18385c55653886acac3821999a3ccd17b3,Artistic-1.0 | GPL-2.0-only
19393a5ca445f6965873eca0259a17f833,GPL-2.0-only
203b83ef96387f14655fc854ddc3c6bd57,Apache-2.0
213bf50002aefd002f49e7bb854063f7e7,LGPL-2.0-only
223debde09238a8c8e1f6a847e1ec9055b,LGPL-2.1-only
234325afd396febcb659c36b49533135d4,GPL-2.0-only
244c641f2d995c47f5cb08bdb4b5b6ea05,BSD-2-Clause
254ee4feb2b545c2231749e5c54ace343e,BSD-3-Clause
264fbd65380cdd255951079008b364516c,LGPL-2.1-only
2750fab24ce589d69af8964fdbfe414c60,BSD-2-Clause
2854c7042be62e169199200bc6477f04d1,BSD-3-Clause
2955ca817ccb7d5b5b66355690e9abc605,LGPL-2.0-only
3059530bdf33659b29e73d4adb9f9f6552,GPL-2.0-only
315d4950ecb7b26d2c5e4e7b4e0dd74707,BSD-3-Clause
325f30f0716dfdd0d91eb439ebec522ec2,LGPL-2.0-only
336a6a8e020838b23406c81b19c1d46df6,LGPL-3.0-only
34721f23a96ff4161ca3a5f071bbe18108,MIT
357364d1e4653d3584181e9d22d81f275f,CC0-1.0
36751419260aa954499f7abaabaa882bbe,GPL-2.0-only
3775512892d6f59dddb6d1c7e191957e9c,Zlib
3875605e6bdd564791ab698fca65c94a4f,Unlicense
397998cb338f82d15c0eff93b7004d272a,BSD-3-Clause
407f5202f4d44ed15dcd4915f5210417d8,LGPL-2.1-only
417fbc338309ac38fefcd64b04bb903e34,LGPL-2.1-only
4280fa7b56a28e8c902e6af194003220a5,BSD-2-Clause
4385d8a977ee9d7c5ab4ac03c9b95431c4,MIT-0
4488a4355858a1433fea99fae34a44da88,GPL-2.0-only
458bd23871802951c9ad63855151204c2c,BSD-2-Clause
468ca43cbc842c2336e835926c2166c28b,GPL-2.0-only
47939cce1ec101726fa754e698ac871622,BSD-3-Clause
4894d55d512a9ba36caa9b7df079bae19f,GPL-2.0-only
499ac2e7cff1ddaf48b6eab6028f23ef88,GPL-2.0-only
509f604d8a4f8e74f4f5140845a21b6674,LGPL-2.0-only
51a39327c997c20da0937955192d86232d,BSD-3-Clause
52a54a1a6a39e7f9dbb4a23a42f5c7fd1c,Apache-2.0
53a651bb3d8b1c412632e28823bb432b40,BSD-3-Clause
54a6f89e2100d9b6cdffcea4f398e37343,LGPL-2.1-only
55ad4e9d34a2e966dfe9837f18de03266d,GFDL-1.1-only
56b234ee4d69f5fce4486a80fdaf4a4263,GPL-2.0-only
57b27575459e02221ccef97ec0bfd457ae,Apache-2.0
58b376d29a53c9573006b9970709231431,MIT
59b5f72aef53d3b2b432702c30b0215666,BSD-3-Clause
60b66384e7137e41a9b1904ef4d39703b6,Apache-2.0
61bbb461211a33b134d42ed5ee802b37ff,LGPL-2.1-only
62bfe1f75d606912a4111c90743d6c7325,MPL-1.1-only
63c93c0550bd3173f4504b2cbd8991e50b,GPL-2.0-only
64d014fb11a34eb67dc717fdcfc97e60ed,GFDL-1.2-only
65d0b68be4a2dc957aaf09144970bc6696,MIT
66d32239bcb673463ab874e80d47fae504,GPL-3.0-only
67d7810fab7487fb0aad327b76f1be7cd7,GPL-2.0-only
68d8045f3b8f929c1cb29a1e3fd737b499,LGPL-2.1-only
69db979804f025cf55aabec7129cb671ed,LGPL-2.0-only
70e020ca655b06c112def28e597ab844f1,GFDL-1.3-only
71e659f77bfd9002659e112d0d3d59b2c1,BSD-2-Clause
72eb723b61539feef013de476e68b5c50a,GPL-2.0-only
73ebb5c50ab7cab4baeffba14977030c07,GPL-2.0-only
74efe2cb9a35826992b9df68224e3c2628,EPL-1.0
75f27defe1e96c2e1ecd4e0c9be8967949,GPL-3.0-only
76f90c613c51aa35da4d79dd55fc724ceb,LGPL-3.0-only
77fad9b3332be894bab9bc501572864b29,LGPL-2.1-only
78fbc093901857fcd118f065f900982c24,LGPL-2.1-only
diff --git a/meta/lib/oe/bootfiles.py b/meta/lib/oe/bootfiles.py
index 155fe742db..7ee148c4e2 100644
--- a/meta/lib/oe/bootfiles.py
+++ b/meta/lib/oe/bootfiles.py
@@ -10,7 +10,7 @@
10# Returns a list of tuples with (original filepath relative to 10# Returns a list of tuples with (original filepath relative to
11# deploy_dir, desired filepath renaming) 11# deploy_dir, desired filepath renaming)
12# 12#
13# Heavily inspired of bootimg-partition.py 13# Heavily inspired of bootimg_partition.py
14# 14#
15def get_boot_files(deploy_dir, boot_files): 15def get_boot_files(deploy_dir, boot_files):
16 import re 16 import re
diff --git a/meta/lib/oe/license_finder.py b/meta/lib/oe/license_finder.py
new file mode 100644
index 0000000000..16f5d7c94c
--- /dev/null
+++ b/meta/lib/oe/license_finder.py
@@ -0,0 +1,179 @@
1#
2# Copyright OpenEmbedded Contributors
3#
4# SPDX-License-Identifier: GPL-2.0-only
5#
6
7import fnmatch
8import hashlib
9import logging
10import os
11import re
12
13import bb
14import bb.utils
15
16logger = logging.getLogger("BitBake.OE.LicenseFinder")
17
18def _load_hash_csv(d):
19 """
20 Load a mapping of (checksum: license name) from all files/license-hashes.csv
21 files that can be found in the available layers.
22 """
23 import csv
24 md5sums = {}
25
26 # Read license md5sums from csv file
27 for path in d.getVar('BBPATH').split(':'):
28 csv_path = os.path.join(path, 'files', 'license-hashes.csv')
29 if os.path.isfile(csv_path):
30 with open(csv_path, newline='') as csv_file:
31 reader = csv.DictReader(csv_file, delimiter=',', fieldnames=['md5sum', 'license'])
32 for row in reader:
33 md5sums[row['md5sum']] = row['license']
34
35 return md5sums
36
37
38def _crunch_known_licenses(d):
39 """
40 Calculate the MD5 checksums for the original and "crunched" versions of all
41 known licenses.
42 """
43 md5sums = {}
44
45 lic_dirs = [d.getVar('COMMON_LICENSE_DIR')] + (d.getVar('LICENSE_PATH') or "").split()
46 for lic_dir in lic_dirs:
47 for fn in os.listdir(lic_dir):
48 path = os.path.join(lic_dir, fn)
49 # Hash the exact contents
50 md5value = bb.utils.md5_file(path)
51 md5sums[md5value] = fn
52 # Also hash a "crunched" version
53 md5value = _crunch_license(path)
54 md5sums[md5value] = fn
55
56 return md5sums
57
58
59def _crunch_license(licfile):
60 '''
61 Remove non-material text from a license file and then calculate its
62 md5sum. This works well for licenses that contain a copyright statement,
63 but is also a useful way to handle people's insistence upon reformatting
64 the license text slightly (with no material difference to the text of the
65 license).
66 '''
67
68 import oe.utils
69
70 # Note: these are carefully constructed!
71 license_title_re = re.compile(r'^#*\(? *(This is )?([Tt]he )?.{0,15} ?[Ll]icen[sc]e( \(.{1,10}\))?\)?[:\.]? ?#*$')
72 license_statement_re = re.compile(r'^((This (project|software)|.{1,10}) is( free software)? (released|licen[sc]ed)|(Released|Licen[cs]ed)) under the .{1,10} [Ll]icen[sc]e:?$')
73 copyright_re = re.compile(r'^ *[#\*]* *(Modified work |MIT LICENSED )?Copyright ?(\([cC]\))? .*$')
74 disclaimer_re = re.compile(r'^ *\*? ?All [Rr]ights [Rr]eserved\.$')
75 email_re = re.compile(r'^.*<[\w\.-]*@[\w\.\-]*>$')
76 header_re = re.compile(r'^(\/\**!?)? ?[\-=\*]* ?(\*\/)?$')
77 tag_re = re.compile(r'^ *@?\(?([Ll]icense|MIT)\)?$')
78 url_re = re.compile(r'^ *[#\*]* *https?:\/\/[\w\.\/\-]+$')
79
80 lictext = []
81 with open(licfile, 'r', errors='surrogateescape') as f:
82 for line in f:
83 # Drop opening statements
84 if copyright_re.match(line):
85 continue
86 elif disclaimer_re.match(line):
87 continue
88 elif email_re.match(line):
89 continue
90 elif header_re.match(line):
91 continue
92 elif tag_re.match(line):
93 continue
94 elif url_re.match(line):
95 continue
96 elif license_title_re.match(line):
97 continue
98 elif license_statement_re.match(line):
99 continue
100 # Strip comment symbols
101 line = line.replace('*', '') \
102 .replace('#', '')
103 # Unify spelling
104 line = line.replace('sub-license', 'sublicense')
105 # Squash spaces
106 line = oe.utils.squashspaces(line.strip())
107 # Replace smart quotes, double quotes and backticks with single quotes
108 line = line.replace(u"\u2018", "'").replace(u"\u2019", "'").replace(u"\u201c","'").replace(u"\u201d", "'").replace('"', '\'').replace('`', '\'')
109 # Unify brackets
110 line = line.replace("{", "[").replace("}", "]")
111 if line:
112 lictext.append(line)
113
114 m = hashlib.md5()
115 try:
116 m.update(' '.join(lictext).encode('utf-8'))
117 md5val = m.hexdigest()
118 except UnicodeEncodeError:
119 md5val = None
120 return md5val
121
122
123def find_license_files(srctree, first_only=False):
124 """
125 Search srctree for files that look like they could be licenses.
126 If first_only is True, only return the first file found.
127 """
128 licspecs = ['*LICEN[CS]E*', 'COPYING*', '*[Ll]icense*', 'LEGAL*', '[Ll]egal*', '*GPL*', 'README.lic*', 'COPYRIGHT*', '[Cc]opyright*', 'e[dp]l-v10']
129 skip_extensions = (".html", ".js", ".json", ".svg", ".ts", ".go", ".sh")
130 licfiles = []
131 for root, dirs, files in os.walk(srctree):
132 # Sort files so that LICENSE is before LICENSE.subcomponent, which is
133 # meaningful if first_only is set.
134 for fn in sorted(files):
135 if fn.endswith(skip_extensions):
136 continue
137 for spec in licspecs:
138 if fnmatch.fnmatch(fn, spec):
139 fullpath = os.path.join(root, fn)
140 if not fullpath in licfiles:
141 licfiles.append(fullpath)
142 if first_only:
143 return licfiles
144
145 return licfiles
146
147
148def match_licenses(licfiles, srctree, d, extra_hashes={}):
149 md5sums = {}
150 md5sums.update(_load_hash_csv(d))
151 md5sums.update(_crunch_known_licenses(d))
152 md5sums.update(extra_hashes)
153
154 licenses = []
155 for licfile in sorted(licfiles):
156 resolved_licfile = d.expand(licfile)
157 md5value = bb.utils.md5_file(resolved_licfile)
158 license = md5sums.get(md5value, None)
159 if not license:
160 crunched_md5 = _crunch_license(resolved_licfile)
161 license = md5sums.get(crunched_md5, None)
162 if not license:
163 license = 'Unknown'
164 logger.info("Please add the following line for '%s' to a 'license-hashes.csv' " \
165 "and replace `Unknown` with the license:\n" \
166 "%s,Unknown" % (os.path.relpath(licfile, srctree + "/.."), md5value))
167
168 licenses.append((license, os.path.relpath(licfile, srctree), md5value))
169
170 return licenses
171
172
173def find_licenses(srctree, d, first_only=False, extra_hashes={}):
174 licfiles = find_license_files(srctree, first_only)
175 licenses = match_licenses(licfiles, srctree, d, extra_hashes)
176
177 # FIXME should we grab at least one source file with a license header and add that too?
178
179 return licenses
diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py
index 60392cbced..ce69151e5d 100644
--- a/meta/lib/oe/package.py
+++ b/meta/lib/oe/package.py
@@ -16,6 +16,7 @@ import mmap
16import subprocess 16import subprocess
17import shutil 17import shutil
18 18
19import bb.parse
19import oe.cachedpath 20import oe.cachedpath
20 21
21def runstrip(file, elftype, strip, extra_strip_sections=''): 22def runstrip(file, elftype, strip, extra_strip_sections=''):
@@ -1049,6 +1050,7 @@ def copydebugsources(debugsrcdir, sources, d):
1049 if os.path.exists(p) and not os.listdir(p): 1050 if os.path.exists(p) and not os.listdir(p):
1050 os.rmdir(p) 1051 os.rmdir(p)
1051 1052
1053@bb.parse.vardepsexclude("BB_NUMBER_THREADS")
1052def save_debugsources_info(debugsrcdir, sources_raw, d): 1054def save_debugsources_info(debugsrcdir, sources_raw, d):
1053 import json 1055 import json
1054 import bb.compress.zstd 1056 import bb.compress.zstd
@@ -1081,6 +1083,7 @@ def save_debugsources_info(debugsrcdir, sources_raw, d):
1081 with bb.compress.zstd.open(debugsources_file, "wt", encoding="utf-8", num_threads=num_threads) as f: 1083 with bb.compress.zstd.open(debugsources_file, "wt", encoding="utf-8", num_threads=num_threads) as f:
1082 json.dump(sources_dict, f, sort_keys=True) 1084 json.dump(sources_dict, f, sort_keys=True)
1083 1085
1086@bb.parse.vardepsexclude("BB_NUMBER_THREADS")
1084def read_debugsources_info(d): 1087def read_debugsources_info(d):
1085 import json 1088 import json
1086 import bb.compress.zstd 1089 import bb.compress.zstd
diff --git a/meta/lib/oe/packagedata.py b/meta/lib/oe/packagedata.py
index 2d1d6ddeb7..b6a10a930a 100644
--- a/meta/lib/oe/packagedata.py
+++ b/meta/lib/oe/packagedata.py
@@ -7,6 +7,7 @@
7import codecs 7import codecs
8import os 8import os
9import json 9import json
10import bb.parse
10import bb.compress.zstd 11import bb.compress.zstd
11import oe.path 12import oe.path
12 13
@@ -64,6 +65,7 @@ def read_subpkgdata_dict(pkg, d):
64 ret[newvar] = subd[var] 65 ret[newvar] = subd[var]
65 return ret 66 return ret
66 67
68@bb.parse.vardepsexclude("BB_NUMBER_THREADS")
67def read_subpkgdata_extended(pkg, d): 69def read_subpkgdata_extended(pkg, d):
68 import json 70 import json
69 import bb.compress.zstd 71 import bb.compress.zstd
@@ -182,6 +184,7 @@ def runtime_mapping_rename(varname, pkg, d):
182 184
183 #bb.note("%s after: %s" % (varname, d.getVar(varname))) 185 #bb.note("%s after: %s" % (varname, d.getVar(varname)))
184 186
187@bb.parse.vardepsexclude("BB_NUMBER_THREADS")
185def emit_pkgdata(pkgfiles, d): 188def emit_pkgdata(pkgfiles, d):
186 def process_postinst_on_target(pkg, mlprefix): 189 def process_postinst_on_target(pkg, mlprefix):
187 pkgval = d.getVar('PKG:%s' % pkg) 190 pkgval = d.getVar('PKG:%s' % pkg)
diff --git a/meta/lib/oe/path.py b/meta/lib/oe/path.py
index 5d21cdcbdf..a1efe97d88 100644
--- a/meta/lib/oe/path.py
+++ b/meta/lib/oe/path.py
@@ -10,6 +10,8 @@ import shutil
10import subprocess 10import subprocess
11import os.path 11import os.path
12 12
13import bb.parse
14
13def join(*paths): 15def join(*paths):
14 """Like os.path.join but doesn't treat absolute RHS specially""" 16 """Like os.path.join but doesn't treat absolute RHS specially"""
15 return os.path.normpath("/".join(paths)) 17 return os.path.normpath("/".join(paths))
@@ -77,6 +79,7 @@ def replace_absolute_symlinks(basedir, d):
77 os.remove(path) 79 os.remove(path)
78 os.symlink(base, path) 80 os.symlink(base, path)
79 81
82@bb.parse.vardepsexclude("TOPDIR")
80def format_display(path, metadata): 83def format_display(path, metadata):
81 """ Prepare a path for display to the user. """ 84 """ Prepare a path for display to the user. """
82 rel = relative(metadata.getVar("TOPDIR"), path) 85 rel = relative(metadata.getVar("TOPDIR"), path)
diff --git a/meta/lib/oe/sstatesig.py b/meta/lib/oe/sstatesig.py
index 826549948e..ef687f5d41 100644
--- a/meta/lib/oe/sstatesig.py
+++ b/meta/lib/oe/sstatesig.py
@@ -3,6 +3,7 @@
3# 3#
4# SPDX-License-Identifier: GPL-2.0-only 4# SPDX-License-Identifier: GPL-2.0-only
5# 5#
6import bb.parse
6import bb.siggen 7import bb.siggen
7import bb.runqueue 8import bb.runqueue
8import oe 9import oe
@@ -493,6 +494,7 @@ def sstate_get_manifest_filename(task, d):
493 d2.setVar("SSTATE_MANMACH", extrainf) 494 d2.setVar("SSTATE_MANMACH", extrainf)
494 return (d2.expand("${SSTATE_MANFILEPREFIX}.%s" % task), d2) 495 return (d2.expand("${SSTATE_MANFILEPREFIX}.%s" % task), d2)
495 496
497@bb.parse.vardepsexclude("BBEXTENDCURR", "BBEXTENDVARIANT", "OVERRIDES", "PACKAGE_EXTRA_ARCHS")
496def find_sstate_manifest(taskdata, taskdata2, taskname, d, multilibcache): 498def find_sstate_manifest(taskdata, taskdata2, taskname, d, multilibcache):
497 d2 = d 499 d2 = d
498 variant = '' 500 variant = ''
diff --git a/meta/lib/oe/utils.py b/meta/lib/oe/utils.py
index d272dd2b8d..a11db5f3cd 100644
--- a/meta/lib/oe/utils.py
+++ b/meta/lib/oe/utils.py
@@ -9,6 +9,8 @@ import multiprocessing
9import traceback 9import traceback
10import errno 10import errno
11 11
12import bb.parse
13
12def read_file(filename): 14def read_file(filename):
13 try: 15 try:
14 f = open( filename, "r" ) 16 f = open( filename, "r" )
@@ -265,6 +267,7 @@ def execute_pre_post_process(d, cmds):
265 bb.note("Executing %s ..." % cmd) 267 bb.note("Executing %s ..." % cmd)
266 bb.build.exec_func(cmd, d) 268 bb.build.exec_func(cmd, d)
267 269
270@bb.parse.vardepsexclude("BB_NUMBER_THREADS")
268def get_bb_number_threads(d): 271def get_bb_number_threads(d):
269 return int(d.getVar("BB_NUMBER_THREADS") or os.cpu_count() or 1) 272 return int(d.getVar("BB_NUMBER_THREADS") or os.cpu_count() or 1)
270 273
@@ -467,7 +470,7 @@ def host_gcc_version(d, taskcontextonly=False):
467 version = match.group(1) 470 version = match.group(1)
468 return "-%s" % version if version in ("4.8", "4.9") else "" 471 return "-%s" % version if version in ("4.8", "4.9") else ""
469 472
470 473@bb.parse.vardepsexclude("DEFAULTTUNE_MULTILIB_ORIGINAL", "OVERRIDES")
471def get_multilib_datastore(variant, d): 474def get_multilib_datastore(variant, d):
472 localdata = bb.data.createCopy(d) 475 localdata = bb.data.createCopy(d)
473 if variant: 476 if variant:
diff --git a/meta/lib/oeqa/selftest/cases/fitimage.py b/meta/lib/oeqa/selftest/cases/fitimage.py
index be291e4b0f..ca4724d1ae 100644
--- a/meta/lib/oeqa/selftest/cases/fitimage.py
+++ b/meta/lib/oeqa/selftest/cases/fitimage.py
@@ -786,7 +786,7 @@ FIT_CONF_PREFIX = "foo-"
786 EXPECTED_COMP = ["ti,am335x-bone-green", "ti,am335x-bone-black", "ti,am335x-bone", "ti,am33xx"] 786 EXPECTED_COMP = ["ti,am335x-bone-green", "ti,am335x-bone-black", "ti,am335x-bone", "ti,am33xx"]
787 787
788 config = """ 788 config = """
789DISTRO="poky" 789DISTRO = "poky"
790MACHINE = "beaglebone-yocto" 790MACHINE = "beaglebone-yocto"
791""" 791"""
792 self.write_config(config) 792 self.write_config(config)
@@ -918,7 +918,7 @@ UBOOT_MKIMAGE_SIGN_ARGS = "-c 'a smart comment'"
918 bb_vars = self._fit_get_bb_vars() 918 bb_vars = self._fit_get_bb_vars()
919 919
920 # Ensure new keys are generated and FIT_GENERATE_KEYS = "1" is tested 920 # Ensure new keys are generated and FIT_GENERATE_KEYS = "1" is tested
921 bitbake("kernel-signing-keys-native -c cleansstate") 921 bitbake("kernel-signing-keys-native -c compile -f")
922 922
923 self._test_fitimage(bb_vars) 923 self._test_fitimage(bb_vars)
924 924
@@ -938,7 +938,7 @@ UBOOT_MKIMAGE_SIGN_ARGS = "-c 'a smart comment'"
938 """ 938 """
939 939
940 config = """ 940 config = """
941DISTRO="poky" 941DISTRO = "poky"
942MACHINE = "beaglebone-yocto" 942MACHINE = "beaglebone-yocto"
943INITRAMFS_IMAGE = "core-image-minimal-initramfs" 943INITRAMFS_IMAGE = "core-image-minimal-initramfs"
944INITRAMFS_SCRIPTS = "" 944INITRAMFS_SCRIPTS = ""
@@ -992,7 +992,7 @@ FIT_HASH_ALG = "sha256"
992 """ 992 """
993 993
994 config = """ 994 config = """
995DISTRO="poky" 995DISTRO = "poky"
996MACHINE = "beaglebone-yocto" 996MACHINE = "beaglebone-yocto"
997INITRAMFS_IMAGE_BUNDLE = "1" 997INITRAMFS_IMAGE_BUNDLE = "1"
998INITRAMFS_IMAGE = "core-image-minimal-initramfs" 998INITRAMFS_IMAGE = "core-image-minimal-initramfs"
diff --git a/meta/lib/oeqa/selftest/cases/wic.py b/meta/lib/oeqa/selftest/cases/wic.py
index 1a67b6df51..f45608172f 100644
--- a/meta/lib/oeqa/selftest/cases/wic.py
+++ b/meta/lib/oeqa/selftest/cases/wic.py
@@ -153,7 +153,7 @@ class Wic(WicTestCase):
153 # create a temporary file for the WKS content 153 # create a temporary file for the WKS content
154 with NamedTemporaryFile("w", suffix=".wks") as wks: 154 with NamedTemporaryFile("w", suffix=".wks") as wks:
155 wks.write( 155 wks.write(
156 'part --source bootimg-efi ' 156 'part --source bootimg_efi '
157 '--sourceparams="loader=grub-efi,install-kernel-into-boot-dir=false" ' 157 '--sourceparams="loader=grub-efi,install-kernel-into-boot-dir=false" '
158 '--label boot --active\n' 158 '--label boot --active\n'
159 ) 159 )
@@ -186,7 +186,7 @@ class Wic(WicTestCase):
186 # create a temporary file for the WKS content 186 # create a temporary file for the WKS content
187 with NamedTemporaryFile("w", suffix=".wks") as wks: 187 with NamedTemporaryFile("w", suffix=".wks") as wks:
188 wks.write( 188 wks.write(
189 'part --source bootimg-efi ' 189 'part --source bootimg_efi '
190 '--sourceparams="loader=grub-efi,install-kernel-into-boot-dir=true" ' 190 '--sourceparams="loader=grub-efi,install-kernel-into-boot-dir=true" '
191 '--label boot --active\n' 191 '--label boot --active\n'
192 ) 192 )
@@ -1358,7 +1358,7 @@ class Wic2(WicTestCase):
1358 def test_biosplusefi_plugin(self): 1358 def test_biosplusefi_plugin(self):
1359 """Test biosplusefi plugin""" 1359 """Test biosplusefi plugin"""
1360 # Wic generation below may fail depending on the order of the unittests 1360 # Wic generation below may fail depending on the order of the unittests
1361 # This is because bootimg-pcbios (that bootimg-biosplusefi uses) generate its MBR inside STAGING_DATADIR directory 1361 # This is because bootimg_pcbios (that bootimg_biosplusefi uses) generate its MBR inside STAGING_DATADIR directory
1362 # which may or may not exists depending on what was built already 1362 # which may or may not exists depending on what was built already
1363 # If an image hasn't been built yet, directory ${STAGING_DATADIR}/syslinux won't exists and _get_bootimg_dir() 1363 # If an image hasn't been built yet, directory ${STAGING_DATADIR}/syslinux won't exists and _get_bootimg_dir()
1364 # will raise with "Couldn't find correct bootimg_dir" 1364 # will raise with "Couldn't find correct bootimg_dir"
@@ -1370,7 +1370,7 @@ class Wic2(WicTestCase):
1370 1370
1371 img = 'core-image-minimal' 1371 img = 'core-image-minimal'
1372 with NamedTemporaryFile("w", suffix=".wks") as wks: 1372 with NamedTemporaryFile("w", suffix=".wks") as wks:
1373 wks.writelines(['part /boot --active --source bootimg-biosplusefi --sourceparams="loader=grub-efi"\n', 1373 wks.writelines(['part /boot --active --source bootimg_biosplusefi --sourceparams="loader=grub-efi"\n',
1374 'part / --source rootfs --fstype=ext4 --align 1024 --use-uuid\n'\ 1374 'part / --source rootfs --fstype=ext4 --align 1024 --use-uuid\n'\
1375 'bootloader --timeout=0 --append="console=ttyS0,115200n8"\n']) 1375 'bootloader --timeout=0 --append="console=ttyS0,115200n8"\n'])
1376 wks.flush() 1376 wks.flush()
@@ -1390,7 +1390,7 @@ class Wic2(WicTestCase):
1390 1390
1391 img = 'core-image-minimal' 1391 img = 'core-image-minimal'
1392 with NamedTemporaryFile("w", suffix=".wks") as wks: 1392 with NamedTemporaryFile("w", suffix=".wks") as wks:
1393 wks.writelines(['part /boot --source bootimg-efi --sourceparams="loader=uefi-kernel"\n' 1393 wks.writelines(['part /boot --source bootimg_efi --sourceparams="loader=uefi-kernel"\n'
1394 'part / --source rootfs --fstype=ext4 --align 1024 --use-uuid\n'\ 1394 'part / --source rootfs --fstype=ext4 --align 1024 --use-uuid\n'\
1395 'bootloader --timeout=0 --append="console=ttyS0,115200n8"\n']) 1395 'bootloader --timeout=0 --append="console=ttyS0,115200n8"\n'])
1396 wks.flush() 1396 wks.flush()
diff --git a/meta/recipes-core/libxml/libxml2/CVE-2025-6021.patch b/meta/recipes-core/libxml/libxml2/CVE-2025-6021.patch
new file mode 100644
index 0000000000..157486848b
--- /dev/null
+++ b/meta/recipes-core/libxml/libxml2/CVE-2025-6021.patch
@@ -0,0 +1,59 @@
1From 33d7969baf541326a35e2fbe31943c46af8c71db Mon Sep 17 00:00:00 2001
2From: Nick Wellnhofer <wellnhofer@aevum.de>
3Date: Tue, 27 May 2025 12:53:17 +0200
4Subject: [PATCH] tree: Fix integer overflow in xmlBuildQName
5
6This issue affects memory safety and might receive a CVE ID later.
7
8Fixes #926.
9
10Signed-off-by: Nick Wellnhofer <wellnhofer@aevum.de>
11
12Add '#include <stdint.h>' to assure the definition of SIZE_MAX
13CVE: CVE-2025-6021
14Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libxml2/-/commit/acbbeef9f5dcdcc901c5f3fa14d583ef8cfd22f0]
15Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
16---
17 tree.c | 9 ++++++---
18 1 file changed, 6 insertions(+), 3 deletions(-)
19
20diff --git a/tree.c b/tree.c
21index 7454b07..22ec11c 100644
22--- a/tree.c
23+++ b/tree.c
24@@ -23,6 +23,7 @@
25 #include <limits.h>
26 #include <ctype.h>
27 #include <stdlib.h>
28+#include <stdint.h>
29
30 #ifdef LIBXML_ZLIB_ENABLED
31 #include <zlib.h>
32@@ -168,10 +169,10 @@ xmlGetParameterEntityFromDtd(const xmlDtd *dtd, const xmlChar *name) {
33 xmlChar *
34 xmlBuildQName(const xmlChar *ncname, const xmlChar *prefix,
35 xmlChar *memory, int len) {
36- int lenn, lenp;
37+ size_t lenn, lenp;
38 xmlChar *ret;
39
40- if (ncname == NULL) return(NULL);
41+ if ((ncname == NULL) || (len < 0)) return(NULL);
42 if (prefix == NULL) return((xmlChar *) ncname);
43
44 #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
45@@ -182,8 +183,10 @@ xmlBuildQName(const xmlChar *ncname, const xmlChar *prefix,
46
47 lenn = strlen((char *) ncname);
48 lenp = strlen((char *) prefix);
49+ if (lenn >= SIZE_MAX - lenp - 1)
50+ return(NULL);
51
52- if ((memory == NULL) || (len < lenn + lenp + 2)) {
53+ if ((memory == NULL) || ((size_t) len < lenn + lenp + 2)) {
54 ret = xmlMalloc(lenn + lenp + 2);
55 if (ret == NULL)
56 return(NULL);
57--
582.34.1
59
diff --git a/meta/recipes-core/libxml/libxml2_2.14.3.bb b/meta/recipes-core/libxml/libxml2_2.14.3.bb
index da75cbe450..4baab59186 100644
--- a/meta/recipes-core/libxml/libxml2_2.14.3.bb
+++ b/meta/recipes-core/libxml/libxml2_2.14.3.bb
@@ -18,6 +18,7 @@ SRC_URI += "http://www.w3.org/XML/Test/xmlts20130923.tar;subdir=${BP};name=testt
18 file://run-ptest \ 18 file://run-ptest \
19 file://install-tests.patch \ 19 file://install-tests.patch \
20 file://0001-Revert-cmake-Fix-installation-directories-in-libxml2.patch \ 20 file://0001-Revert-cmake-Fix-installation-directories-in-libxml2.patch \
21 file://CVE-2025-6021.patch \
21 " 22 "
22 23
23SRC_URI[archive.sha256sum] = "6de55cacc8c2bc758f2ef6f93c313cb30e4dd5d84ac5d3c7ccbd9344d8cc6833" 24SRC_URI[archive.sha256sum] = "6de55cacc8c2bc758f2ef6f93c313cb30e4dd5d84ac5d3c7ccbd9344d8cc6833"
diff --git a/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-1.patch b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-1.patch
new file mode 100644
index 0000000000..066dfa0ff0
--- /dev/null
+++ b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-1.patch
@@ -0,0 +1,43 @@
1From 2c8fb3e5164effc8a370e800fe91db7341e69116 Mon Sep 17 00:00:00 2001
2From: Doug Flick <dougflick@microsoft.com>
3Date: Mon, 7 Apr 2025 11:23:41 -0700
4Subject: [PATCH 1/4] SecurityPkg: Update SecurityFixes.yaml for CVE-2024-38797
5
6This commit updates the SecurityFixes.yaml file to include
7information about the CVE-2024-38797 vulnerability.
8
9Signed-off-by: Doug Flick <DougFlick@microsoft.com>
10
11CVE: CVE-2024-38797
12Upstream-Status: Backport [https://github.com/tianocore/edk2/pull/10928/commits/519366f542e9370bee982b1c3687ffedb5cabc21]
13Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
14---
15 SecurityPkg/SecurityFixes.yaml | 15 +++++++++++++++
16 1 file changed, 15 insertions(+)
17
18diff --git a/SecurityPkg/SecurityFixes.yaml b/SecurityPkg/SecurityFixes.yaml
19index b4006b4..06b597a 100644
20--- a/SecurityPkg/SecurityFixes.yaml
21+++ b/SecurityPkg/SecurityFixes.yaml
22@@ -40,3 +40,18 @@ CVE_2022_36764:
23 - Library\DxeTpmMeasureBootLib\DxeTpmMeasureBootLib.c
24 links:
25 - https://bugzilla.tianocore.org/show_bug.cgi?id=4118
26+CVE_2024_38797:
27+ commit-titles:
28+ - "SecurityPkg: Out of bound read in HashPeImageByType()"
29+ - "SecurityPkg: Improving HashPeImageByType () logic"
30+ - "SecurityPkg: Improving SecureBootConfigImpl:HashPeImageByType () logic"
31+ cve: CVE-2024-38797
32+ date_reported: 2024-06-04 12:00 UTC
33+ description: Out of bound read in HashPeImageByType()
34+ note:
35+ files_impacted:
36+ - SecurityPkg\Library\DxeImageVerificationLib\DxeImageVerificationLib.c
37+ - SecurityPkg\VariableAuthenticated\SecureBootConfigDxe\SecureBootConfigImpl.c
38+ links:
39+ - https://bugzilla.tianocore.org/show_bug.cgi?id=2214
40+ - https://github.com/tianocore/edk2/security/advisories/GHSA-4wjw-6xmf-44xf
41--
422.34.1
43
diff --git a/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-2.patch b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-2.patch
new file mode 100644
index 0000000000..9bf6645681
--- /dev/null
+++ b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-2.patch
@@ -0,0 +1,63 @@
1From 1a7be26382c4a34504875f094e15fe371d44192e Mon Sep 17 00:00:00 2001
2From: Doug Flick <dougflick@microsoft.com>
3Date: Thu, 3 Oct 2024 09:37:18 -0700
4Subject: [PATCH 2/4] SecurityPkg: Out of bound read in HashPeImageByType()
5
6In HashPeImageByType(), the hash of PE/COFF image is calculated.
7This function may get untrusted input.
8
9Inside this function, the following code verifies the loaded image has
10the correct format, by reading the second byte of the buffer.
11
12```c
13 if ((*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE) {
14 ...
15 }
16```
17
18The input image is not trusted and that may not have the second byte to
19read. So this poses an out of bound read error.
20
21With below fix we are assuring that we don't do out of bound read. i.e,
22we make sure that AuthDataSize is greater than 1.
23
24```c
25 if (AuthDataSize > 1
26 && (*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE){
27 ...
28 }
29```
30
31AuthDataSize size is verified before reading the second byte.
32So if AuthDataSize is less than 2, the second byte will not be read, and
33the out of bound read situation won't occur.
34
35Tested the patch on real platform with and without TPM connected and
36verified image is booting fine.
37
38Authored-by: Raj AlwinX Selvaraj <Alw...@intel.com>
39Signed-off-by: Doug Flick <DougFlick@microsoft.com>
40
41CVE: CVE-2024-38797
42Upstream-Status: Backport [https://github.com/tianocore/edk2/pull/10928/commits/2dcdb41b564aa3cb846644b4b1722a0b3ae5e06b]
43Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
44---
45 .../Library/DxeImageVerificationLib/DxeImageVerificationLib.c | 2 +-
46 1 file changed, 1 insertion(+), 1 deletion(-)
47
48diff --git a/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c b/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
49index b05da19..2afa2c9 100644
50--- a/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
51+++ b/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
52@@ -642,7 +642,7 @@ HashPeImageByType (
53 // This field has the fixed offset (+32) in final Authenticode ASN.1 data.
54 // Fixed offset (+32) is calculated based on two bytes of length encoding.
55 //
56- if ((*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE) {
57+ if ((AuthDataSize > 1) && ((*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE)) {
58 //
59 // Only support two bytes of Long Form of Length Encoding.
60 //
61--
622.34.1
63
diff --git a/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-3.patch b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-3.patch
new file mode 100644
index 0000000000..169c78daab
--- /dev/null
+++ b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-3.patch
@@ -0,0 +1,99 @@
1From 4db363db013a92937431234252fc9d84e44fc120 Mon Sep 17 00:00:00 2001
2From: Doug Flick <dougflick@microsoft.com>
3Date: Thu, 3 Oct 2024 10:16:57 -0700
4Subject: [PATCH 3/4] SecurityPkg: Improving HashPeImageByType () logic
5
6Namely:
7
8(1) The TWO_BYTE_ENCODE check is independent of Index. If it evalutes
9 to TRUE for Index==0, then it will evaluate to TRUE for all other
10 Index values as well. As a result, the (Index == HASHALG_MAX)
11 condition will fire after the loop, and we'll return
12 EFI_UNSUPPORTED.
13
14 While this is correct, functionally speaking, it is wasteful to
15 keep re-checking TWO_BYTE_ENCODE in the loop body. The check
16 should be made at the top of the function, and EFI_UNSUPPORTED
17 should be returned at once, if appropriate.
18
19(2) If the hash algorithm selected by Index has such a large OID that
20 the OID comparison cannot even be performed (because AuthDataSize
21 is not large enough for containing the OID in question, starting
22 at offset 32), then the function returns EFI_UNSUPPORTED at once.
23
24 This is bogus; this case should simply be treated as an OID
25 mismatch, and the loop should advance to the next Index value /
26 hash algorithm candidate. A remaining hash algo may have a shorter
27 OID and yield an OID match.
28
29Signed-off-by: Doug Flick <DougFlick@microsoft.com>
30
31CVE: CVE-2024-38797
32Upstream-Status: Backport [https://github.com/tianocore/edk2/pull/10928/commits/5df518ec510324f48ed1cf0376150960644b41f0]
33Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
34---
35 .../DxeImageVerificationLib.c | 37 ++++++++++---------
36 1 file changed, 19 insertions(+), 18 deletions(-)
37
38diff --git a/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c b/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
39index 2afa2c9..2eca39d 100644
40--- a/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
41+++ b/SecurityPkg/Library/DxeImageVerificationLib/DxeImageVerificationLib.c
42@@ -618,6 +618,7 @@ Done:
43 @param[in] AuthDataSize Size of the Authenticode Signature in bytes.
44
45 @retval EFI_UNSUPPORTED Hash algorithm is not supported.
46+ @retval EFI_BAD_BUFFER_SIZE AuthData provided is invalid size.
47 @retval EFI_SUCCESS Hash successfully.
48
49 **/
50@@ -629,28 +630,28 @@ HashPeImageByType (
51 {
52 UINT8 Index;
53
54- for (Index = 0; Index < HASHALG_MAX; Index++) {
55+ //
56+ // Check the Hash algorithm in PE/COFF Authenticode.
57+ // According to PKCS#7 Definition:
58+ // SignedData ::= SEQUENCE {
59+ // version Version,
60+ // digestAlgorithms DigestAlgorithmIdentifiers,
61+ // contentInfo ContentInfo,
62+ // .... }
63+ // The DigestAlgorithmIdentifiers can be used to determine the hash algorithm in PE/COFF hashing
64+ // This field has the fixed offset (+32) in final Authenticode ASN.1 data.
65+ // Fixed offset (+32) is calculated based on two bytes of length encoding.
66+ //
67+ if ((AuthDataSize > 1) && ((*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE)) {
68 //
69- // Check the Hash algorithm in PE/COFF Authenticode.
70- // According to PKCS#7 Definition:
71- // SignedData ::= SEQUENCE {
72- // version Version,
73- // digestAlgorithms DigestAlgorithmIdentifiers,
74- // contentInfo ContentInfo,
75- // .... }
76- // The DigestAlgorithmIdentifiers can be used to determine the hash algorithm in PE/COFF hashing
77- // This field has the fixed offset (+32) in final Authenticode ASN.1 data.
78- // Fixed offset (+32) is calculated based on two bytes of length encoding.
79+ // Only support two bytes of Long Form of Length Encoding.
80 //
81- if ((AuthDataSize > 1) && ((*(AuthData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE)) {
82- //
83- // Only support two bytes of Long Form of Length Encoding.
84- //
85- continue;
86- }
87+ return EFI_BAD_BUFFER_SIZE;
88+ }
89
90+ for (Index = 0; Index < HASHALG_MAX; Index++) {
91 if (AuthDataSize < 32 + mHash[Index].OidLength) {
92- return EFI_UNSUPPORTED;
93+ continue;
94 }
95
96 if (CompareMem (AuthData + 32, mHash[Index].OidValue, mHash[Index].OidLength) == 0) {
97--
982.34.1
99
diff --git a/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-4.patch b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-4.patch
new file mode 100644
index 0000000000..86bc950e7d
--- /dev/null
+++ b/meta/recipes-core/ovmf/ovmf/CVE-2024-38797-4.patch
@@ -0,0 +1,97 @@
1From cb3342702c5c1f8a4ddbb6d503a98ed720d14eb3 Mon Sep 17 00:00:00 2001
2From: Doug Flick <dougflick@microsoft.com>
3Date: Fri, 17 Jan 2025 11:30:17 -0800
4Subject: [PATCH 4/4] SecurityPkg: Improving
5 SecureBootConfigImpl:HashPeImageByType () logic
6
7Namely:
8
9(1) The TWO_BYTE_ENCODE check is independent of Index. If it evalutes
10 to TRUE for Index==0, then it will evaluate to TRUE for all other
11 Index values as well. As a result, the (Index == HASHALG_MAX)
12 condition will fire after the loop, and we'll return
13 EFI_UNSUPPORTED.
14
15 While this is correct, functionally speaking, it is wasteful to
16 keep re-checking TWO_BYTE_ENCODE in the loop body. The check
17 should be made at the top of the function, and EFI_UNSUPPORTED
18 should be returned at once, if appropriate.
19
20(2) If the hash algorithm selected by Index has such a large OID that
21 the OID comparison cannot even be performed (because AuthDataSize
22 is not large enough for containing the OID in question, starting
23 at offset 32), then the function returns EFI_UNSUPPORTED at once.
24
25 This is bogus; this case should simply be treated as an OID
26 mismatch, and the loop should advance to the next Index value /
27 hash algorithm candidate. A remaining hash algo may have a shorter
28 OID and yield an OID match.
29
30Signed-off-by: Doug Flick <DougFlick@microsoft.com>
31
32CVE: CVE-2024-38797
33Upstream-Status: Backport [https://github.com/tianocore/edk2/pull/10928/commits/8676572908b950dd4d1f8985006011be99c0a5b6]
34Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
35---
36 .../SecureBootConfigImpl.c | 37 +++++++++++--------
37 1 file changed, 21 insertions(+), 16 deletions(-)
38
39diff --git a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c b/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
40index 6d4560c..155e755 100644
41--- a/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
42+++ b/SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.c
43@@ -2096,30 +2096,35 @@ HashPeImageByType (
44 {
45 UINT8 Index;
46 WIN_CERTIFICATE_EFI_PKCS *PkcsCertData;
47+ UINT32 PkcsCertSize;
48
49 PkcsCertData = (WIN_CERTIFICATE_EFI_PKCS *)(mImageBase + mSecDataDir->Offset);
50+ PkcsCertSize = mSecDataDir->SizeOfCert;
51
52- for (Index = 0; Index < HASHALG_MAX; Index++) {
53+ //
54+ // Check the Hash algorithm in PE/COFF Authenticode.
55+ // According to PKCS#7 Definition:
56+ // SignedData ::= SEQUENCE {
57+ // version Version,
58+ // digestAlgorithms DigestAlgorithmIdentifiers,
59+ // contentInfo ContentInfo,
60+ // .... }
61+ // The DigestAlgorithmIdentifiers can be used to determine the hash algorithm in PE/COFF hashing
62+ // This field has the fixed offset (+32) in final Authenticode ASN.1 data.
63+ // Fixed offset (+32) is calculated based on two bytes of length encoding.
64+ //
65+ if ((PkcsCertSize > 1) && ((*(PkcsCertData->CertData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE)) {
66 //
67- // Check the Hash algorithm in PE/COFF Authenticode.
68- // According to PKCS#7 Definition:
69- // SignedData ::= SEQUENCE {
70- // version Version,
71- // digestAlgorithms DigestAlgorithmIdentifiers,
72- // contentInfo ContentInfo,
73- // .... }
74- // The DigestAlgorithmIdentifiers can be used to determine the hash algorithm in PE/COFF hashing
75- // This field has the fixed offset (+32) in final Authenticode ASN.1 data.
76- // Fixed offset (+32) is calculated based on two bytes of length encoding.
77+ // Only support two bytes of Long Form of Length Encoding.
78 //
79- if ((*(PkcsCertData->CertData + 1) & TWO_BYTE_ENCODE) != TWO_BYTE_ENCODE) {
80- //
81- // Only support two bytes of Long Form of Length Encoding.
82- //
83+ return EFI_BAD_BUFFER_SIZE;
84+ }
85+
86+ for (Index = 0; Index < HASHALG_MAX; Index++) {
87+ if (PkcsCertSize < 32 + mHash[Index].OidLength) {
88 continue;
89 }
90
91- //
92 if (CompareMem (PkcsCertData->CertData + 32, mHash[Index].OidValue, mHash[Index].OidLength) == 0) {
93 break;
94 }
95--
962.34.1
97
diff --git a/meta/recipes-core/ovmf/ovmf_git.bb b/meta/recipes-core/ovmf/ovmf_git.bb
index aa7de3af2b..ab6c580722 100644
--- a/meta/recipes-core/ovmf/ovmf_git.bb
+++ b/meta/recipes-core/ovmf/ovmf_git.bb
@@ -27,6 +27,10 @@ SRC_URI = "gitsm://github.com/tianocore/edk2.git;branch=master;protocol=https \
27 file://0003-debug-prefix-map.patch \ 27 file://0003-debug-prefix-map.patch \
28 file://0004-reproducible.patch \ 28 file://0004-reproducible.patch \
29 file://CVE-2025-2295.patch \ 29 file://CVE-2025-2295.patch \
30 file://CVE-2024-38797-1.patch \
31 file://CVE-2024-38797-2.patch \
32 file://CVE-2024-38797-3.patch \
33 file://CVE-2024-38797-4.patch \
30 " 34 "
31 35
32PV = "edk2-stable202502" 36PV = "edk2-stable202502"
diff --git a/meta/recipes-core/packagegroups/packagegroup-base.bb b/meta/recipes-core/packagegroups/packagegroup-base.bb
index cb9d1f07af..2e051dba33 100644
--- a/meta/recipes-core/packagegroups/packagegroup-base.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-base.bb
@@ -119,7 +119,7 @@ python __anonymous () {
119# packages added by distribution 119# packages added by distribution
120# 120#
121SUMMARY:packagegroup-distro-base = "${DISTRO} extras" 121SUMMARY:packagegroup-distro-base = "${DISTRO} extras"
122DEPENDS_packagegroup-distro-base = "${DISTRO_EXTRA_DEPENDS}" 122DEPENDS:packagegroup-distro-base = "${DISTRO_EXTRA_DEPENDS}"
123RDEPENDS:packagegroup-distro-base = "${DISTRO_EXTRA_RDEPENDS}" 123RDEPENDS:packagegroup-distro-base = "${DISTRO_EXTRA_RDEPENDS}"
124RRECOMMENDS:packagegroup-distro-base = "${DISTRO_EXTRA_RRECOMMENDS}" 124RRECOMMENDS:packagegroup-distro-base = "${DISTRO_EXTRA_RRECOMMENDS}"
125 125
diff --git a/meta/recipes-core/systemd/systemd-boot-native_257.5.bb b/meta/recipes-core/systemd/systemd-boot-native_257.6.bb
index 05ebe7b63e..05ebe7b63e 100644
--- a/meta/recipes-core/systemd/systemd-boot-native_257.5.bb
+++ b/meta/recipes-core/systemd/systemd-boot-native_257.6.bb
diff --git a/meta/recipes-core/systemd/systemd-boot_257.5.bb b/meta/recipes-core/systemd/systemd-boot_257.6.bb
index c6c443f929..c6c443f929 100644
--- a/meta/recipes-core/systemd/systemd-boot_257.5.bb
+++ b/meta/recipes-core/systemd/systemd-boot_257.6.bb
diff --git a/meta/recipes-core/systemd/systemd-systemctl-native_257.5.bb b/meta/recipes-core/systemd/systemd-systemctl-native_257.6.bb
index 041a040a26..041a040a26 100644
--- a/meta/recipes-core/systemd/systemd-systemctl-native_257.5.bb
+++ b/meta/recipes-core/systemd/systemd-systemctl-native_257.6.bb
diff --git a/meta/recipes-core/systemd/systemd.inc b/meta/recipes-core/systemd/systemd.inc
index 243053a8c7..5ed84757f3 100644
--- a/meta/recipes-core/systemd/systemd.inc
+++ b/meta/recipes-core/systemd/systemd.inc
@@ -15,7 +15,7 @@ LICENSE:libsystemd = "LGPL-2.1-or-later"
15LIC_FILES_CHKSUM = "file://LICENSE.GPL2;md5=751419260aa954499f7abaabaa882bbe \ 15LIC_FILES_CHKSUM = "file://LICENSE.GPL2;md5=751419260aa954499f7abaabaa882bbe \
16 file://LICENSE.LGPL2.1;md5=4fbd65380cdd255951079008b364516c" 16 file://LICENSE.LGPL2.1;md5=4fbd65380cdd255951079008b364516c"
17 17
18SRCREV = "1c93ed4c72a4513d9cefcd1f89d11a9dc828d06c" 18SRCREV = "00a12c234e2506f5cab683460199575f13c454db"
19SRCBRANCH = "v257-stable" 19SRCBRANCH = "v257-stable"
20SRC_URI = "git://github.com/systemd/systemd.git;protocol=https;branch=${SRCBRANCH};tag=v${PV}" 20SRC_URI = "git://github.com/systemd/systemd.git;protocol=https;branch=${SRCBRANCH};tag=v${PV}"
21 21
diff --git a/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch b/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch
index f9a45bb40b..47b8583e7a 100644
--- a/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch
+++ b/meta/recipes-core/systemd/systemd/0004-add-fallback-parse_printf_format-implementation.patch
@@ -25,7 +25,7 @@ diff --git a/meson.build b/meson.build
25index bffda86845..4146f4beef 100644 25index bffda86845..4146f4beef 100644
26--- a/meson.build 26--- a/meson.build
27+++ b/meson.build 27+++ b/meson.build
28@@ -773,6 +773,7 @@ foreach header : ['crypt.h', 28@@ -770,6 +770,7 @@ foreach header : ['crypt.h',
29 'linux/ioprio.h', 29 'linux/ioprio.h',
30 'linux/memfd.h', 30 'linux/memfd.h',
31 'linux/time_types.h', 31 'linux/time_types.h',
diff --git a/meta/recipes-core/systemd/systemd/0012-do-not-disable-buffer-in-writing-files.patch b/meta/recipes-core/systemd/systemd/0012-do-not-disable-buffer-in-writing-files.patch
index 00b4b777f4..0bbc6bbac7 100644
--- a/meta/recipes-core/systemd/systemd/0012-do-not-disable-buffer-in-writing-files.patch
+++ b/meta/recipes-core/systemd/systemd/0012-do-not-disable-buffer-in-writing-files.patch
@@ -71,7 +71,7 @@ diff --git a/src/basic/namespace-util.c b/src/basic/namespace-util.c
71index 332e8cdfd5..804498127d 100644 71index 332e8cdfd5..804498127d 100644
72--- a/src/basic/namespace-util.c 72--- a/src/basic/namespace-util.c
73+++ b/src/basic/namespace-util.c 73+++ b/src/basic/namespace-util.c
74@@ -354,12 +354,12 @@ int userns_acquire(const char *uid_map, const char *gid_map) { 74@@ -359,12 +359,12 @@ int userns_acquire(const char *uid_map, const char *gid_map) {
75 freeze(); 75 freeze();
76 76
77 xsprintf(path, "/proc/" PID_FMT "/uid_map", pid); 77 xsprintf(path, "/proc/" PID_FMT "/uid_map", pid);
@@ -154,7 +154,7 @@ diff --git a/src/core/cgroup.c b/src/core/cgroup.c
154index 6933aae54d..ab6fccc0e4 100644 154index 6933aae54d..ab6fccc0e4 100644
155--- a/src/core/cgroup.c 155--- a/src/core/cgroup.c
156+++ b/src/core/cgroup.c 156+++ b/src/core/cgroup.c
157@@ -5167,7 +5167,7 @@ int unit_cgroup_freezer_action(Unit *u, FreezerAction action) { 157@@ -5175,7 +5175,7 @@ int unit_cgroup_freezer_action(Unit *u, FreezerAction action) {
158 if (r < 0) 158 if (r < 0)
159 return r; 159 return r;
160 160
@@ -180,7 +180,7 @@ diff --git a/src/core/main.c b/src/core/main.c
180index 172742c769..e68ce2a6d8 100644 180index 172742c769..e68ce2a6d8 100644
181--- a/src/core/main.c 181--- a/src/core/main.c
182+++ b/src/core/main.c 182+++ b/src/core/main.c
183@@ -1812,7 +1812,7 @@ static void initialize_core_pattern(bool skip_setup) { 183@@ -1826,7 +1826,7 @@ static void initialize_core_pattern(bool skip_setup) {
184 if (getpid_cached() != 1) 184 if (getpid_cached() != 1)
185 return; 185 return;
186 186
@@ -231,7 +231,7 @@ diff --git a/src/libsystemd/sd-device/sd-device.c b/src/libsystemd/sd-device/sd-
231index 01fa90b1ff..83ab655bf4 100644 231index 01fa90b1ff..83ab655bf4 100644
232--- a/src/libsystemd/sd-device/sd-device.c 232--- a/src/libsystemd/sd-device/sd-device.c
233+++ b/src/libsystemd/sd-device/sd-device.c 233+++ b/src/libsystemd/sd-device/sd-device.c
234@@ -2563,7 +2563,7 @@ _public_ int sd_device_set_sysattr_value(sd_device *device, const char *sysattr, 234@@ -2564,7 +2564,7 @@ _public_ int sd_device_set_sysattr_value(sd_device *device, const char *sysattr,
235 if (!value) 235 if (!value)
236 return -ENOMEM; 236 return -ENOMEM;
237 237
@@ -359,7 +359,7 @@ diff --git a/src/shared/coredump-util.c b/src/shared/coredump-util.c
359index 805503f366..3234a1d76e 100644 359index 805503f366..3234a1d76e 100644
360--- a/src/shared/coredump-util.c 360--- a/src/shared/coredump-util.c
361+++ b/src/shared/coredump-util.c 361+++ b/src/shared/coredump-util.c
362@@ -173,7 +173,7 @@ void disable_coredumps(void) { 362@@ -180,7 +180,7 @@ void disable_coredumps(void) {
363 if (detect_container() > 0) 363 if (detect_container() > 0)
364 return; 364 return;
365 365
@@ -372,7 +372,7 @@ diff --git a/src/shared/hibernate-util.c b/src/shared/hibernate-util.c
372index 1213fdc2c7..4c26e6a4ee 100644 372index 1213fdc2c7..4c26e6a4ee 100644
373--- a/src/shared/hibernate-util.c 373--- a/src/shared/hibernate-util.c
374+++ b/src/shared/hibernate-util.c 374+++ b/src/shared/hibernate-util.c
375@@ -495,7 +495,7 @@ int write_resume_config(dev_t devno, uint64_t offset, const char *device) { 375@@ -498,7 +498,7 @@ int write_resume_config(dev_t devno, uint64_t offset, const char *device) {
376 376
377 /* We write the offset first since it's safer. Note that this file is only available in 4.17+, so 377 /* We write the offset first since it's safer. Note that this file is only available in 4.17+, so
378 * fail gracefully if it doesn't exist and we're only overwriting it with 0. */ 378 * fail gracefully if it doesn't exist and we're only overwriting it with 0. */
@@ -381,7 +381,7 @@ index 1213fdc2c7..4c26e6a4ee 100644
381 if (r == -ENOENT) { 381 if (r == -ENOENT) {
382 if (offset != 0) 382 if (offset != 0)
383 return log_error_errno(SYNTHETIC_ERRNO(EOPNOTSUPP), 383 return log_error_errno(SYNTHETIC_ERRNO(EOPNOTSUPP),
384@@ -511,7 +511,7 @@ int write_resume_config(dev_t devno, uint64_t offset, const char *device) { 384@@ -514,7 +514,7 @@ int write_resume_config(dev_t devno, uint64_t offset, const char *device) {
385 log_debug("Wrote resume_offset=%s for device '%s' to /sys/power/resume_offset.", 385 log_debug("Wrote resume_offset=%s for device '%s' to /sys/power/resume_offset.",
386 offset_str, device); 386 offset_str, device);
387 387
diff --git a/meta/recipes-core/systemd/systemd/0014-Handle-missing-gshadow.patch b/meta/recipes-core/systemd/systemd/0014-Handle-missing-gshadow.patch
index 08d4e384ff..0aabae6d82 100644
--- a/meta/recipes-core/systemd/systemd/0014-Handle-missing-gshadow.patch
+++ b/meta/recipes-core/systemd/systemd/0014-Handle-missing-gshadow.patch
@@ -140,7 +140,7 @@ diff --git a/src/shared/userdb.c b/src/shared/userdb.c
140index ff83d4bf90..54d36cc706 100644 140index ff83d4bf90..54d36cc706 100644
141--- a/src/shared/userdb.c 141--- a/src/shared/userdb.c
142+++ b/src/shared/userdb.c 142+++ b/src/shared/userdb.c
143@@ -1041,13 +1041,15 @@ int groupdb_iterator_get(UserDBIterator *iterator, GroupRecord **ret) { 143@@ -1042,13 +1042,15 @@ int groupdb_iterator_get(UserDBIterator *iterator, GroupRecord **ret) {
144 if (gr) { 144 if (gr) {
145 _cleanup_free_ char *buffer = NULL; 145 _cleanup_free_ char *buffer = NULL;
146 bool incomplete = false; 146 bool incomplete = false;
@@ -157,7 +157,7 @@ index ff83d4bf90..54d36cc706 100644
157 if (!FLAGS_SET(iterator->flags, USERDB_SUPPRESS_SHADOW)) { 157 if (!FLAGS_SET(iterator->flags, USERDB_SUPPRESS_SHADOW)) {
158 r = nss_sgrp_for_group(gr, &sgrp, &buffer); 158 r = nss_sgrp_for_group(gr, &sgrp, &buffer);
159 if (r < 0) { 159 if (r < 0) {
160@@ -1060,6 +1062,9 @@ int groupdb_iterator_get(UserDBIterator *iterator, GroupRecord **ret) { 160@@ -1061,6 +1063,9 @@ int groupdb_iterator_get(UserDBIterator *iterator, GroupRecord **ret) {
161 } 161 }
162 162
163 r = nss_group_to_group_record(gr, r >= 0 ? &sgrp : NULL, ret); 163 r = nss_group_to_group_record(gr, r >= 0 ? &sgrp : NULL, ret);
diff --git a/meta/recipes-core/systemd/systemd/0019-errno-util-Make-STRERROR-portable-for-musl.patch b/meta/recipes-core/systemd/systemd/0019-errno-util-Make-STRERROR-portable-for-musl.patch
index 791079a19f..56083cc7b3 100644
--- a/meta/recipes-core/systemd/systemd/0019-errno-util-Make-STRERROR-portable-for-musl.patch
+++ b/meta/recipes-core/systemd/systemd/0019-errno-util-Make-STRERROR-portable-for-musl.patch
@@ -11,8 +11,8 @@ Upstream-Status: Inappropriate [musl specific]
11 11
12Signed-off-by: Khem Raj <raj.khem@gmail.com> 12Signed-off-by: Khem Raj <raj.khem@gmail.com>
13--- 13---
14 src/basic/errno-util.h | 12 ++++++++++-- 14 src/basic/errno-util.h | 10 +++++++++-
15 1 file changed, 10 insertions(+), 2 deletions(-) 15 1 file changed, 9 insertions(+), 1 deletion(-)
16 16
17diff --git a/src/basic/errno-util.h b/src/basic/errno-util.h 17diff --git a/src/basic/errno-util.h b/src/basic/errno-util.h
18index 48b76e4bf7..6e7653e2d9 100644 18index 48b76e4bf7..6e7653e2d9 100644
@@ -23,9 +23,8 @@ index 48b76e4bf7..6e7653e2d9 100644
23 * 23 *
24 * Note that we use the GNU variant of strerror_r() here. */ 24 * Note that we use the GNU variant of strerror_r() here. */
25-#define STRERROR(errnum) strerror_r(abs(errnum), (char[ERRNO_BUF_LEN]){}, ERRNO_BUF_LEN) 25-#define STRERROR(errnum) strerror_r(abs(errnum), (char[ERRNO_BUF_LEN]){}, ERRNO_BUF_LEN)
26-
27+static inline const char * STRERROR(int errnum); 26+static inline const char * STRERROR(int errnum);
28+ 27
29+static inline const char * STRERROR(int errnum) { 28+static inline const char * STRERROR(int errnum) {
30+#ifdef __GLIBC__ 29+#ifdef __GLIBC__
31+ return strerror_r(abs(errnum), (char[ERRNO_BUF_LEN]){}, ERRNO_BUF_LEN); 30+ return strerror_r(abs(errnum), (char[ERRNO_BUF_LEN]){}, ERRNO_BUF_LEN);
diff --git a/meta/recipes-core/systemd/systemd_257.5.bb b/meta/recipes-core/systemd/systemd_257.6.bb
index 995b55580e..995b55580e 100644
--- a/meta/recipes-core/systemd/systemd_257.5.bb
+++ b/meta/recipes-core/systemd/systemd_257.6.bb
diff --git a/meta/recipes-devtools/binutils/binutils-cross.inc b/meta/recipes-devtools/binutils/binutils-cross.inc
index 9c371e7e13..c545ea2ad9 100644
--- a/meta/recipes-devtools/binutils/binutils-cross.inc
+++ b/meta/recipes-devtools/binutils/binutils-cross.inc
@@ -9,6 +9,8 @@ TARGET_ARCH[vardepvalue] = "${TARGET_ARCH}"
9INHIBIT_DEFAULT_DEPS = "1" 9INHIBIT_DEFAULT_DEPS = "1"
10INHIBIT_AUTOTOOLS_DEPS = "1" 10INHIBIT_AUTOTOOLS_DEPS = "1"
11 11
12TOOLCHAIN = "gcc"
13
12SRC_URI += "file://0002-binutils-cross-Do-not-generate-linker-script-directo.patch" 14SRC_URI += "file://0002-binutils-cross-Do-not-generate-linker-script-directo.patch"
13 15
14# Specify lib-path else we use a load of search dirs which we don't use 16# Specify lib-path else we use a load of search dirs which we don't use
diff --git a/meta/recipes-devtools/clang/clang-cross_git.bb b/meta/recipes-devtools/clang/clang-cross_git.bb
index 9b9b120a3d..323cc0d880 100644
--- a/meta/recipes-devtools/clang/clang-cross_git.bb
+++ b/meta/recipes-devtools/clang/clang-cross_git.bb
@@ -11,6 +11,7 @@ PN = "clang-cross-${TARGET_ARCH}"
11require common-clang.inc 11require common-clang.inc
12require common-source.inc 12require common-source.inc
13inherit cross 13inherit cross
14TOOLCHAIN = "clang"
14DEPENDS += "clang-native virtual/cross-binutils" 15DEPENDS += "clang-native virtual/cross-binutils"
15 16
16#INHIBIT_PACKAGE_STRIP = "1" 17#INHIBIT_PACKAGE_STRIP = "1"
diff --git a/meta/recipes-devtools/clang/clang-crosssdk_git.bb b/meta/recipes-devtools/clang/clang-crosssdk_git.bb
index 47ac96f4f9..ef162ef153 100644
--- a/meta/recipes-devtools/clang/clang-crosssdk_git.bb
+++ b/meta/recipes-devtools/clang/clang-crosssdk_git.bb
@@ -11,6 +11,7 @@ PN = "clang-crosssdk-${SDK_SYS}"
11require common-clang.inc 11require common-clang.inc
12require common-source.inc 12require common-source.inc
13inherit crosssdk 13inherit crosssdk
14TOOLCHAIN = "clang"
14DEPENDS += "clang-native nativesdk-clang-glue virtual/nativesdk-cross-binutils virtual/nativesdk-libc" 15DEPENDS += "clang-native nativesdk-clang-glue virtual/nativesdk-cross-binutils virtual/nativesdk-libc"
15 16
16do_install() { 17do_install() {
diff --git a/meta/recipes-devtools/meson/meson_1.8.1.bb b/meta/recipes-devtools/meson/meson_1.8.2.bb
index af4bc9fecd..bfeaab0a79 100644
--- a/meta/recipes-devtools/meson/meson_1.8.1.bb
+++ b/meta/recipes-devtools/meson/meson_1.8.2.bb
@@ -15,7 +15,7 @@ SRC_URI = "${GITHUB_BASE_URI}/download/${PV}/meson-${PV}.tar.gz \
15 file://0001-Make-CPU-family-warnings-fatal.patch \ 15 file://0001-Make-CPU-family-warnings-fatal.patch \
16 file://0002-Support-building-allarch-recipes-again.patch \ 16 file://0002-Support-building-allarch-recipes-again.patch \
17 " 17 "
18SRC_URI[sha256sum] = "b4e3b80e8fa633555abf447a95a700aba1585419467b2710d5e5bf88df0a7011" 18SRC_URI[sha256sum] = "c105816d8158c76b72adcb9ff60297719096da7d07f6b1f000fd8c013cd387af"
19UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)$" 19UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)$"
20 20
21inherit python_setuptools_build_meta github-releases 21inherit python_setuptools_build_meta github-releases
diff --git a/meta/recipes-devtools/python/python3-cython_3.1.1.bb b/meta/recipes-devtools/python/python3-cython_3.1.2.bb
index 1bc6eda4ac..77dbbe8b2c 100644
--- a/meta/recipes-devtools/python/python3-cython_3.1.1.bb
+++ b/meta/recipes-devtools/python/python3-cython_3.1.2.bb
@@ -7,7 +7,7 @@ SECTION = "devel/python"
7LICENSE = "Apache-2.0" 7LICENSE = "Apache-2.0"
8LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=61c3ee8961575861fa86c7e62bc9f69c" 8LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=61c3ee8961575861fa86c7e62bc9f69c"
9 9
10SRC_URI[sha256sum] = "505ccd413669d5132a53834d792c707974248088c4f60c497deb1b416e366397" 10SRC_URI[sha256sum] = "6bbf7a953fa6762dfecdec015e3b054ba51c0121a45ad851fa130f63f5331381"
11 11
12inherit pypi setuptools3 cython 12inherit pypi setuptools3 cython
13 13
diff --git a/meta/recipes-devtools/python/python3-dtschema_2025.2.bb b/meta/recipes-devtools/python/python3-dtschema_2025.6.1.bb
index 2071763741..872084841b 100644
--- a/meta/recipes-devtools/python/python3-dtschema_2025.2.bb
+++ b/meta/recipes-devtools/python/python3-dtschema_2025.6.1.bb
@@ -7,7 +7,7 @@ inherit pypi python_setuptools_build_meta
7 7
8PYPI_PACKAGE = "dtschema" 8PYPI_PACKAGE = "dtschema"
9 9
10SRC_URI[sha256sum] = "9adeaff2079a8b5fbc4bd1c8f02cbd232016a84a9684739cac20b4df3b19509e" 10SRC_URI[sha256sum] = "6348fb23961d0cd1c89ea0c29b790c622bc34fdd1be56090724c6c1f76cbf10d"
11 11
12DEPENDS += "python3-setuptools-scm-native" 12DEPENDS += "python3-setuptools-scm-native"
13RDEPENDS:${PN} += "\ 13RDEPENDS:${PN} += "\
diff --git a/meta/recipes-devtools/python/python3-hypothesis_6.132.0.bb b/meta/recipes-devtools/python/python3-hypothesis_6.135.9.bb
index 52688b8765..efc5229fbc 100644
--- a/meta/recipes-devtools/python/python3-hypothesis_6.132.0.bb
+++ b/meta/recipes-devtools/python/python3-hypothesis_6.135.9.bb
@@ -13,7 +13,7 @@ SRC_URI += " \
13 file://test_rle.py \ 13 file://test_rle.py \
14 " 14 "
15 15
16SRC_URI[sha256sum] = "55868060add41baa6176ed9c3456655678d140c74e3514bdf03381dae6391403" 16SRC_URI[sha256sum] = "a80a256268b8af3d34d62be30f6bf4a7d099b2b762621cc5f3f1de65e7b98543"
17 17
18RDEPENDS:${PN} += " \ 18RDEPENDS:${PN} += " \
19 python3-attrs \ 19 python3-attrs \
diff --git a/meta/recipes-devtools/python/python3-numpy_2.2.6.bb b/meta/recipes-devtools/python/python3-numpy_2.3.0.bb
index 10468d6850..e77a4ba5c3 100644
--- a/meta/recipes-devtools/python/python3-numpy_2.2.6.bb
+++ b/meta/recipes-devtools/python/python3-numpy_2.3.0.bb
@@ -3,7 +3,7 @@ HOMEPAGE = "https://numpy.org/"
3DESCRIPTION = "NumPy is the fundamental package needed for scientific computing with Python." 3DESCRIPTION = "NumPy is the fundamental package needed for scientific computing with Python."
4SECTION = "devel/python" 4SECTION = "devel/python"
5LICENSE = "BSD-3-Clause & BSD-2-Clause & PSF-2.0 & Apache-2.0 & MIT" 5LICENSE = "BSD-3-Clause & BSD-2-Clause & PSF-2.0 & Apache-2.0 & MIT"
6LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=1de863c37a83e71b1e97b64d036ea78b" 6LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=26080bf81b2662c7119d3ef28ae197fd"
7 7
8SRCNAME = "numpy" 8SRCNAME = "numpy"
9 9
@@ -12,7 +12,7 @@ SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/${SRCNAME}-${PV}.tar.gz \
12 file://fix_reproducibility.patch \ 12 file://fix_reproducibility.patch \
13 file://run-ptest \ 13 file://run-ptest \
14 " 14 "
15SRC_URI[sha256sum] = "e29554e2bef54a90aa5cc07da6ce955accb83f21ab5de01a62c8478897b264fd" 15SRC_URI[sha256sum] = "581f87f9e9e9db2cba2141400e160e9dd644ee248788d6f90636eeb8fd9260a6"
16 16
17GITHUB_BASE_URI = "https://github.com/numpy/numpy/releases" 17GITHUB_BASE_URI = "https://github.com/numpy/numpy/releases"
18UPSTREAM_CHECK_REGEX = "releases/tag/v?(?P<pver>\d+(\.\d+)+)$" 18UPSTREAM_CHECK_REGEX = "releases/tag/v?(?P<pver>\d+(\.\d+)+)$"
diff --git a/meta/recipes-devtools/python/python3-pdm_2.24.2.bb b/meta/recipes-devtools/python/python3-pdm_2.25.1.bb
index d24e03d650..d9331ba72c 100644
--- a/meta/recipes-devtools/python/python3-pdm_2.24.2.bb
+++ b/meta/recipes-devtools/python/python3-pdm_2.25.1.bb
@@ -4,7 +4,7 @@ LICENSE = "MIT"
4SECTION = "devel/python" 4SECTION = "devel/python"
5LIC_FILES_CHKSUM = "file://LICENSE;md5=2eb31a2cc1a758c34b499f287dd04ef2" 5LIC_FILES_CHKSUM = "file://LICENSE;md5=2eb31a2cc1a758c34b499f287dd04ef2"
6 6
7SRC_URI[sha256sum] = "ce0d5e9005fe26238b8ba5cf0e37ac00acab2fb90f904bf0219a5e8445849dfb" 7SRC_URI[sha256sum] = "3145251f37a3f94fa211ade992e7db7792da4c3e8e3eeeb1993d952adebe0b96"
8 8
9inherit pypi python_setuptools_build_meta 9inherit pypi python_setuptools_build_meta
10 10
diff --git a/meta/recipes-devtools/python/python3-requests_2.32.3.bb b/meta/recipes-devtools/python/python3-requests_2.32.4.bb
index bc9b2289f6..49d44298f6 100644
--- a/meta/recipes-devtools/python/python3-requests_2.32.3.bb
+++ b/meta/recipes-devtools/python/python3-requests_2.32.4.bb
@@ -7,7 +7,7 @@ SRC_URI:append:class-nativesdk = " \
7 file://environment.d-python3-requests.sh \ 7 file://environment.d-python3-requests.sh \
8" 8"
9 9
10SRC_URI[sha256sum] = "55365417734eb18255590a9ff9eb97e9e1da868d4ccd6402399eaf68af20a760" 10SRC_URI[sha256sum] = "27d0316682c8a29834d3264820024b62a36942083d52caf2f14c0591336d3422"
11 11
12inherit pypi python_setuptools_build_meta 12inherit pypi python_setuptools_build_meta
13 13
diff --git a/meta/recipes-devtools/python/python3-ruamel-yaml_0.18.12.bb b/meta/recipes-devtools/python/python3-ruamel-yaml_0.18.14.bb
index 3b136b3b58..e7ac24abb8 100644
--- a/meta/recipes-devtools/python/python3-ruamel-yaml_0.18.12.bb
+++ b/meta/recipes-devtools/python/python3-ruamel-yaml_0.18.14.bb
@@ -9,7 +9,7 @@ UPSTREAM_CHECK_PYPI_PACKAGE = "${PYPI_PACKAGE}"
9 9
10inherit pypi python_setuptools_build_meta 10inherit pypi python_setuptools_build_meta
11 11
12SRC_URI[sha256sum] = "5a38fd5ce39d223bebb9e3a6779e86b9427a03fb0bf9f270060f8b149cffe5e2" 12SRC_URI[sha256sum] = "7227b76aaec364df15936730efbf7d72b30c0b79b1d578bbb8e3dcb2d81f52b7"
13 13
14RDEPENDS:${PN} += "\ 14RDEPENDS:${PN} += "\
15 python3-shell \ 15 python3-shell \
diff --git a/meta/recipes-devtools/python/python3-typing-extensions_4.13.2.bb b/meta/recipes-devtools/python/python3-typing-extensions_4.14.0.bb
index 9c83ae6c61..1c03aacc10 100644
--- a/meta/recipes-devtools/python/python3-typing-extensions_4.13.2.bb
+++ b/meta/recipes-devtools/python/python3-typing-extensions_4.14.0.bb
@@ -16,7 +16,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=fcf6b249c2641540219a727f35d8d2c2"
16PYPI_PACKAGE = "typing_extensions" 16PYPI_PACKAGE = "typing_extensions"
17UPSTREAM_CHECK_PYPI_PACKAGE = "${PYPI_PACKAGE}" 17UPSTREAM_CHECK_PYPI_PACKAGE = "${PYPI_PACKAGE}"
18 18
19SRC_URI[sha256sum] = "e6c81219bd689f51865d9e372991c540bda33a0379d5573cddb9a3a23f7caaef" 19SRC_URI[sha256sum] = "8676b788e32f02ab42d9e7c61324048ae4c6d844a399eebace3d4979d75ceef4"
20 20
21inherit pypi python_flit_core 21inherit pypi python_flit_core
22 22
diff --git a/meta/recipes-devtools/repo/repo_2.55.bb b/meta/recipes-devtools/repo/repo_2.55.2.bb
index 5fea49abb3..9cff3c0b7c 100644
--- a/meta/recipes-devtools/repo/repo_2.55.bb
+++ b/meta/recipes-devtools/repo/repo_2.55.2.bb
@@ -11,7 +11,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
11 11
12SRC_URI = "git://gerrit.googlesource.com/git-repo.git;protocol=https;branch=main;tag=v${PV} \ 12SRC_URI = "git://gerrit.googlesource.com/git-repo.git;protocol=https;branch=main;tag=v${PV} \
13 " 13 "
14SRCREV = "08815ad3eb245872700201e03c47cb504d1dc3f9" 14SRCREV = "b262d0e4619c406a2708856ed312091d21c5bf39"
15 15
16MIRRORS += "git://gerrit.googlesource.com/git-repo.git git://github.com/GerritCodeReview/git-repo.git" 16MIRRORS += "git://gerrit.googlesource.com/git-repo.git git://github.com/GerritCodeReview/git-repo.git"
17 17
diff --git a/meta/recipes-extended/libsolv/libsolv_0.7.32.bb b/meta/recipes-extended/libsolv/libsolv_0.7.33.bb
index 71786e40dc..7584251420 100644
--- a/meta/recipes-extended/libsolv/libsolv_0.7.32.bb
+++ b/meta/recipes-extended/libsolv/libsolv_0.7.33.bb
@@ -12,7 +12,7 @@ SRC_URI = "git://github.com/openSUSE/libsolv.git;branch=master;protocol=https \
12 file://0001-utils-Conside-musl-when-wrapping-qsort_r.patch \ 12 file://0001-utils-Conside-musl-when-wrapping-qsort_r.patch \
13" 13"
14 14
15SRCREV = "95f64952e3270deb6be30ae4b786cae5c114c807" 15SRCREV = "9fb855d872139fb1ebebec4c892b338fccda69ba"
16 16
17UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)" 17UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+(\.\d+)+)"
18 18
diff --git a/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-01.patch b/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-01.patch
new file mode 100644
index 0000000000..0d55512497
--- /dev/null
+++ b/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-01.patch
@@ -0,0 +1,91 @@
1From 7a8f42fb20013a1493d8cae1c43436f85e656f2d Mon Sep 17 00:00:00 2001
2From: Zephkeks <zephyrofficialdiscord@gmail.com>
3Date: Tue, 13 May 2025 11:04:17 +0200
4Subject: [PATCH] CVE-2025-46836: interface.c: Stack-based Buffer Overflow in
5 get_name()
6
7Coordinated as GHSA-pfwf-h6m3-63wf
8
9CVE: CVE-2025-46836
10Upstream-Status: Backport [https://sourceforge.net/p/net-tools/code/ci/7a8f42fb20013a1493d8cae1c43436f85e656f2d/]
11Signed-off-by: Peter Marko <peter.marko@siemens.com>
12---
13 lib/interface.c | 63 ++++++++++++++++++++++++++++++-------------------
14 1 file changed, 39 insertions(+), 24 deletions(-)
15
16diff --git a/lib/interface.c b/lib/interface.c
17index 71d4163..a054f12 100644
18--- a/lib/interface.c
19+++ b/lib/interface.c
20@@ -211,32 +211,47 @@ out:
21 }
22
23 static const char *get_name(char *name, const char *p)
24+/* Safe version — guarantees at most IFNAMSIZ‑1 bytes are copied
25+ and the destination buffer is always NUL‑terminated. */
26 {
27- while (isspace(*p))
28- p++;
29- while (*p) {
30- if (isspace(*p))
31- break;
32- if (*p == ':') { /* could be an alias */
33- const char *dot = p++;
34- while (*p && isdigit(*p)) p++;
35- if (*p == ':') {
36- /* Yes it is, backup and copy it. */
37- p = dot;
38- *name++ = *p++;
39- while (*p && isdigit(*p)) {
40- *name++ = *p++;
41- }
42- } else {
43- /* No, it isn't */
44- p = dot;
45- }
46- p++;
47- break;
48- }
49- *name++ = *p++;
50+ char *dst = name; /* current write ptr */
51+ const char *end = name + IFNAMSIZ - 1; /* last byte we may write */
52+
53+ /* Skip leading white‑space. */
54+ while (isspace((unsigned char)*p))
55+ ++p;
56+
57+ /* Copy until white‑space, end of string, or buffer full. */
58+ while (*p && !isspace((unsigned char)*p) && dst < end) {
59+ if (*p == ':') { /* possible alias veth0:123: */
60+ const char *dot = p; /* remember the colon */
61+ ++p;
62+ while (*p && isdigit((unsigned char)*p))
63+ ++p;
64+
65+ if (*p == ':') { /* confirmed alias */
66+ p = dot; /* rewind and copy it all */
67+
68+ /* copy the colon */
69+ if (dst < end)
70+ *dst++ = *p++;
71+
72+ /* copy the digits */
73+ while (*p && isdigit((unsigned char)*p) && dst < end)
74+ *dst++ = *p++;
75+
76+ if (*p == ':') /* consume trailing colon */
77+ ++p;
78+ } else { /* if so treat as normal */
79+ p = dot;
80+ }
81+ break; /* interface name ends here */
82+ }
83+
84+ *dst++ = *p++; /* ordinary character copy */
85 }
86- *name++ = '\0';
87+
88+ *dst = '\0'; /* always NUL‑terminate */
89 return p;
90 }
91
diff --git a/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-02.patch b/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-02.patch
new file mode 100644
index 0000000000..d2c3673a24
--- /dev/null
+++ b/meta/recipes-extended/net-tools/net-tools/CVE-2025-46836-02.patch
@@ -0,0 +1,31 @@
1From ddb0e375fb9ca95bb69335540b85bbdaa2714348 Mon Sep 17 00:00:00 2001
2From: Bernd Eckenfels <net-tools@lina.inka.de>
3Date: Sat, 17 May 2025 21:53:23 +0200
4Subject: [PATCH] Interface statistic regression after 7a8f42fb2
5
6CVE: CVE-2025-46836
7Upstream-Status: Backport [https://sourceforge.net/p/net-tools/code/ci/ddb0e375fb9ca95bb69335540b85bbdaa2714348/]
8Signed-off-by: Peter Marko <peter.marko@siemens.com>
9---
10 lib/interface.c | 5 ++---
11 1 file changed, 2 insertions(+), 3 deletions(-)
12
13diff --git a/lib/interface.c b/lib/interface.c
14index a054f12..ca4adf1 100644
15--- a/lib/interface.c
16+++ b/lib/interface.c
17@@ -239,12 +239,11 @@ static const char *get_name(char *name, const char *p)
18 /* copy the digits */
19 while (*p && isdigit((unsigned char)*p) && dst < end)
20 *dst++ = *p++;
21-
22- if (*p == ':') /* consume trailing colon */
23- ++p;
24 } else { /* if so treat as normal */
25 p = dot;
26 }
27+ if (*p == ':') /* consume trailing colon */
28+ ++p;
29 break; /* interface name ends here */
30 }
31
diff --git a/meta/recipes-extended/net-tools/net-tools_2.10.bb b/meta/recipes-extended/net-tools/net-tools_2.10.bb
index 7facc0cc8d..547079f4cf 100644
--- a/meta/recipes-extended/net-tools/net-tools_2.10.bb
+++ b/meta/recipes-extended/net-tools/net-tools_2.10.bb
@@ -11,6 +11,8 @@ SRC_URI = "git://git.code.sf.net/p/net-tools/code;protocol=https;branch=master \
11 file://net-tools-config.h \ 11 file://net-tools-config.h \
12 file://net-tools-config.make \ 12 file://net-tools-config.make \
13 file://Add_missing_headers.patch \ 13 file://Add_missing_headers.patch \
14 file://CVE-2025-46836-01.patch \
15 file://CVE-2025-46836-02.patch \
14" 16"
15 17
16S = "${WORKDIR}/git" 18S = "${WORKDIR}/git"
diff --git a/meta/recipes-gnome/gtk+/gtk4_4.18.5.bb b/meta/recipes-gnome/gtk+/gtk4_4.18.6.bb
index 85773b1174..092f8d309f 100644
--- a/meta/recipes-gnome/gtk+/gtk4_4.18.5.bb
+++ b/meta/recipes-gnome/gtk+/gtk4_4.18.6.bb
@@ -38,7 +38,7 @@ MAJ_VER = "${@oe.utils.trim_version("${PV}", 2)}"
38UPSTREAM_CHECK_REGEX = "gtk-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)\.tar.xz" 38UPSTREAM_CHECK_REGEX = "gtk-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)\.tar.xz"
39 39
40SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk/${MAJ_VER}/gtk-${PV}.tar.xz" 40SRC_URI = "http://ftp.gnome.org/pub/gnome/sources/gtk/${MAJ_VER}/gtk-${PV}.tar.xz"
41SRC_URI[sha256sum] = "bb5267a062f5936947d34c9999390a674b0b2b0d8aa3472fe0d05e2064955abc" 41SRC_URI[sha256sum] = "e1817c650ddc3261f9a8345b3b22a26a5d80af154630dedc03cc7becefffd0fa"
42 42
43S = "${WORKDIR}/gtk-${PV}" 43S = "${WORKDIR}/gtk-${PV}"
44 44
diff --git a/meta/recipes-graphics/drm/libdrm_2.4.124.bb b/meta/recipes-graphics/drm/libdrm_2.4.125.bb
index 78f31ccb95..a256f73145 100644
--- a/meta/recipes-graphics/drm/libdrm_2.4.124.bb
+++ b/meta/recipes-graphics/drm/libdrm_2.4.125.bb
@@ -13,7 +13,7 @@ DEPENDS = "libpthread-stubs"
13SRC_URI = "http://dri.freedesktop.org/libdrm/${BP}.tar.xz \ 13SRC_URI = "http://dri.freedesktop.org/libdrm/${BP}.tar.xz \
14 " 14 "
15 15
16SRC_URI[sha256sum] = "ac36293f61ca4aafaf4b16a2a7afff312aa4f5c37c9fbd797de9e3c0863ca379" 16SRC_URI[sha256sum] = "d4bae92797a50f81a93524762e0410a49cd84cfa0f997795bc0172ac8fb1d96a"
17 17
18inherit meson pkgconfig manpages 18inherit meson pkgconfig manpages
19 19
diff --git a/meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.0.bb b/meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.1.bb
index a5f1932a90..2b39a4c1d9 100644
--- a/meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.0.bb
+++ b/meta/recipes-graphics/jpeg/libjpeg-turbo_3.1.1.bb
@@ -9,7 +9,7 @@ DEPENDS:append:x86-64:class-target = " nasm-native"
9DEPENDS:append:x86:class-target = " nasm-native" 9DEPENDS:append:x86:class-target = " nasm-native"
10 10
11SRC_URI = "${GITHUB_BASE_URI}/download/${PV}/${BP}.tar.gz" 11SRC_URI = "${GITHUB_BASE_URI}/download/${PV}/${BP}.tar.gz"
12SRC_URI[sha256sum] = "9564c72b1dfd1d6fe6274c5f95a8d989b59854575d4bbee44ade7bc17aa9bc93" 12SRC_URI[sha256sum] = "aadc97ea91f6ef078b0ae3a62bba69e008d9a7db19b34e4ac973b19b71b4217c"
13 13
14PE = "1" 14PE = "1"
15 15
diff --git a/meta/recipes-graphics/libsdl2/libsdl2_2.32.6.bb b/meta/recipes-graphics/libsdl2/libsdl2_2.32.8.bb
index 75710b962a..57758de8b3 100644
--- a/meta/recipes-graphics/libsdl2/libsdl2_2.32.6.bb
+++ b/meta/recipes-graphics/libsdl2/libsdl2_2.32.8.bb
@@ -25,7 +25,7 @@ SRC_URI = "http://www.libsdl.org/release/SDL2-${PV}.tar.gz"
25 25
26S = "${WORKDIR}/SDL2-${PV}" 26S = "${WORKDIR}/SDL2-${PV}"
27 27
28SRC_URI[sha256sum] = "6a7a40d6c2e00016791815e1a9f4042809210bdf10cc78d2c75b45c4f52f93ad" 28SRC_URI[sha256sum] = "0ca83e9c9b31e18288c7ec811108e58bac1f1bb5ec6577ad386830eac51c787e"
29 29
30inherit cmake lib_package binconfig-disabled pkgconfig upstream-version-is-even 30inherit cmake lib_package binconfig-disabled pkgconfig upstream-version-is-even
31UPSTREAM_CHECK_REGEX = "SDL2-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)\.tar" 31UPSTREAM_CHECK_REGEX = "SDL2-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)\.tar"
diff --git a/meta/recipes-graphics/mesa/mesa.inc b/meta/recipes-graphics/mesa/mesa.inc
index b222e72fdd..56ac18ea53 100644
--- a/meta/recipes-graphics/mesa/mesa.inc
+++ b/meta/recipes-graphics/mesa/mesa.inc
@@ -93,10 +93,10 @@ PACKAGECONFIG = " \
93# skip all Rust dependencies if we are not building OpenCL" 93# skip all Rust dependencies if we are not building OpenCL"
94INHIBIT_DEFAULT_RUST_DEPS = "${@bb.utils.contains('PACKAGECONFIG', 'opencl', '', '1', d)}" 94INHIBIT_DEFAULT_RUST_DEPS = "${@bb.utils.contains('PACKAGECONFIG', 'opencl', '', '1', d)}"
95 95
96PACKAGECONFIG:append:x86 = " libclc gallium-llvm intel amd svga" 96PACKAGECONFIG:append:x86 = " libclc gallium-llvm intel amd nouveau svga"
97PACKAGECONFIG:append:x86-64 = " libclc gallium-llvm intel amd svga" 97PACKAGECONFIG:append:x86-64 = " libclc gallium-llvm intel amd nouveau svga"
98PACKAGECONFIG:append:i686 = " libclc gallium-llvm intel amd svga" 98PACKAGECONFIG:append:i686 = " libclc gallium-llvm intel amd nouveau svga"
99PACKAGECONFIG:append:class-native = " libclc gallium-llvm amd svga" 99PACKAGECONFIG:append:class-native = " libclc gallium-llvm amd nouveau svga"
100 100
101# "gbm" requires "opengl" 101# "gbm" requires "opengl"
102PACKAGECONFIG[gbm] = "-Dgbm=enabled,-Dgbm=disabled" 102PACKAGECONFIG[gbm] = "-Dgbm=enabled,-Dgbm=disabled"
@@ -171,15 +171,18 @@ GALLIUMDRIVERS:append = "${@bb.utils.contains('PACKAGECONFIG', 'v3d', ',v3d', ''
171GALLIUMDRIVERS:append = "${@bb.utils.contains('PACKAGECONFIG', 'zink', ',zink', '', d)}" 171GALLIUMDRIVERS:append = "${@bb.utils.contains('PACKAGECONFIG', 'zink', ',zink', '', d)}"
172 172
173GALLIUMDRIVERS_ASAHI = "${@bb.utils.contains('PACKAGECONFIG', 'asahi libclc opencl', ',asahi', '', d)}" 173GALLIUMDRIVERS_ASAHI = "${@bb.utils.contains('PACKAGECONFIG', 'asahi libclc opencl', ',asahi', '', d)}"
174GALLIUMDRIVERS_AMD = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',r300', '', d)}"
174GALLIUMDRIVERS_IRIS = "${@bb.utils.contains('PACKAGECONFIG', 'intel libclc', ',iris', '', d)}" 175GALLIUMDRIVERS_IRIS = "${@bb.utils.contains('PACKAGECONFIG', 'intel libclc', ',iris', '', d)}"
176GALLIUMDRIVERS_NOUVEAU = "${@bb.utils.contains('PACKAGECONFIG', 'nouveau', ',nouveau', '', d)}"
175GALLIUMDRIVERS_RADEONSI = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',radeonsi', '', d)}" 177GALLIUMDRIVERS_RADEONSI = "${@bb.utils.contains('PACKAGECONFIG', 'amd', ',radeonsi', '', d)}"
176GALLIUMDRIVERS_LLVMPIPE = ",llvmpipe" 178GALLIUMDRIVERS_LLVMPIPE = ",llvmpipe"
177# llvmpipe crashes on x32 179# llvmpipe crashes on x32
178GALLIUMDRIVERS_LLVMPIPE:x86-x32 = "" 180GALLIUMDRIVERS_LLVMPIPE:x86-x32 = ""
179GALLIUMDRIVERS_SVGA = "${@bb.utils.contains('PACKAGECONFIG', 'svga', ',svga', '', d)}" 181GALLIUMDRIVERS_SVGA = "${@bb.utils.contains('PACKAGECONFIG', 'svga', ',svga', '', d)}"
180GALLIUMDRIVERS_LLVM = ",r300,nouveau${GALLIUMDRIVERS_LLVMPIPE}${GALLIUMDRIVERS_ASAHI}${GALLIUMDRIVERS_IRIS}${GALLIUMDRIVERS_RADEONSI}${GALLIUMDRIVERS_SVGA}" 182GALLIUMDRIVERS_LLVM = "${GALLIUMDRIVERS_LLVMPIPE}${GALLIUMDRIVERS_AMD}${GALLIUMDRIVERS_ASAHI}${GALLIUMDRIVERS_IRIS}${GALLIUMDRIVERS_NOUVEAU}${GALLIUMDRIVERS_RADEONSI}${GALLIUMDRIVERS_SVGA}"
181 183
182PACKAGECONFIG[amd] = "" 184PACKAGECONFIG[amd] = ""
185PACKAGECONFIG[nouveau] = ""
183PACKAGECONFIG[svga] = "" 186PACKAGECONFIG[svga] = ""
184PACKAGECONFIG[virgl] = "" 187PACKAGECONFIG[virgl] = ""
185 188
diff --git a/meta/recipes-graphics/wayland/wayland-protocols_1.44.bb b/meta/recipes-graphics/wayland/wayland-protocols_1.45.bb
index c86f09eb7c..d98ccf964f 100644
--- a/meta/recipes-graphics/wayland/wayland-protocols_1.44.bb
+++ b/meta/recipes-graphics/wayland/wayland-protocols_1.45.bb
@@ -10,7 +10,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=c7b12b6702da38ca028ace54aae3d484 \
10 file://stable/presentation-time/presentation-time.xml;endline=26;md5=4646cd7d9edc9fa55db941f2d3a7dc53" 10 file://stable/presentation-time/presentation-time.xml;endline=26;md5=4646cd7d9edc9fa55db941f2d3a7dc53"
11 11
12SRC_URI = "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/${PV}/downloads/wayland-protocols-${PV}.tar.xz" 12SRC_URI = "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/${PV}/downloads/wayland-protocols-${PV}.tar.xz"
13SRC_URI[sha256sum] = "3df1107ecf8bfd6ee878aeca5d3b7afd81248a48031e14caf6ae01f14eebb50e" 13SRC_URI[sha256sum] = "4d2b2a9e3e099d017dc8107bf1c334d27bb87d9e4aff19a0c8d856d17cd41ef0"
14 14
15UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/tags" 15UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/tags"
16UPSTREAM_CHECK_REGEX = "releases/(?P<pver>.+)" 16UPSTREAM_CHECK_REGEX = "releases/(?P<pver>.+)"
diff --git a/meta/recipes-graphics/wayland/weston_14.0.1.bb b/meta/recipes-graphics/wayland/weston_14.0.2.bb
index 2a0a403d99..03b49d730e 100644
--- a/meta/recipes-graphics/wayland/weston_14.0.1.bb
+++ b/meta/recipes-graphics/wayland/weston_14.0.2.bb
@@ -13,7 +13,7 @@ SRC_URI = "https://gitlab.freedesktop.org/wayland/weston/-/releases/${PV}/downlo
13 file://systemd-notify.weston-start \ 13 file://systemd-notify.weston-start \
14 " 14 "
15 15
16SRC_URI[sha256sum] = "a8150505b126a59df781fe8c30c8e6f87da7013e179039eb844a5bbbcc7c79b3" 16SRC_URI[sha256sum] = "b47216b3530da76d02a3a1acbf1846a9cd41d24caa86448f9c46f78f20b6e0ac"
17 17
18UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/weston/-/tags" 18UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/weston/-/tags"
19UPSTREAM_CHECK_REGEX = "releases/(?P<pver>\d+\.\d+\.(?!9\d+)\d+)" 19UPSTREAM_CHECK_REGEX = "releases/(?P<pver>\d+\.\d+\.(?!9\d+)\d+)"
@@ -92,7 +92,7 @@ PACKAGECONFIG[image-jpeg] = "-Dimage-jpeg=true,-Dimage-jpeg=false, jpeg"
92# screencasting via PipeWire 92# screencasting via PipeWire
93PACKAGECONFIG[pipewire] = "-Dbackend-pipewire=true,-Dbackend-pipewire=false,pipewire" 93PACKAGECONFIG[pipewire] = "-Dbackend-pipewire=true,-Dbackend-pipewire=false,pipewire"
94# VNC remote screensharing 94# VNC remote screensharing
95PACKAGECONFIG[vnc] = "-Dbackend-vnc=true,-Dbackend-vnc=false,neatvnc" 95PACKAGECONFIG[vnc] = "-Dbackend-vnc=true,-Dbackend-vnc=false,neatvnc libpam"
96 96
97 97
98do_install:append() { 98do_install:append() {
diff --git a/meta/recipes-graphics/xorg-lib/pixman_0.46.0.bb b/meta/recipes-graphics/xorg-lib/pixman_0.46.2.bb
index c1c71fd420..71c7f9a98d 100644
--- a/meta/recipes-graphics/xorg-lib/pixman_0.46.0.bb
+++ b/meta/recipes-graphics/xorg-lib/pixman_0.46.2.bb
@@ -8,7 +8,7 @@ SECTION = "x11/libs"
8DEPENDS = "zlib" 8DEPENDS = "zlib"
9 9
10SRC_URI = "https://www.cairographics.org/releases/${BP}.tar.gz" 10SRC_URI = "https://www.cairographics.org/releases/${BP}.tar.gz"
11SRC_URI[sha256sum] = "02d9ff7b8458ef61731c3d355f854bbf461fd0a4d3563c51f1c1c7b00638050d" 11SRC_URI[sha256sum] = "3e0de5ba6e356916946a3d958192f15505dcab85134771bfeab4ce4e29bbd733"
12 12
13# see http://cairographics.org/releases/ - only even minor versions are stable 13# see http://cairographics.org/releases/ - only even minor versions are stable
14UPSTREAM_CHECK_REGEX = "pixman-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)" 14UPSTREAM_CHECK_REGEX = "pixman-(?P<pver>\d+\.(\d*[02468])+(\.\d+)+)"
diff --git a/meta/recipes-kernel/lttng/lttng-modules_2.13.18.bb b/meta/recipes-kernel/lttng/lttng-modules_2.13.19.bb
index 1b2327f609..63ba488515 100644
--- a/meta/recipes-kernel/lttng/lttng-modules_2.13.18.bb
+++ b/meta/recipes-kernel/lttng/lttng-modules_2.13.19.bb
@@ -17,7 +17,7 @@ SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \
17SRC_URI:append = " file://0001-src-Kbuild-change-missing-CONFIG_TRACEPOINTS-to-warn.patch \ 17SRC_URI:append = " file://0001-src-Kbuild-change-missing-CONFIG_TRACEPOINTS-to-warn.patch \
18 " 18 "
19 19
20SRC_URI[sha256sum] = "a2f38e289817dbd1d2f12cfc1f20390230e16d56323cb58cc1db9874ced400ed" 20SRC_URI[sha256sum] = "06d704633749039f8fa72a954bec6486058386e2a0c3557b22c484698f9b34d5"
21 21
22export INSTALL_MOD_DIR = "kernel/lttng-modules" 22export INSTALL_MOD_DIR = "kernel/lttng-modules"
23 23
diff --git a/meta/recipes-multimedia/libtheora/libtheora_1.2.0.bb b/meta/recipes-multimedia/libtheora/libtheora_1.2.0.bb
index 361d2c6e4a..1a1b5fce06 100644
--- a/meta/recipes-multimedia/libtheora/libtheora_1.2.0.bb
+++ b/meta/recipes-multimedia/libtheora/libtheora_1.2.0.bb
@@ -19,6 +19,11 @@ inherit autotools pkgconfig
19 19
20EXTRA_OECONF = "--disable-examples --disable-doc" 20EXTRA_OECONF = "--disable-examples --disable-doc"
21 21
22# theora 1.2.0 has broken 32-bit arm assembler, see:
23# https://gitlab.xiph.org/xiph/theora/-/issues/2339
24# https://gitlab.xiph.org/xiph/theora/-/issues/2340
25EXTRA_OECONF:append:arm = " --disable-asm"
26
22# these old architectures don't support all the instructions from the asm source files 27# these old architectures don't support all the instructions from the asm source files
23EXTRA_OECONF:append:armv4 = " --disable-asm " 28EXTRA_OECONF:append:armv4 = " --disable-asm "
24EXTRA_OECONF:append:armv5 = " --disable-asm " 29EXTRA_OECONF:append:armv5 = " --disable-asm "
diff --git a/meta/recipes-multimedia/mpg123/mpg123_1.32.10.bb b/meta/recipes-multimedia/mpg123/mpg123_1.33.0.bb
index d559bc6417..2905bf0abc 100644
--- a/meta/recipes-multimedia/mpg123/mpg123_1.32.10.bb
+++ b/meta/recipes-multimedia/mpg123/mpg123_1.33.0.bb
@@ -10,7 +10,7 @@ LICENSE = "LGPL-2.1-only"
10LIC_FILES_CHKSUM = "file://COPYING;md5=e7b9c15fcfb986abb4cc5e8400a24169" 10LIC_FILES_CHKSUM = "file://COPYING;md5=e7b9c15fcfb986abb4cc5e8400a24169"
11 11
12SRC_URI = "https://www.mpg123.de/download/${BP}.tar.bz2" 12SRC_URI = "https://www.mpg123.de/download/${BP}.tar.bz2"
13SRC_URI[sha256sum] = "87b2c17fe0c979d3ef38eeceff6362b35b28ac8589fbf1854b5be75c9ab6557c" 13SRC_URI[sha256sum] = "2290e3aede6f4d163e1a17452165af33caad4b5f0948f99429cfa2d8385faa9d"
14 14
15UPSTREAM_CHECK_REGEX = "mpg123-(?P<pver>\d+(\.\d+)+)\.tar" 15UPSTREAM_CHECK_REGEX = "mpg123-(?P<pver>\d+(\.\d+)+)\.tar"
16 16
diff --git a/meta/recipes-support/debianutils/debianutils_5.22.bb b/meta/recipes-support/debianutils/debianutils_5.23.1.bb
index f5deead51a..85955883a4 100644
--- a/meta/recipes-support/debianutils/debianutils_5.22.bb
+++ b/meta/recipes-support/debianutils/debianutils_5.23.1.bb
@@ -11,7 +11,7 @@ LIC_FILES_CHKSUM = "file://debian/copyright;md5=4b667f30411d21bc8fd7db85d502a8e9
11SRC_URI = "git://salsa.debian.org/debian/debianutils.git;protocol=https;branch=master;tag=debian/${PV} \ 11SRC_URI = "git://salsa.debian.org/debian/debianutils.git;protocol=https;branch=master;tag=debian/${PV} \
12 " 12 "
13 13
14SRCREV = "528fac5c7448989f33c54599ae6e4c2b84d41e21" 14SRCREV = "ab0eaf33b783ba578773af2557753d2b973ba5bb"
15 15
16inherit autotools update-alternatives 16inherit autotools update-alternatives
17 17
diff --git a/meta/recipes-support/diffoscope/diffoscope_297.bb b/meta/recipes-support/diffoscope/diffoscope_298.bb
index 6f6f4ac520..4a50059c99 100644
--- a/meta/recipes-support/diffoscope/diffoscope_297.bb
+++ b/meta/recipes-support/diffoscope/diffoscope_298.bb
@@ -12,7 +12,7 @@ PYPI_PACKAGE = "diffoscope"
12 12
13inherit pypi setuptools3 13inherit pypi setuptools3
14 14
15SRC_URI[sha256sum] = "25532061c640b4be7496f9a726640e20ca0fcb8e46a8a1a46e51ac940a5f4e57" 15SRC_URI[sha256sum] = "9644b7e711df71f13c5f50f3d1353c1e6d09f462d342d9771576e75f3dd8c3e1"
16 16
17RDEPENDS:${PN} += "\ 17RDEPENDS:${PN} += "\
18 binutils \ 18 binutils \
diff --git a/meta/recipes-support/hwdata/hwdata_0.395.bb b/meta/recipes-support/hwdata/hwdata_0.396.bb
index 73b846b181..291a4ef85d 100644
--- a/meta/recipes-support/hwdata/hwdata_0.395.bb
+++ b/meta/recipes-support/hwdata/hwdata_0.396.bb
@@ -8,7 +8,7 @@ LICENSE = "GPL-2.0-or-later | X11"
8LIC_FILES_CHKSUM = "file://LICENSE;md5=1556547711e8246992b999edd9445a57" 8LIC_FILES_CHKSUM = "file://LICENSE;md5=1556547711e8246992b999edd9445a57"
9 9
10SRC_URI = "git://github.com/vcrhonek/${BPN}.git;branch=master;protocol=https;tag=v${PV}" 10SRC_URI = "git://github.com/vcrhonek/${BPN}.git;branch=master;protocol=https;tag=v${PV}"
11SRCREV = "95c1de6c4a0d40415867b29c0791480fb8ad3cdb" 11SRCREV = "736513dfc1d44c5fb48bead62af7e91c4e1d1dd2"
12 12
13S = "${WORKDIR}/git" 13S = "${WORKDIR}/git"
14 14
diff --git a/meta/recipes-support/libcheck/libcheck_0.15.2.bb b/meta/recipes-support/libcheck/libcheck_0.15.2.bb
index 5ab67b8728..8455f2c748 100644
--- a/meta/recipes-support/libcheck/libcheck_0.15.2.bb
+++ b/meta/recipes-support/libcheck/libcheck_0.15.2.bb
@@ -18,15 +18,16 @@ GITHUB_BASE_URI = "https://github.com/libcheck/check/releases/"
18 18
19S = "${WORKDIR}/check-${PV}" 19S = "${WORKDIR}/check-${PV}"
20 20
21inherit autotools pkgconfig texinfo github-releases 21inherit cmake pkgconfig texinfo github-releases
22
23CACHED_CONFIGUREVARS += "ac_cv_path_AWK_PATH=${bindir}/gawk"
24 22
25RREPLACES:${PN} = "check (<= 0.9.5)" 23RREPLACES:${PN} = "check (<= 0.9.5)"
26 24
25EXTRA_OECMAKE:append:class-target = " -DAWK_PATH=${bindir}/awk"
26
27do_install:append:class-native() { 27do_install:append:class-native() {
28 create_cmdline_shebang_wrapper ${D}${bindir}/checkmk 28 create_cmdline_shebang_wrapper ${D}${bindir}/checkmk
29} 29}
30
30BBCLASSEXTEND = "native nativesdk" 31BBCLASSEXTEND = "native nativesdk"
31 32
32PACKAGES =+ "checkmk" 33PACKAGES =+ "checkmk"
@@ -34,3 +35,4 @@ PACKAGES =+ "checkmk"
34FILES:checkmk = "${bindir}/checkmk" 35FILES:checkmk = "${bindir}/checkmk"
35 36
36RDEPENDS:checkmk = "gawk" 37RDEPENDS:checkmk = "gawk"
38
diff --git a/meta/recipes-support/libffi/libffi/not-win32.patch b/meta/recipes-support/libffi/libffi/not-win32.patch
index 8efeb9c357..26263731f3 100644
--- a/meta/recipes-support/libffi/libffi/not-win32.patch
+++ b/meta/recipes-support/libffi/libffi/not-win32.patch
@@ -1,4 +1,4 @@
1From d7263091bbea40fd97d4fccd295c0ea4f5a80ad7 Mon Sep 17 00:00:00 2001 1From 28d0fd6b73163fc2dbc10c7dc838a8222671f88c Mon Sep 17 00:00:00 2001
2From: Ross Burton <ross.burton@intel.com> 2From: Ross Burton <ross.burton@intel.com>
3Date: Thu, 4 Feb 2016 16:22:50 +0000 3Date: Thu, 4 Feb 2016 16:22:50 +0000
4Subject: [PATCH] libffi: ensure sysroot paths are not in libffi.pc 4Subject: [PATCH] libffi: ensure sysroot paths are not in libffi.pc
@@ -20,10 +20,10 @@ Signed-off-by: Ross Burton <ross.burton@intel.com>
20 1 file changed, 1 insertion(+), 1 deletion(-) 20 1 file changed, 1 insertion(+), 1 deletion(-)
21 21
22diff --git a/configure.ac b/configure.ac 22diff --git a/configure.ac b/configure.ac
23index f047895..630bdd5 100644 23index 258107d..ef1a285 100644
24--- a/configure.ac 24--- a/configure.ac
25+++ b/configure.ac 25+++ b/configure.ac
26@@ -402,7 +402,7 @@ AC_ARG_ENABLE(multi-os-directory, 26@@ -403,7 +403,7 @@ AC_ARG_ENABLE(multi-os-directory,
27 27
28 # These variables are only ever used when we cross-build to X86_WIN32. 28 # These variables are only ever used when we cross-build to X86_WIN32.
29 # And we only support this with GCC, so... 29 # And we only support this with GCC, so...
diff --git a/meta/recipes-support/libffi/libffi_3.4.8.bb b/meta/recipes-support/libffi/libffi_3.5.1.bb
index 7f927c650b..be16008e0f 100644
--- a/meta/recipes-support/libffi/libffi_3.4.8.bb
+++ b/meta/recipes-support/libffi/libffi_3.5.1.bb
@@ -8,12 +8,12 @@ library really only provides the lowest, machine dependent layer of a fully feat
8A layer must exist above `libffi' that handles type conversions for values passed between the two languages." 8A layer must exist above `libffi' that handles type conversions for values passed between the two languages."
9 9
10LICENSE = "MIT" 10LICENSE = "MIT"
11LIC_FILES_CHKSUM = "file://LICENSE;md5=1db54c9fd307a12218766c3c7f650ca7" 11LIC_FILES_CHKSUM = "file://LICENSE;md5=ce4763670c5b7756000561f9af1ab178"
12 12
13SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/${BPN}-${PV}.tar.gz \ 13SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/${BPN}-${PV}.tar.gz \
14 file://not-win32.patch \ 14 file://not-win32.patch \
15 " 15 "
16SRC_URI[sha256sum] = "bc9842a18898bfacb0ed1252c4febcc7e78fa139fd27fdc7a3e30d9d9356119b" 16SRC_URI[sha256sum] = "f99eb68a67c7d54866b7706af245e87ba060d419a062474b456d3bc8d4abdbd1"
17 17
18EXTRA_OECONF += "--disable-builddir --disable-exec-static-tramp" 18EXTRA_OECONF += "--disable-builddir --disable-exec-static-tramp"
19EXTRA_OECONF:class-native += "--with-gcc-arch=generic" 19EXTRA_OECONF:class-native += "--with-gcc-arch=generic"
diff --git a/scripts/install-buildtools b/scripts/install-buildtools
index 6750ffcbcc..aa23942858 100755
--- a/scripts/install-buildtools
+++ b/scripts/install-buildtools
@@ -57,8 +57,8 @@ logger = scriptutils.logger_create(PROGNAME, stream=sys.stdout)
57 57
58DEFAULT_INSTALL_DIR = os.path.join(os.path.split(scripts_path)[0],'buildtools') 58DEFAULT_INSTALL_DIR = os.path.join(os.path.split(scripts_path)[0],'buildtools')
59DEFAULT_BASE_URL = 'https://downloads.yoctoproject.org/releases/yocto' 59DEFAULT_BASE_URL = 'https://downloads.yoctoproject.org/releases/yocto'
60DEFAULT_RELEASE = 'yocto-5.2' 60DEFAULT_RELEASE = 'yocto-5.2.1'
61DEFAULT_INSTALLER_VERSION = '5.2' 61DEFAULT_INSTALLER_VERSION = '5.2.1'
62DEFAULT_BUILDDATE = '202110XX' 62DEFAULT_BUILDDATE = '202110XX'
63 63
64# Python version sanity check 64# Python version sanity check
diff --git a/scripts/lib/devtool/ide_plugins/ide_code.py b/scripts/lib/devtool/ide_plugins/ide_code.py
index a62b93224e..ee5bb57265 100644
--- a/scripts/lib/devtool/ide_plugins/ide_code.py
+++ b/scripts/lib/devtool/ide_plugins/ide_code.py
@@ -161,7 +161,6 @@ class IdeVSCode(IdeBase):
161 if modified_recipe.build_tool is not BuildTool.CMAKE: 161 if modified_recipe.build_tool is not BuildTool.CMAKE:
162 return 162 return
163 recommendations += [ 163 recommendations += [
164 "twxs.cmake",
165 "ms-vscode.cmake-tools", 164 "ms-vscode.cmake-tools",
166 "ms-vscode.cpptools", 165 "ms-vscode.cpptools",
167 "ms-vscode.cpptools-extension-pack", 166 "ms-vscode.cpptools-extension-pack",
diff --git a/scripts/lib/recipetool/create.py b/scripts/lib/recipetool/create.py
index 94d52d6077..3c6ef6719f 100644
--- a/scripts/lib/recipetool/create.py
+++ b/scripts/lib/recipetool/create.py
@@ -18,6 +18,7 @@ from urllib.parse import urlparse, urldefrag, urlsplit
18import hashlib 18import hashlib
19import bb.fetch2 19import bb.fetch2
20logger = logging.getLogger('recipetool') 20logger = logging.getLogger('recipetool')
21from oe.license_finder import find_licenses
21 22
22tinfoil = None 23tinfoil = None
23plugins = None 24plugins = None
@@ -1040,230 +1041,6 @@ def handle_license_vars(srctree, lines_before, handled, extravalues, d):
1040 handled.append(('license', licvalues)) 1041 handled.append(('license', licvalues))
1041 return licvalues 1042 return licvalues
1042 1043
1043def get_license_md5sums(d, static_only=False, linenumbers=False):
1044 import bb.utils
1045 import csv
1046 md5sums = {}
1047 if not static_only and not linenumbers:
1048 # Gather md5sums of license files in common license dir
1049 commonlicdir = d.getVar('COMMON_LICENSE_DIR')
1050 for fn in os.listdir(commonlicdir):
1051 md5value = bb.utils.md5_file(os.path.join(commonlicdir, fn))
1052 md5sums[md5value] = fn
1053
1054 # The following were extracted from common values in various recipes
1055 # (double checking the license against the license file itself, not just
1056 # the LICENSE value in the recipe)
1057
1058 # Read license md5sums from csv file
1059 scripts_path = os.path.dirname(os.path.realpath(__file__))
1060 for path in (d.getVar('BBPATH').split(':')
1061 + [os.path.join(scripts_path, '..', '..')]):
1062 csv_path = os.path.join(path, 'lib', 'recipetool', 'licenses.csv')
1063 if os.path.isfile(csv_path):
1064 with open(csv_path, newline='') as csv_file:
1065 fieldnames = ['md5sum', 'license', 'beginline', 'endline', 'md5']
1066 reader = csv.DictReader(csv_file, delimiter=',', fieldnames=fieldnames)
1067 for row in reader:
1068 if linenumbers:
1069 md5sums[row['md5sum']] = (
1070 row['license'], row['beginline'], row['endline'], row['md5'])
1071 else:
1072 md5sums[row['md5sum']] = row['license']
1073
1074 return md5sums
1075
1076def crunch_known_licenses(d):
1077 '''
1078 Calculate the MD5 checksums for the crunched versions of all common
1079 licenses. Also add additional known checksums.
1080 '''
1081
1082 crunched_md5sums = {}
1083
1084 # common licenses
1085 crunched_md5sums['ad4e9d34a2e966dfe9837f18de03266d'] = 'GFDL-1.1-only'
1086 crunched_md5sums['d014fb11a34eb67dc717fdcfc97e60ed'] = 'GFDL-1.2-only'
1087 crunched_md5sums['e020ca655b06c112def28e597ab844f1'] = 'GFDL-1.3-only'
1088
1089 # The following two were gleaned from the "forever" npm package
1090 crunched_md5sums['0a97f8e4cbaf889d6fa51f84b89a79f6'] = 'ISC'
1091 # https://github.com/waffle-gl/waffle/blob/master/LICENSE.txt
1092 crunched_md5sums['50fab24ce589d69af8964fdbfe414c60'] = 'BSD-2-Clause'
1093 # https://github.com/spigwitmer/fakeds1963s/blob/master/LICENSE
1094 crunched_md5sums['88a4355858a1433fea99fae34a44da88'] = 'GPL-2.0-only'
1095 # http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
1096 crunched_md5sums['063b5c3ebb5f3aa4c85a2ed18a31fbe7'] = 'GPL-2.0-only'
1097 # https://github.com/FFmpeg/FFmpeg/blob/master/COPYING.LGPLv2.1
1098 crunched_md5sums['7f5202f4d44ed15dcd4915f5210417d8'] = 'LGPL-2.1-only'
1099 # unixODBC-2.3.4 COPYING
1100 crunched_md5sums['3debde09238a8c8e1f6a847e1ec9055b'] = 'LGPL-2.1-only'
1101 # https://github.com/FFmpeg/FFmpeg/blob/master/COPYING.LGPLv3
1102 crunched_md5sums['f90c613c51aa35da4d79dd55fc724ceb'] = 'LGPL-3.0-only'
1103 # https://raw.githubusercontent.com/eclipse/mosquitto/v1.4.14/epl-v10
1104 crunched_md5sums['efe2cb9a35826992b9df68224e3c2628'] = 'EPL-1.0'
1105
1106 # https://raw.githubusercontent.com/jquery/esprima/3.1.3/LICENSE.BSD
1107 crunched_md5sums['80fa7b56a28e8c902e6af194003220a5'] = 'BSD-2-Clause'
1108 # https://raw.githubusercontent.com/npm/npm-install-checks/master/LICENSE
1109 crunched_md5sums['e659f77bfd9002659e112d0d3d59b2c1'] = 'BSD-2-Clause'
1110 # https://raw.githubusercontent.com/silverwind/default-gateway/4.2.0/LICENSE
1111 crunched_md5sums['4c641f2d995c47f5cb08bdb4b5b6ea05'] = 'BSD-2-Clause'
1112 # https://raw.githubusercontent.com/tad-lispy/node-damerau-levenshtein/v1.0.5/LICENSE
1113 crunched_md5sums['2b8c039b2b9a25f0feb4410c4542d346'] = 'BSD-2-Clause'
1114 # https://raw.githubusercontent.com/terser/terser/v3.17.0/LICENSE
1115 crunched_md5sums['8bd23871802951c9ad63855151204c2c'] = 'BSD-2-Clause'
1116 # https://raw.githubusercontent.com/alexei/sprintf.js/1.0.3/LICENSE
1117 crunched_md5sums['008c22318c8ea65928bf730ddd0273e3'] = 'BSD-3-Clause'
1118 # https://raw.githubusercontent.com/Caligatio/jsSHA/v3.2.0/LICENSE
1119 crunched_md5sums['0e46634a01bfef056892949acaea85b1'] = 'BSD-3-Clause'
1120 # https://raw.githubusercontent.com/d3/d3-path/v1.0.9/LICENSE
1121 crunched_md5sums['b5f72aef53d3b2b432702c30b0215666'] = 'BSD-3-Clause'
1122 # https://raw.githubusercontent.com/feross/ieee754/v1.1.13/LICENSE
1123 crunched_md5sums['a39327c997c20da0937955192d86232d'] = 'BSD-3-Clause'
1124 # https://raw.githubusercontent.com/joyent/node-extsprintf/v1.3.0/LICENSE
1125 crunched_md5sums['721f23a96ff4161ca3a5f071bbe18108'] = 'MIT'
1126 # https://raw.githubusercontent.com/pvorb/clone/v0.2.0/LICENSE
1127 crunched_md5sums['b376d29a53c9573006b9970709231431'] = 'MIT'
1128 # https://raw.githubusercontent.com/andris9/encoding/v0.1.12/LICENSE
1129 crunched_md5sums['85d8a977ee9d7c5ab4ac03c9b95431c4'] = 'MIT-0'
1130 # https://raw.githubusercontent.com/faye/websocket-driver-node/0.7.3/LICENSE.md
1131 crunched_md5sums['b66384e7137e41a9b1904ef4d39703b6'] = 'Apache-2.0'
1132 # https://raw.githubusercontent.com/less/less.js/v4.1.1/LICENSE
1133 crunched_md5sums['b27575459e02221ccef97ec0bfd457ae'] = 'Apache-2.0'
1134 # https://raw.githubusercontent.com/microsoft/TypeScript/v3.5.3/LICENSE.txt
1135 crunched_md5sums['a54a1a6a39e7f9dbb4a23a42f5c7fd1c'] = 'Apache-2.0'
1136 # https://raw.githubusercontent.com/request/request/v2.87.0/LICENSE
1137 crunched_md5sums['1034431802e57486b393d00c5d262b8a'] = 'Apache-2.0'
1138 # https://raw.githubusercontent.com/dchest/tweetnacl-js/v0.14.5/LICENSE
1139 crunched_md5sums['75605e6bdd564791ab698fca65c94a4f'] = 'Unlicense'
1140 # https://raw.githubusercontent.com/stackgl/gl-mat3/v2.0.0/LICENSE.md
1141 crunched_md5sums['75512892d6f59dddb6d1c7e191957e9c'] = 'Zlib'
1142
1143 commonlicdir = d.getVar('COMMON_LICENSE_DIR')
1144 for fn in sorted(os.listdir(commonlicdir)):
1145 md5value, lictext = crunch_license(os.path.join(commonlicdir, fn))
1146 if md5value not in crunched_md5sums:
1147 crunched_md5sums[md5value] = fn
1148 elif fn != crunched_md5sums[md5value]:
1149 bb.debug(2, "crunched_md5sums['%s'] is already set to '%s' rather than '%s'" % (md5value, crunched_md5sums[md5value], fn))
1150 else:
1151 bb.debug(2, "crunched_md5sums['%s'] is already set to '%s'" % (md5value, crunched_md5sums[md5value]))
1152
1153 return crunched_md5sums
1154
1155def crunch_license(licfile):
1156 '''
1157 Remove non-material text from a license file and then calculate its
1158 md5sum. This works well for licenses that contain a copyright statement,
1159 but is also a useful way to handle people's insistence upon reformatting
1160 the license text slightly (with no material difference to the text of the
1161 license).
1162 '''
1163
1164 import oe.utils
1165
1166 # Note: these are carefully constructed!
1167 license_title_re = re.compile(r'^#*\(? *(This is )?([Tt]he )?.{0,15} ?[Ll]icen[sc]e( \(.{1,10}\))?\)?[:\.]? ?#*$')
1168 license_statement_re = re.compile(r'^((This (project|software)|.{1,10}) is( free software)? (released|licen[sc]ed)|(Released|Licen[cs]ed)) under the .{1,10} [Ll]icen[sc]e:?$')
1169 copyright_re = re.compile(r'^ *[#\*]* *(Modified work |MIT LICENSED )?Copyright ?(\([cC]\))? .*$')
1170 disclaimer_re = re.compile(r'^ *\*? ?All [Rr]ights [Rr]eserved\.$')
1171 email_re = re.compile(r'^.*<[\w\.-]*@[\w\.\-]*>$')
1172 header_re = re.compile(r'^(\/\**!?)? ?[\-=\*]* ?(\*\/)?$')
1173 tag_re = re.compile(r'^ *@?\(?([Ll]icense|MIT)\)?$')
1174 url_re = re.compile(r'^ *[#\*]* *https?:\/\/[\w\.\/\-]+$')
1175
1176 lictext = []
1177 with open(licfile, 'r', errors='surrogateescape') as f:
1178 for line in f:
1179 # Drop opening statements
1180 if copyright_re.match(line):
1181 continue
1182 elif disclaimer_re.match(line):
1183 continue
1184 elif email_re.match(line):
1185 continue
1186 elif header_re.match(line):
1187 continue
1188 elif tag_re.match(line):
1189 continue
1190 elif url_re.match(line):
1191 continue
1192 elif license_title_re.match(line):
1193 continue
1194 elif license_statement_re.match(line):
1195 continue
1196 # Strip comment symbols
1197 line = line.replace('*', '') \
1198 .replace('#', '')
1199 # Unify spelling
1200 line = line.replace('sub-license', 'sublicense')
1201 # Squash spaces
1202 line = oe.utils.squashspaces(line.strip())
1203 # Replace smart quotes, double quotes and backticks with single quotes
1204 line = line.replace(u"\u2018", "'").replace(u"\u2019", "'").replace(u"\u201c","'").replace(u"\u201d", "'").replace('"', '\'').replace('`', '\'')
1205 # Unify brackets
1206 line = line.replace("{", "[").replace("}", "]")
1207 if line:
1208 lictext.append(line)
1209
1210 m = hashlib.md5()
1211 try:
1212 m.update(' '.join(lictext).encode('utf-8'))
1213 md5val = m.hexdigest()
1214 except UnicodeEncodeError:
1215 md5val = None
1216 lictext = ''
1217 return md5val, lictext
1218
1219def find_license_files(srctree):
1220 licspecs = ['*LICEN[CS]E*', 'COPYING*', '*[Ll]icense*', 'LEGAL*', '[Ll]egal*', '*GPL*', 'README.lic*', 'COPYRIGHT*', '[Cc]opyright*', 'e[dp]l-v10']
1221 skip_extensions = (".html", ".js", ".json", ".svg", ".ts", ".go")
1222 licfiles = []
1223 for root, dirs, files in os.walk(srctree):
1224 for fn in files:
1225 if fn.endswith(skip_extensions):
1226 continue
1227 for spec in licspecs:
1228 if fnmatch.fnmatch(fn, spec):
1229 fullpath = os.path.join(root, fn)
1230 if not fullpath in licfiles:
1231 licfiles.append(fullpath)
1232
1233 return licfiles
1234
1235def match_licenses(licfiles, srctree, d):
1236 import bb
1237 md5sums = get_license_md5sums(d)
1238
1239 crunched_md5sums = crunch_known_licenses(d)
1240
1241 licenses = []
1242 for licfile in sorted(licfiles):
1243 resolved_licfile = d.expand(licfile)
1244 md5value = bb.utils.md5_file(resolved_licfile)
1245 license = md5sums.get(md5value, None)
1246 if not license:
1247 crunched_md5, lictext = crunch_license(resolved_licfile)
1248 license = crunched_md5sums.get(crunched_md5, None)
1249 if lictext and not license:
1250 license = 'Unknown'
1251 logger.info("Please add the following line for '%s' to a 'lib/recipetool/licenses.csv' " \
1252 "and replace `Unknown` with the license:\n" \
1253 "%s,Unknown" % (os.path.relpath(licfile, srctree + "/.."), md5value))
1254 if license:
1255 licenses.append((license, os.path.relpath(licfile, srctree), md5value))
1256
1257 return licenses
1258
1259def find_licenses(srctree, d):
1260 licfiles = find_license_files(srctree)
1261 licenses = match_licenses(licfiles, srctree, d)
1262
1263 # FIXME should we grab at least one source file with a license header and add that too?
1264
1265 return licenses
1266
1267def split_pkg_licenses(licvalues, packages, outlines, fallback_licenses=None, pn='${PN}'): 1044def split_pkg_licenses(licvalues, packages, outlines, fallback_licenses=None, pn='${PN}'):
1268 """ 1045 """
1269 Given a list of (license, path, md5sum) as returned by match_licenses(), 1046 Given a list of (license, path, md5sum) as returned by match_licenses(),
diff --git a/scripts/lib/recipetool/create_npm.py b/scripts/lib/recipetool/create_npm.py
index 3363a0e7ee..8c4cdd5234 100644
--- a/scripts/lib/recipetool/create_npm.py
+++ b/scripts/lib/recipetool/create_npm.py
@@ -15,8 +15,9 @@ import bb
15from bb.fetch2.npm import NpmEnvironment 15from bb.fetch2.npm import NpmEnvironment
16from bb.fetch2.npm import npm_package 16from bb.fetch2.npm import npm_package
17from bb.fetch2.npmsw import foreach_dependencies 17from bb.fetch2.npmsw import foreach_dependencies
18from oe.license_finder import match_licenses, find_license_files
18from recipetool.create import RecipeHandler 19from recipetool.create import RecipeHandler
19from recipetool.create import match_licenses, find_license_files, generate_common_licenses_chksums 20from recipetool.create import generate_common_licenses_chksums
20from recipetool.create import split_pkg_licenses 21from recipetool.create import split_pkg_licenses
21logger = logging.getLogger('recipetool') 22logger = logging.getLogger('recipetool')
22 23
diff --git a/scripts/lib/recipetool/licenses.csv b/scripts/lib/recipetool/licenses.csv
deleted file mode 100644
index 80851111b3..0000000000
--- a/scripts/lib/recipetool/licenses.csv
+++ /dev/null
@@ -1,37 +0,0 @@
10636e73ff0215e8d672dc4c32c317bb3,GPL-2.0-only
212f884d2ae1ff87c09e5b7ccc2c4ca7e,GPL-2.0-only
318810669f13b87348459e611d31ab760,GPL-2.0-only
4252890d9eee26aab7b432e8b8a616475,LGPL-2.0-only
52d5025d4aa3495befef8f17206a5b0a1,LGPL-2.1-only
63214f080875748938ba060314b4f727d,LGPL-2.0-only
7385c55653886acac3821999a3ccd17b3,Artistic-1.0 | GPL-2.0-only
8393a5ca445f6965873eca0259a17f833,GPL-2.0-only
93b83ef96387f14655fc854ddc3c6bd57,Apache-2.0
103bf50002aefd002f49e7bb854063f7e7,LGPL-2.0-only
114325afd396febcb659c36b49533135d4,GPL-2.0-only
124fbd65380cdd255951079008b364516c,LGPL-2.1-only
1354c7042be62e169199200bc6477f04d1,BSD-3-Clause
1455ca817ccb7d5b5b66355690e9abc605,LGPL-2.0-only
1559530bdf33659b29e73d4adb9f9f6552,GPL-2.0-only
165f30f0716dfdd0d91eb439ebec522ec2,LGPL-2.0-only
176a6a8e020838b23406c81b19c1d46df6,LGPL-3.0-only
18751419260aa954499f7abaabaa882bbe,GPL-2.0-only
197fbc338309ac38fefcd64b04bb903e34,LGPL-2.1-only
208ca43cbc842c2336e835926c2166c28b,GPL-2.0-only
2194d55d512a9ba36caa9b7df079bae19f,GPL-2.0-only
229ac2e7cff1ddaf48b6eab6028f23ef88,GPL-2.0-only
239f604d8a4f8e74f4f5140845a21b6674,LGPL-2.0-only
24a6f89e2100d9b6cdffcea4f398e37343,LGPL-2.1-only
25b234ee4d69f5fce4486a80fdaf4a4263,GPL-2.0-only
26bbb461211a33b134d42ed5ee802b37ff,LGPL-2.1-only
27bfe1f75d606912a4111c90743d6c7325,MPL-1.1-only
28c93c0550bd3173f4504b2cbd8991e50b,GPL-2.0-only
29d32239bcb673463ab874e80d47fae504,GPL-3.0-only
30d7810fab7487fb0aad327b76f1be7cd7,GPL-2.0-only
31d8045f3b8f929c1cb29a1e3fd737b499,LGPL-2.1-only
32db979804f025cf55aabec7129cb671ed,LGPL-2.0-only
33eb723b61539feef013de476e68b5c50a,GPL-2.0-only
34ebb5c50ab7cab4baeffba14977030c07,GPL-2.0-only
35f27defe1e96c2e1ecd4e0c9be8967949,GPL-3.0-only
36fad9b3332be894bab9bc501572864b29,LGPL-2.1-only
37fbc093901857fcd118f065f900982c24,LGPL-2.1-only
diff --git a/scripts/lib/wic/canned-wks/common.wks.inc b/scripts/lib/wic/canned-wks/common.wks.inc
index 89880b417b..4a440ddafe 100644
--- a/scripts/lib/wic/canned-wks/common.wks.inc
+++ b/scripts/lib/wic/canned-wks/common.wks.inc
@@ -1,3 +1,3 @@
1# This file is included into 3 canned wks files from this directory 1# This file is included into 3 canned wks files from this directory
2part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024 2part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
3part / --source rootfs --use-uuid --fstype=ext4 --label platform --align 1024 3part / --source rootfs --use-uuid --fstype=ext4 --label platform --align 1024
diff --git a/scripts/lib/wic/canned-wks/directdisk-gpt.wks b/scripts/lib/wic/canned-wks/directdisk-gpt.wks
index 8d7d8de6ea..cb640056f1 100644
--- a/scripts/lib/wic/canned-wks/directdisk-gpt.wks
+++ b/scripts/lib/wic/canned-wks/directdisk-gpt.wks
@@ -3,7 +3,7 @@
3# can directly dd to boot media. 3# can directly dd to boot media.
4 4
5 5
6part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024 6part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid 7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
8 8
9bootloader --ptable gpt --timeout=0 --append="rootwait rootfstype=ext4 video=vesafb vga=0x318 console=tty0 console=ttyS0,115200n8" 9bootloader --ptable gpt --timeout=0 --append="rootwait rootfstype=ext4 video=vesafb vga=0x318 console=tty0 console=ttyS0,115200n8"
diff --git a/scripts/lib/wic/canned-wks/directdisk-multi-rootfs.wks b/scripts/lib/wic/canned-wks/directdisk-multi-rootfs.wks
index f61d941d6d..4fd1999ffb 100644
--- a/scripts/lib/wic/canned-wks/directdisk-multi-rootfs.wks
+++ b/scripts/lib/wic/canned-wks/directdisk-multi-rootfs.wks
@@ -15,7 +15,7 @@
15# 15#
16# - or any combinations of -r and --rootfs command line options 16# - or any combinations of -r and --rootfs command line options
17 17
18part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024 18part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
19part / --source rootfs --rootfs-dir=rootfs1 --ondisk sda --fstype=ext4 --label platform --align 1024 19part / --source rootfs --rootfs-dir=rootfs1 --ondisk sda --fstype=ext4 --label platform --align 1024
20part /rescue --source rootfs --rootfs-dir=rootfs2 --ondisk sda --fstype=ext4 --label secondary --align 1024 20part /rescue --source rootfs --rootfs-dir=rootfs2 --ondisk sda --fstype=ext4 --label secondary --align 1024
21 21
diff --git a/scripts/lib/wic/canned-wks/efi-uki-bootdisk.wks.in b/scripts/lib/wic/canned-wks/efi-uki-bootdisk.wks.in
index 67cc41a241..cac0fa32cd 100644
--- a/scripts/lib/wic/canned-wks/efi-uki-bootdisk.wks.in
+++ b/scripts/lib/wic/canned-wks/efi-uki-bootdisk.wks.in
@@ -1,3 +1,3 @@
1bootloader --ptable gpt --timeout=5 1bootloader --ptable gpt --timeout=5
2part /boot --source bootimg-efi --sourceparams="loader=${EFI_PROVIDER}" --label boot --active --align 1024 --use-uuid --part-name="ESP" --part-type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B --overhead-factor=1 2part /boot --source bootimg_efi --sourceparams="loader=${EFI_PROVIDER}" --label boot --active --align 1024 --use-uuid --part-name="ESP" --part-type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B --overhead-factor=1
3part / --source rootfs --fstype=ext4 --label root --align 1024 --exclude-path boot/ 3part / --source rootfs --fstype=ext4 --label root --align 1024 --exclude-path boot/
diff --git a/scripts/lib/wic/canned-wks/mkefidisk.wks b/scripts/lib/wic/canned-wks/mkefidisk.wks
index 5fa6682a9e..16dfe76dfe 100644
--- a/scripts/lib/wic/canned-wks/mkefidisk.wks
+++ b/scripts/lib/wic/canned-wks/mkefidisk.wks
@@ -2,7 +2,7 @@
2# long-description: Creates a partitioned EFI disk image that the user 2# long-description: Creates a partitioned EFI disk image that the user
3# can directly dd to boot media. 3# can directly dd to boot media.
4 4
5part /boot --source bootimg-efi --sourceparams="loader=grub-efi" --ondisk sda --label msdos --active --align 1024 5part /boot --source bootimg_efi --sourceparams="loader=grub-efi" --ondisk sda --label msdos --active --align 1024
6 6
7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid 7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
8 8
diff --git a/scripts/lib/wic/canned-wks/mkhybridiso.wks b/scripts/lib/wic/canned-wks/mkhybridiso.wks
index 48c5ac4791..c3a030e5b4 100644
--- a/scripts/lib/wic/canned-wks/mkhybridiso.wks
+++ b/scripts/lib/wic/canned-wks/mkhybridiso.wks
@@ -2,6 +2,6 @@
2# long-description: Creates an EFI and legacy bootable hybrid ISO image 2# long-description: Creates an EFI and legacy bootable hybrid ISO image
3# which can be used on optical media as well as USB media. 3# which can be used on optical media as well as USB media.
4 4
5part /boot --source isoimage-isohybrid --sourceparams="loader=grub-efi,image_name=HYBRID_ISO_IMG" --ondisk cd --label HYBRIDISO 5part /boot --source isoimage_isohybrid --sourceparams="loader=grub-efi,image_name=HYBRID_ISO_IMG" --ondisk cd --label HYBRIDISO
6 6
7bootloader --timeout=15 --append="" 7bootloader --timeout=15 --append=""
diff --git a/scripts/lib/wic/canned-wks/sdimage-bootpart.wks b/scripts/lib/wic/canned-wks/sdimage-bootpart.wks
index 63bc4dab6a..f9f8044f7d 100644
--- a/scripts/lib/wic/canned-wks/sdimage-bootpart.wks
+++ b/scripts/lib/wic/canned-wks/sdimage-bootpart.wks
@@ -2,5 +2,5 @@
2# long-description: Creates a partitioned SD card image. Boot files 2# long-description: Creates a partitioned SD card image. Boot files
3# are located in the first vfat partition. 3# are located in the first vfat partition.
4 4
5part /boot --source bootimg-partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --size 16 5part /boot --source bootimg_partition --ondisk mmcblk0 --fstype=vfat --label boot --active --align 4 --size 16
6part / --source rootfs --ondisk mmcblk0 --fstype=ext4 --label root --align 4 6part / --source rootfs --ondisk mmcblk0 --fstype=ext4 --label root --align 4
diff --git a/scripts/lib/wic/canned-wks/systemd-bootdisk.wks b/scripts/lib/wic/canned-wks/systemd-bootdisk.wks
index 95d7b97a60..3fb2c0e35f 100644
--- a/scripts/lib/wic/canned-wks/systemd-bootdisk.wks
+++ b/scripts/lib/wic/canned-wks/systemd-bootdisk.wks
@@ -2,7 +2,7 @@
2# long-description: Creates a partitioned EFI disk image that the user 2# long-description: Creates a partitioned EFI disk image that the user
3# can directly dd to boot media. The selected bootloader is systemd-boot. 3# can directly dd to boot media. The selected bootloader is systemd-boot.
4 4
5part /boot --source bootimg-efi --sourceparams="loader=systemd-boot" --ondisk sda --label msdos --active --align 1024 --use-uuid 5part /boot --source bootimg_efi --sourceparams="loader=systemd-boot" --ondisk sda --label msdos --active --align 1024 --use-uuid
6 6
7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid 7part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 --use-uuid
8 8
diff --git a/scripts/lib/wic/engine.py b/scripts/lib/wic/engine.py
index 64b1d52882..b9e60cbe4e 100644
--- a/scripts/lib/wic/engine.py
+++ b/scripts/lib/wic/engine.py
@@ -180,6 +180,8 @@ def wic_create(wks_file, rootfs_dir, bootimg_dir, kernel_dir,
180 os.makedirs(options.outdir) 180 os.makedirs(options.outdir)
181 181
182 pname = options.imager 182 pname = options.imager
183 # Don't support '-' in plugin names
184 pname = pname.replace("-", "_")
183 plugin_class = PluginMgr.get_plugins('imager').get(pname) 185 plugin_class = PluginMgr.get_plugins('imager').get(pname)
184 if not plugin_class: 186 if not plugin_class:
185 raise WicError('Unknown plugin: %s' % pname) 187 raise WicError('Unknown plugin: %s' % pname)
diff --git a/scripts/lib/wic/help.py b/scripts/lib/wic/help.py
index 9180d75a92..2e3061f343 100644
--- a/scripts/lib/wic/help.py
+++ b/scripts/lib/wic/help.py
@@ -544,18 +544,18 @@ DESCRIPTION
544 the --source param given to that partition. For example, if the 544 the --source param given to that partition. For example, if the
545 partition is set up like this: 545 partition is set up like this:
546 546
547 part /boot --source bootimg-pcbios ... 547 part /boot --source bootimg_pcbios ...
548 548
549 then the methods defined as class members of the plugin having the 549 then the methods defined as class members of the plugin having the
550 matching bootimg-pcbios .name class member would be used. 550 matching bootimg_pcbios .name class member would be used.
551 551
552 To be more concrete, here's the plugin definition that would match 552 To be more concrete, here's the plugin definition that would match
553 a '--source bootimg-pcbios' usage, along with an example method 553 a '--source bootimg_pcbios' usage, along with an example method
554 that would be called by the wic implementation when it needed to 554 that would be called by the wic implementation when it needed to
555 invoke an implementation-specific partition-preparation function: 555 invoke an implementation-specific partition-preparation function:
556 556
557 class BootimgPcbiosPlugin(SourcePlugin): 557 class BootimgPcbiosPlugin(SourcePlugin):
558 name = 'bootimg-pcbios' 558 name = 'bootimg_pcbios'
559 559
560 @classmethod 560 @classmethod
561 def do_prepare_partition(self, part, ...) 561 def do_prepare_partition(self, part, ...)
@@ -794,7 +794,7 @@ DESCRIPTION
794 794
795 Here is a content of test.wks: 795 Here is a content of test.wks:
796 796
797 part /boot --source bootimg-pcbios --ondisk sda --label boot --active --align 1024 797 part /boot --source bootimg_pcbios --ondisk sda --label boot --active --align 1024
798 part / --source rootfs --ondisk sda --fstype=ext3 --label platform --align 1024 798 part / --source rootfs --ondisk sda --fstype=ext3 --label platform --align 1024
799 799
800 bootloader --timeout=0 --append="rootwait rootfstype=ext3 video=vesafb vga=0x318 console=tty0" 800 bootloader --timeout=0 --append="rootwait rootfstype=ext3 video=vesafb vga=0x318 console=tty0"
diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index 5b51ab214f..b34691d313 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -164,6 +164,9 @@ class Partition():
164 164
165 plugins = PluginMgr.get_plugins('source') 165 plugins = PluginMgr.get_plugins('source')
166 166
167 # Don't support '-' in plugin names
168 self.source = self.source.replace("-", "_")
169
167 if self.source not in plugins: 170 if self.source not in plugins:
168 raise WicError("The '%s' --source specified for %s doesn't exist.\n\t" 171 raise WicError("The '%s' --source specified for %s doesn't exist.\n\t"
169 "See 'wic list source-plugins' for a list of available" 172 "See 'wic list source-plugins' for a list of available"
@@ -178,7 +181,7 @@ class Partition():
178 splitted = self.sourceparams.split(',') 181 splitted = self.sourceparams.split(',')
179 srcparams_dict = dict((par.split('=', 1) + [None])[:2] for par in splitted if par) 182 srcparams_dict = dict((par.split('=', 1) + [None])[:2] for par in splitted if par)
180 183
181 plugin = PluginMgr.get_plugins('source')[self.source] 184 plugin = plugins[self.source]
182 plugin.do_configure_partition(self, srcparams_dict, creator, 185 plugin.do_configure_partition(self, srcparams_dict, creator,
183 cr_workdir, oe_builddir, bootimg_dir, 186 cr_workdir, oe_builddir, bootimg_dir,
184 kernel_dir, native_sysroot) 187 kernel_dir, native_sysroot)
diff --git a/scripts/lib/wic/pluginbase.py b/scripts/lib/wic/pluginbase.py
index b64568339b..640da292d3 100644
--- a/scripts/lib/wic/pluginbase.py
+++ b/scripts/lib/wic/pluginbase.py
@@ -44,7 +44,7 @@ class PluginMgr:
44 path = os.path.join(layer_path, script_plugin_dir) 44 path = os.path.join(layer_path, script_plugin_dir)
45 path = os.path.abspath(os.path.expanduser(path)) 45 path = os.path.abspath(os.path.expanduser(path))
46 if path not in cls._plugin_dirs and os.path.isdir(path): 46 if path not in cls._plugin_dirs and os.path.isdir(path):
47 cls._plugin_dirs.insert(0, path) 47 cls._plugin_dirs.append(path)
48 48
49 if ptype not in PLUGINS: 49 if ptype not in PLUGINS:
50 # load all ptype plugins 50 # load all ptype plugins
diff --git a/scripts/lib/wic/plugins/imager/direct.py b/scripts/lib/wic/plugins/imager/direct.py
index 2124ceac7f..6e1f1c8cba 100644
--- a/scripts/lib/wic/plugins/imager/direct.py
+++ b/scripts/lib/wic/plugins/imager/direct.py
@@ -203,6 +203,8 @@ class DirectPlugin(ImagerPlugin):
203 source_plugin = self.ks.bootloader.source 203 source_plugin = self.ks.bootloader.source
204 disk_name = self.parts[0].disk 204 disk_name = self.parts[0].disk
205 if source_plugin: 205 if source_plugin:
206 # Don't support '-' in plugin names
207 source_plugin = source_plugin.replace("-", "_")
206 plugin = PluginMgr.get_plugins('source')[source_plugin] 208 plugin = PluginMgr.get_plugins('source')[source_plugin]
207 plugin.do_install_disk(self._image, disk_name, self, self.workdir, 209 plugin.do_install_disk(self._image, disk_name, self, self.workdir,
208 self.oe_builddir, self.bootimg_dir, 210 self.oe_builddir, self.bootimg_dir,
diff --git a/scripts/lib/wic/plugins/source/bootimg-biosplusefi.py b/scripts/lib/wic/plugins/source/bootimg_biosplusefi.py
index 5bd7390680..4279ddded8 100644
--- a/scripts/lib/wic/plugins/source/bootimg-biosplusefi.py
+++ b/scripts/lib/wic/plugins/source/bootimg_biosplusefi.py
@@ -13,7 +13,7 @@
13# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 13# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
14# 14#
15# DESCRIPTION 15# DESCRIPTION
16# This implements the 'bootimg-biosplusefi' source plugin class for 'wic' 16# This implements the 'bootimg_biosplusefi' source plugin class for 'wic'
17# 17#
18# AUTHORS 18# AUTHORS
19# William Bourque <wbourque [at) gmail.com> 19# William Bourque <wbourque [at) gmail.com>
@@ -34,7 +34,7 @@ class BootimgBiosPlusEFIPlugin(SourcePlugin):
34 34
35 Note it is possible to create an image that can boot from both 35 Note it is possible to create an image that can boot from both
36 legacy BIOS and EFI by defining two partitions : one with arg 36 legacy BIOS and EFI by defining two partitions : one with arg
37 --source bootimg-efi and another one with --source bootimg-pcbios. 37 --source bootimg_efi and another one with --source bootimg_pcbios.
38 However, this method has the obvious downside that it requires TWO 38 However, this method has the obvious downside that it requires TWO
39 partitions to be created on the storage device. 39 partitions to be created on the storage device.
40 Both partitions will also be marked as "bootable" which does not work on 40 Both partitions will also be marked as "bootable" which does not work on
@@ -45,7 +45,7 @@ class BootimgBiosPlusEFIPlugin(SourcePlugin):
45 the first partition will be duplicated into the second, even though it 45 the first partition will be duplicated into the second, even though it
46 will not be used at all. 46 will not be used at all.
47 47
48 Also, unlike "isoimage-isohybrid" that also does BIOS and EFI, this plugin 48 Also, unlike "isoimage_isohybrid" that also does BIOS and EFI, this plugin
49 allows you to have more than only a single rootfs partitions and does 49 allows you to have more than only a single rootfs partitions and does
50 not turn the rootfs into an initramfs RAM image. 50 not turn the rootfs into an initramfs RAM image.
51 51
@@ -53,32 +53,32 @@ class BootimgBiosPlusEFIPlugin(SourcePlugin):
53 does not have the limitations listed above. 53 does not have the limitations listed above.
54 54
55 The plugin is made so it does tries not to reimplement what's already 55 The plugin is made so it does tries not to reimplement what's already
56 been done in other plugins; as such it imports "bootimg-pcbios" 56 been done in other plugins; as such it imports "bootimg_pcbios"
57 and "bootimg-efi". 57 and "bootimg_efi".
58 Plugin "bootimg-pcbios" is used to generate legacy BIOS boot. 58 Plugin "bootimg_pcbios" is used to generate legacy BIOS boot.
59 Plugin "bootimg-efi" is used to generate the UEFI boot. Note that it 59 Plugin "bootimg_efi" is used to generate the UEFI boot. Note that it
60 requires a --sourceparams argument to know which loader to use; refer 60 requires a --sourceparams argument to know which loader to use; refer
61 to "bootimg-efi" code/documentation for the list of loader. 61 to "bootimg_efi" code/documentation for the list of loader.
62 62
63 Imports are handled with "SourceFileLoader" from importlib as it is 63 Imports are handled with "SourceFileLoader" from importlib as it is
64 otherwise very difficult to import module that has hyphen "-" in their 64 otherwise very difficult to import module that has hyphen "-" in their
65 filename. 65 filename.
66 The SourcePlugin() methods used in the plugins (do_install_disk, 66 The SourcePlugin() methods used in the plugins (do_install_disk,
67 do_configure_partition, do_prepare_partition) are then called on both, 67 do_configure_partition, do_prepare_partition) are then called on both,
68 beginning by "bootimg-efi". 68 beginning by "bootimg_efi".
69 69
70 Plugin options, such as "--sourceparams" can still be passed to a 70 Plugin options, such as "--sourceparams" can still be passed to a
71 plugin, as long they does not cause issue in the other plugin. 71 plugin, as long they does not cause issue in the other plugin.
72 72
73 Example wic configuration: 73 Example wic configuration:
74 part /boot --source bootimg-biosplusefi --sourceparams="loader=grub-efi"\\ 74 part /boot --source bootimg_biosplusefi --sourceparams="loader=grub-efi"\\
75 --ondisk sda --label os_boot --active --align 1024 --use-uuid 75 --ondisk sda --label os_boot --active --align 1024 --use-uuid
76 """ 76 """
77 77
78 name = 'bootimg-biosplusefi' 78 name = 'bootimg_biosplusefi'
79 79
80 __PCBIOS_MODULE_NAME = "bootimg-pcbios" 80 __PCBIOS_MODULE_NAME = "bootimg_pcbios"
81 __EFI_MODULE_NAME = "bootimg-efi" 81 __EFI_MODULE_NAME = "bootimg_efi"
82 82
83 __imgEFIObj = None 83 __imgEFIObj = None
84 __imgBiosObj = None 84 __imgBiosObj = None
@@ -100,7 +100,7 @@ class BootimgBiosPlusEFIPlugin(SourcePlugin):
100 100
101 """ 101 """
102 102
103 # Import bootimg-pcbios (class name "BootimgPcbiosPlugin") 103 # Import bootimg_pcbios (class name "BootimgPcbiosPlugin")
104 modulePath = os.path.join(os.path.dirname(os.path.realpath(__file__)), 104 modulePath = os.path.join(os.path.dirname(os.path.realpath(__file__)),
105 cls.__PCBIOS_MODULE_NAME + ".py") 105 cls.__PCBIOS_MODULE_NAME + ".py")
106 loader = SourceFileLoader(cls.__PCBIOS_MODULE_NAME, modulePath) 106 loader = SourceFileLoader(cls.__PCBIOS_MODULE_NAME, modulePath)
@@ -108,7 +108,7 @@ class BootimgBiosPlusEFIPlugin(SourcePlugin):
108 loader.exec_module(mod) 108 loader.exec_module(mod)
109 cls.__imgBiosObj = mod.BootimgPcbiosPlugin() 109 cls.__imgBiosObj = mod.BootimgPcbiosPlugin()
110 110
111 # Import bootimg-efi (class name "BootimgEFIPlugin") 111 # Import bootimg_efi (class name "BootimgEFIPlugin")
112 modulePath = os.path.join(os.path.dirname(os.path.realpath(__file__)), 112 modulePath = os.path.join(os.path.dirname(os.path.realpath(__file__)),
113 cls.__EFI_MODULE_NAME + ".py") 113 cls.__EFI_MODULE_NAME + ".py")
114 loader = SourceFileLoader(cls.__EFI_MODULE_NAME, modulePath) 114 loader = SourceFileLoader(cls.__EFI_MODULE_NAME, modulePath)
diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg_efi.py
index 38da5080fb..cf16705a28 100644
--- a/scripts/lib/wic/plugins/source/bootimg-efi.py
+++ b/scripts/lib/wic/plugins/source/bootimg_efi.py
@@ -4,7 +4,7 @@
4# SPDX-License-Identifier: GPL-2.0-only 4# SPDX-License-Identifier: GPL-2.0-only
5# 5#
6# DESCRIPTION 6# DESCRIPTION
7# This implements the 'bootimg-efi' source plugin class for 'wic' 7# This implements the 'bootimg_efi' source plugin class for 'wic'
8# 8#
9# AUTHORS 9# AUTHORS
10# Tom Zanussi <tom.zanussi (at] linux.intel.com> 10# Tom Zanussi <tom.zanussi (at] linux.intel.com>
@@ -32,7 +32,7 @@ class BootimgEFIPlugin(SourcePlugin):
32 This plugin supports GRUB 2 and systemd-boot bootloaders. 32 This plugin supports GRUB 2 and systemd-boot bootloaders.
33 """ 33 """
34 34
35 name = 'bootimg-efi' 35 name = 'bootimg_efi'
36 36
37 @classmethod 37 @classmethod
38 def _copy_additional_files(cls, hdddir, initrd, dtb): 38 def _copy_additional_files(cls, hdddir, initrd, dtb):
@@ -230,9 +230,9 @@ class BootimgEFIPlugin(SourcePlugin):
230 elif source_params['loader'] == 'uefi-kernel': 230 elif source_params['loader'] == 'uefi-kernel':
231 pass 231 pass
232 else: 232 else:
233 raise WicError("unrecognized bootimg-efi loader: %s" % source_params['loader']) 233 raise WicError("unrecognized bootimg_efi loader: %s" % source_params['loader'])
234 except KeyError: 234 except KeyError:
235 raise WicError("bootimg-efi requires a loader, none specified") 235 raise WicError("bootimg_efi requires a loader, none specified")
236 236
237 if get_bitbake_var("IMAGE_EFI_BOOT_FILES") is None: 237 if get_bitbake_var("IMAGE_EFI_BOOT_FILES") is None:
238 logger.debug('No boot files defined in IMAGE_EFI_BOOT_FILES') 238 logger.debug('No boot files defined in IMAGE_EFI_BOOT_FILES')
@@ -365,7 +365,7 @@ class BootimgEFIPlugin(SourcePlugin):
365 out = exec_cmd(cp_cmd, True) 365 out = exec_cmd(cp_cmd, True)
366 logger.debug("uefi-kernel files:\n%s" % out) 366 logger.debug("uefi-kernel files:\n%s" % out)
367 else: 367 else:
368 raise WicError("unrecognized bootimg-efi loader: %s" % 368 raise WicError("unrecognized bootimg_efi loader: %s" %
369 source_params['loader']) 369 source_params['loader'])
370 370
371 # must have installed at least one EFI bootloader 371 # must have installed at least one EFI bootloader
@@ -375,7 +375,7 @@ class BootimgEFIPlugin(SourcePlugin):
375 raise WicError("No EFI loaders installed to ESP partition. Check that grub-efi, systemd-boot or similar is installed.") 375 raise WicError("No EFI loaders installed to ESP partition. Check that grub-efi, systemd-boot or similar is installed.")
376 376
377 except KeyError: 377 except KeyError:
378 raise WicError("bootimg-efi requires a loader, none specified") 378 raise WicError("bootimg_efi requires a loader, none specified")
379 379
380 startup = os.path.join(kernel_dir, "startup.nsh") 380 startup = os.path.join(kernel_dir, "startup.nsh")
381 if os.path.exists(startup): 381 if os.path.exists(startup):
diff --git a/scripts/lib/wic/plugins/source/bootimg-partition.py b/scripts/lib/wic/plugins/source/bootimg_partition.py
index 589853a439..cc121a78f0 100644
--- a/scripts/lib/wic/plugins/source/bootimg-partition.py
+++ b/scripts/lib/wic/plugins/source/bootimg_partition.py
@@ -4,7 +4,7 @@
4# SPDX-License-Identifier: GPL-2.0-only 4# SPDX-License-Identifier: GPL-2.0-only
5# 5#
6# DESCRIPTION 6# DESCRIPTION
7# This implements the 'bootimg-partition' source plugin class for 7# This implements the 'bootimg_partition' source plugin class for
8# 'wic'. The plugin creates an image of boot partition, copying over 8# 'wic'. The plugin creates an image of boot partition, copying over
9# files listed in IMAGE_BOOT_FILES bitbake variable. 9# files listed in IMAGE_BOOT_FILES bitbake variable.
10# 10#
@@ -31,7 +31,7 @@ class BootimgPartitionPlugin(SourcePlugin):
31 listed in IMAGE_BOOT_FILES bitbake variable. 31 listed in IMAGE_BOOT_FILES bitbake variable.
32 """ 32 """
33 33
34 name = 'bootimg-partition' 34 name = 'bootimg_partition'
35 image_boot_files_var_name = 'IMAGE_BOOT_FILES' 35 image_boot_files_var_name = 'IMAGE_BOOT_FILES'
36 36
37 @classmethod 37 @classmethod
diff --git a/scripts/lib/wic/plugins/source/bootimg-pcbios.py b/scripts/lib/wic/plugins/source/bootimg_pcbios.py
index a207a83530..21f41e00bb 100644
--- a/scripts/lib/wic/plugins/source/bootimg-pcbios.py
+++ b/scripts/lib/wic/plugins/source/bootimg_pcbios.py
@@ -4,7 +4,7 @@
4# SPDX-License-Identifier: GPL-2.0-only 4# SPDX-License-Identifier: GPL-2.0-only
5# 5#
6# DESCRIPTION 6# DESCRIPTION
7# This implements the 'bootimg-pcbios' source plugin class for 'wic' 7# This implements the 'bootimg_pcbios' source plugin class for 'wic'
8# 8#
9# AUTHORS 9# AUTHORS
10# Tom Zanussi <tom.zanussi (at] linux.intel.com> 10# Tom Zanussi <tom.zanussi (at] linux.intel.com>
@@ -27,7 +27,7 @@ class BootimgPcbiosPlugin(SourcePlugin):
27 Create MBR boot partition and install syslinux on it. 27 Create MBR boot partition and install syslinux on it.
28 """ 28 """
29 29
30 name = 'bootimg-pcbios' 30 name = 'bootimg_pcbios'
31 31
32 @classmethod 32 @classmethod
33 def _get_bootimg_dir(cls, bootimg_dir, dirname): 33 def _get_bootimg_dir(cls, bootimg_dir, dirname):
diff --git a/scripts/lib/wic/plugins/source/isoimage-isohybrid.py b/scripts/lib/wic/plugins/source/isoimage_isohybrid.py
index 607356ad13..5d42eb5d3e 100644
--- a/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
+++ b/scripts/lib/wic/plugins/source/isoimage_isohybrid.py
@@ -4,7 +4,7 @@
4# SPDX-License-Identifier: GPL-2.0-only 4# SPDX-License-Identifier: GPL-2.0-only
5# 5#
6# DESCRIPTION 6# DESCRIPTION
7# This implements the 'isoimage-isohybrid' source plugin class for 'wic' 7# This implements the 'isoimage_isohybrid' source plugin class for 'wic'
8# 8#
9# AUTHORS 9# AUTHORS
10# Mihaly Varga <mihaly.varga (at] ni.com> 10# Mihaly Varga <mihaly.varga (at] ni.com>
@@ -35,7 +35,7 @@ class IsoImagePlugin(SourcePlugin):
35 bootloader files. 35 bootloader files.
36 36
37 Example kickstart file: 37 Example kickstart file:
38 part /boot --source isoimage-isohybrid --sourceparams="loader=grub-efi, \\ 38 part /boot --source isoimage_isohybrid --sourceparams="loader=grub-efi, \\
39 image_name= IsoImage" --ondisk cd --label LIVECD 39 image_name= IsoImage" --ondisk cd --label LIVECD
40 bootloader --timeout=10 --append=" " 40 bootloader --timeout=10 --append=" "
41 41
@@ -45,7 +45,7 @@ class IsoImagePlugin(SourcePlugin):
45 extension added by direct imeger plugin) and a file named IsoImage-cd.iso 45 extension added by direct imeger plugin) and a file named IsoImage-cd.iso
46 """ 46 """
47 47
48 name = 'isoimage-isohybrid' 48 name = 'isoimage_isohybrid'
49 49
50 @classmethod 50 @classmethod
51 def do_configure_syslinux(cls, creator, cr_workdir): 51 def do_configure_syslinux(cls, creator, cr_workdir):
@@ -340,10 +340,10 @@ class IsoImagePlugin(SourcePlugin):
340 cls.do_configure_grubefi(part, creator, target_dir) 340 cls.do_configure_grubefi(part, creator, target_dir)
341 341
342 else: 342 else:
343 raise WicError("unrecognized bootimg-efi loader: %s" % 343 raise WicError("unrecognized bootimg_efi loader: %s" %
344 source_params['loader']) 344 source_params['loader'])
345 except KeyError: 345 except KeyError:
346 raise WicError("bootimg-efi requires a loader, none specified") 346 raise WicError("bootimg_efi requires a loader, none specified")
347 347
348 # Create efi.img that contains bootloader files for EFI booting 348 # Create efi.img that contains bootloader files for EFI booting
349 # if ISODIR didn't exist or didn't contains it 349 # if ISODIR didn't exist or didn't contains it