Skip to contentSkip to conversation

Confusing and invalid conditional appends

PATCH In review Michal Sieron 2 participants 15 messages Mar 17

lore
Share & tools
lore
#0 lore raw

v3 cover Confusing and invalid conditional appends

This patchset fixes several findings for variable assignments of form:

    A:someoverride += "foo"

and transforms them into:
A:append:someoverride = " foo"

In most of those cases I assume the original intent was to have a conditional append, but what was actually happening was append to a conditional override.

I first noticed such problem in our internal recipes and bbappends, but then I decided to check if similar issue exists upstream and turns out it does.

---
Changes in v3:
- Use normal assignment in libffi and expat instead
- Fix package name typo in musl-locales
- Link to v2: https://lore.kernel.org/r/[email protected]

Changes in v2:
- Split initial single commit into smaller ones
- Described actual impact on the overriden variables
- Added some recipes that I missed last time
- Link to v1: https://lore.kernel.org/r/[email protected]

---
Michal Sieron (13):
libffi: Convert confusing append to assignment
coreutils: Convert confusing append to override syntax
expat: Convert confusing append to assignment tune-power[567]: Remove confusing overrides
no-gplv3.inc: Convert confusing appends to override syntax
bootchart2: Convert confusing appends to override syntax
pigz: Convert confusing append to override syntax
systemtap: Convert confusing append to override syntax
ovmf: Convert confusing append to override syntax
dnf: Convert confusing append to override syntax
qemu: Convert confusing append to override syntax recipes-devtools/python: Convert confusing appends to override syntax
musl-locales: Fix locale-base-sr-sr typo

 meta/conf/distro/include/no-gplv3.inc                    |  4 ++--
 meta/conf/machine/include/powerpc/tune-power5.inc        |  3 +--
 meta/conf/machine/include/powerpc/tune-power6.inc        |  3 +--
 meta/conf/machine/include/powerpc/tune-power7.inc        |  3 +--
 meta/recipes-core/coreutils/coreutils_9.10.bb            |  4 ++--
 meta/recipes-core/expat/expat_2.7.4.bb                   |  2 +-
 meta/recipes-core/musl/musl-locales_git.bb               |  2 +-
 meta/recipes-core/ovmf/ovmf_git.bb                       |  2 +-
 meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb    | 10 +++++-----
 meta/recipes-devtools/dnf/dnf_4.24.0.bb                  |  2 +-
 meta/recipes-devtools/python/python3-asn1crypto_1.5.1.bb |  2 +-
 meta/recipes-devtools/python/python3-bcrypt_5.0.0.bb     |  2 +-
 meta/recipes-devtools/python/python3-chardet_5.2.0.bb    |  2 +-
 meta/recipes-devtools/python/python3-cython_3.2.4.bb     |  4 ++--
 meta/recipes-devtools/python/python3-ply_3.11.bb         |  2 +-
 meta/recipes-devtools/python/python3-pyasn1_0.6.2.bb     |  2 +-
 meta/recipes-devtools/python/python3-pycparser_3.0.bb    |  4 ++--
 meta/recipes-devtools/python/python3-pysocks_1.7.1.bb    |  2 +-
 meta/recipes-devtools/python/python3-pytz_2025.2.bb      |  2 +-
 meta/recipes-devtools/qemu/qemu_10.2.0.bb                |  2 +-
 meta/recipes-extended/pigz/pigz_2.8.bb                   |  2 +-
 meta/recipes-kernel/systemtap/systemtap_5.4.bb           |  2 +-
 meta/recipes-support/libffi/libffi_3.5.2.bb              |  2 +-
 23 files changed, 31 insertions(+), 34 deletions(-)

---
base-commit: 2dc4d2f8b5c7a6e87291385fb860436593767199
change-id: 20260314-fix-invalid-appends-cf5197ef2f07

Best regards,

Signature · 1 line
Michal Sieron <[email protected]>
#1 lore raw

PATCH v3 1/13 libffi: Convert confusing append to assignment

While in this case override caused by EXTRA_OECONF:class-native += is desirable, the += can be confusing. Let's avoid that and use explicit assignment.

---
 meta/recipes-support/libffi/libffi_3.5.2.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-support/libffi/libffi_3.5.2.bb +1 -1
index f648a33a46..97c8996a38 100644
@@ -16,7 +16,7 @@ SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/${BPN}-${PV}.tar.gz \
 SRC_URI[sha256sum] = "f3a3082a23b37c293a4fcd1053147b371f2ff91fa7ea1b2a52e335676bac82dc"
 
 EXTRA_OECONF += "--disable-builddir --disable-exec-static-tramp"
-EXTRA_OECONF:class-native += "--with-gcc-arch=generic"
+EXTRA_OECONF:class-native = "--with-gcc-arch=generic"
 EXTRA_OEMAKE:class-target = "LIBTOOLFLAGS='--tag=CC'"
 
 inherit autotools texinfo multilib_header github-releases
Signature · 1 line
2.53.0
#2 lore raw

PATCH v3 2/13 coreutils: Convert confusing append to override syntax

In reply to Michal Sieron

:class-target overrides for PACKAGE_BEFORE_PN and RDEPENDS:coreutils were being appended to with the coreutils-stdbuf, but instead of being an append only for target builds, it was actually overriding those variables.

One could replace :class-target += with :append:class-target =, but I don't think there is actually any need for this to be :class-target specific. RPROVIDES:coreutils few lines below doesn't use that override.

---
 meta/recipes-core/coreutils/coreutils_9.10.bb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
meta/recipes-core/coreutils/coreutils_9.10.bb +2 -2
index 984c5b5292..fb254d047d 100644
@@ -66,9 +66,9 @@ sbindir_progs = "chroot"
 # coreutils-stdbuf without getting the rest of coreutils, but make
 # coreutils itself pull in stdbuf, so IMAGE_INSTALL += "coreutils"
 # always provides all coreutils
-PACKAGE_BEFORE_PN:class-target += "${@bb.utils.contains('PACKAGECONFIG', 'single-binary', '', 'coreutils-stdbuf', d)}"
+PACKAGE_BEFORE_PN += "${@bb.utils.contains('PACKAGECONFIG', 'single-binary', '', 'coreutils-stdbuf', d)}"
 FILES:coreutils-stdbuf = "${bindir}/stdbuf ${libdir}/coreutils/libstdbuf.so"
-RDEPENDS:coreutils:class-target += "${@bb.utils.contains('PACKAGECONFIG', 'single-binary', '', 'coreutils-stdbuf', d)}"
+RDEPENDS:coreutils += "${@bb.utils.contains('PACKAGECONFIG', 'single-binary', '', 'coreutils-stdbuf', d)}"
 
 # However, when the single-binary PACKAGECONFIG is used, stdbuf
 # functionality is built into the single coreutils binary, so there's
Signature · 1 line
2.53.0
#3 lore raw

PATCH v3 3/13 expat: Convert confusing append to assignment

In reply to Michal Sieron

This is the only assignment to EXTRA_OECMAKE in this recipe, so using +=, especially to a variable with an override can be confusing. Let's avoid that and use explicit assignment.

---
 meta/recipes-core/expat/expat_2.7.4.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-core/expat/expat_2.7.4.bb +1 -1
index 95a1ed52c4..a464f7c703 100644
@@ -17,7 +17,7 @@ UPSTREAM_CHECK_REGEX = "releases/tag/R_(?P<pver>.+)"
 
 SRC_URI[sha256sum] = "e6af11b01e32e5ef64906a5cca8809eabc4beb7ff2f9a0e6aabbd42e825135d0"
 
-EXTRA_OECMAKE:class-native += "-DEXPAT_BUILD_DOCS=OFF"
+EXTRA_OECMAKE:class-native = "-DEXPAT_BUILD_DOCS=OFF"
 
 RDEPENDS:${PN}-ptest += "bash"
 
Signature · 1 line
2.53.0
#4 lore raw

PATCH v3 4/13 tune-power[567]: Remove confusing overrides

In reply to Michal Sieron

The overrides for GLIBC_EXTRA_OECONF are confusing especially with combination with += style append. If there would be any value set prior, it would be overriden as for conditional append override style :append should be used.

As all other tune-power* configs append to GLIBC_EXTRA_OECONF without any override, let's align those to them and drop the override.

---
 meta/conf/machine/include/powerpc/tune-power5.inc | 3 +--
 meta/conf/machine/include/powerpc/tune-power6.inc | 3 +--
 meta/conf/machine/include/powerpc/tune-power7.inc | 3 +--
 3 files changed, 3 insertions(+), 6 deletions(-)
meta/conf/machine/include/powerpc/tune-power5.inc +1 -2
index e70e401217..eb8e51ba3a 100644
@@ -17,8 +17,7 @@ TUNE_PKGARCH:tune-ppc64p5 = "ppc64p5"
 PACKAGE_EXTRA_ARCHS:tune-ppc64p5 = "${PACKAGE_EXTRA_ARCHS:tune-powerpc64} ppc64p5"
 
 # glibc configure options to get power5 specific library
-GLIBC_EXTRA_OECONF:powerpc64 += "${@bb.utils.contains('TUNE_FEATURES', 'power5', '--with-cpu=power5', '', d)}"
-GLIBC_EXTRA_OECONF:powerpc += "${@bb.utils.contains('TUNE_FEATURES', 'power5', '--with-cpu=power5', '', d)}"
+GLIBC_EXTRA_OECONF += "${@bb.utils.contains('TUNE_FEATURES', 'power5', ' --with-cpu=power5', '', d)}"
 
 # QEMU usermode fails with invalid instruction error
 MACHINE_FEATURES_BACKFILL_CONSIDERED:append = "${@bb.utils.contains('TUNE_FEATURES', 'power5', ' qemu-usermode', '', d)}"
meta/conf/machine/include/powerpc/tune-power6.inc +1 -2
index eaf89515ca..ef6d0f5a50 100644
@@ -17,8 +17,7 @@ TUNE_PKGARCH:tune-ppc64p6 = "ppc64p6"
 PACKAGE_EXTRA_ARCHS:tune-ppc64p6 = "${PACKAGE_EXTRA_ARCHS:tune-powerpc64} ppc64p6"
 
 # glibc configure options to get power6 specific library
-GLIBC_EXTRA_OECONF:powerpc64 += "${@bb.utils.contains('TUNE_FEATURES', 'power6', '--with-cpu=power6', '', d)}"
-GLIBC_EXTRA_OECONF:powerpc += "${@bb.utils.contains('TUNE_FEATURES', 'power6', '--with-cpu=power6', '', d)}"
+GLIBC_EXTRA_OECONF += "${@bb.utils.contains('TUNE_FEATURES', 'power6', ' --with-cpu=power6', '', d)}"
 
 # QEMU usermode fails with invalid instruction error
 MACHINE_FEATURES_BACKFILL_CONSIDERED:append = "${@bb.utils.contains('TUNE_FEATURES', 'power6', ' qemu-usermode', '', d)}"
meta/conf/machine/include/powerpc/tune-power7.inc +1 -2
index 4531ddd85f..0e4647ac11 100644
@@ -17,8 +17,7 @@ TUNE_PKGARCH:tune-ppc64p7 = "ppc64p7"
 PACKAGE_EXTRA_ARCHS:tune-ppc64p7 = "${PACKAGE_EXTRA_ARCHS:tune-powerpc64} ppc64p7"
 
 # glibc configure options to get power7 specific library
-GLIBC_EXTRA_OECONF:powerpc64 += "${@bb.utils.contains('TUNE_FEATURES', 'power7', '--with-cpu=power7', '', d)}"
-GLIBC_EXTRA_OECONF:powerpc += "${@bb.utils.contains('TUNE_FEATURES', 'power7', '--with-cpu=power7', '', d)}"
+GLIBC_EXTRA_OECONF += "${@bb.utils.contains('TUNE_FEATURES', 'power7', ' --with-cpu=power7', '', d)}"
 
 # QEMU usermode fails with invalid instruction error
 MACHINE_FEATURES_BACKFILL_CONSIDERED:append = "${@bb.utils.contains('TUNE_FEATURES', 'power7', ' qemu-usermode', '', d)}"
Signature · 1 line
2.53.0
#5 lore raw

PATCH v3 5/13 no-gplv3.inc: Convert confusing appends to override syntax

In reply to Michal Sieron

While in this case CORE_IMAGE_EXTRA_INSTALL::pn-* += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:pn-* = syntax here.

---
 meta/conf/distro/include/no-gplv3.inc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
meta/conf/distro/include/no-gplv3.inc +2 -2
index 705e05319a..2034204035 100644
@@ -18,9 +18,9 @@ PACKAGECONFIG:remove:pn-bluez5 = "readline"
 # dnf pulls in gpg which is gpl3; it also pulls in python3-rpm which pulls in rpm-build which pulls in bash
 # so install rpm but not dnf
 IMAGE_FEATURES:remove:pn-core-image-weston = "package-management"
-CORE_IMAGE_EXTRA_INSTALL:pn-core-image-weston += "rpm"
+CORE_IMAGE_EXTRA_INSTALL:append:pn-core-image-weston = " rpm"
 IMAGE_FEATURES:remove:pn-core-image-full-cmdline = "package-management"
-CORE_IMAGE_EXTRA_INSTALL:pn-core-image-full-cmdline += "rpm"
+CORE_IMAGE_EXTRA_INSTALL:append:pn-core-image-full-cmdline = " rpm"
 
 # matchbox-terminal depends on vte, which is gpl3
 CORE_IMAGE_BASE_INSTALL:remove:pn-core-image-weston = "matchbox-terminal"
Signature · 1 line
2.53.0
#6 lore raw

PATCH v3 6/13 bootchart2: Convert confusing appends to override syntax

In reply to Michal Sieron

While in this case RDEPENDS:${PN}:class-target += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:class-target = syntax here.

Also moving BBCLASSEXTEND to the bottom to conform to the style guide.

---
 meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb +5 -5
index 922e665028..013a86bf78 100644
@@ -106,9 +106,6 @@ ALTERNATIVE:${PN} = "bootchartd"
 ALTERNATIVE_LINK_NAME[bootchartd] = "${base_sbindir}/bootchartd"
 ALTERNATIVE_PRIORITY = "100"
 
-# The only reason to build bootchart2-native is for a native pybootchartgui.
-BBCLASSEXTEND = "native"
-
 SYSTEMD_SERVICE:${PN} = "bootchart2.service bootchart2-done.service bootchart2-done.timer"
 
 UPDATERCPN = "bootchartd-stop-initscript"
@@ -150,8 +147,8 @@ do_install () {
 PACKAGES =+ "pybootchartgui"
 FILES:pybootchartgui += "${PYTHON_SITEPACKAGES_DIR}/pybootchartgui ${bindir}/pybootchartgui"
 RDEPENDS:pybootchartgui = "python3-pycairo python3-compression python3-image python3-math python3-shell python3-compression python3-codecs"
-RDEPENDS:${PN}:class-target += "${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
-RDEPENDS:${PN}:class-target += "lsb-release"
+RDEPENDS:${PN}:append:class-target = " ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
+RDEPENDS:${PN}:append:class-target = " lsb-release"
 DEPENDS:append:class-native = " python3-pycairo-native"
 
 PACKAGES =+ "bootchartd-stop-initscript"
@@ -164,3 +161,6 @@ FILES:${PN} += "${libdir}"
 FILES:${PN}-doc += "${datadir}/docs"
 
 RCONFLICTS:${PN} = "bootchart"
+
+# The only reason to build bootchart2-native is for a native pybootchartgui.
+BBCLASSEXTEND = "native"
Signature · 1 line
2.53.0
#7 lore raw

PATCH v3 7/13 pigz: Convert confusing append to override syntax

In reply to Michal Sieron

In this case PROVIDES:class-native += doesn't override the default provide of ${PN} only because that one is :prepended and thus cannot be overriden. To avoid any surprises in the future let's use :append:class-native = syntax here.

---
 meta/recipes-extended/pigz/pigz_2.8.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-extended/pigz/pigz_2.8.bb +1 -1
index fcf0c93e41..d4640eddce 100644
@@ -10,7 +10,7 @@ LIC_FILES_CHKSUM = "file://pigz.c;md5=9ae6dee8ceba9610596ed0ada493d142;beginline
 
 SRC_URI = "http://zlib.net/${BPN}/fossils/${BP}.tar.gz"
 SRC_URI[sha256sum] = "eb872b4f0e1f0ebe59c9f7bd8c506c4204893ba6a8492de31df416f0d5170fd0"
-PROVIDES:class-native += "gzip-native"
+PROVIDES:append:class-native = " gzip-native"
 
 # Point this at the homepage in case /fossils/ isn't updated
 UPSTREAM_CHECK_URI = "http://zlib.net/${BPN}/"
Signature · 1 line
2.53.0
#8 lore raw

PATCH v3 8/13 systemtap: Convert confusing append to override syntax

In reply to Michal Sieron

While in this case RDEPENDS:${PN}:class-target += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:class-target = syntax here.

---
 meta/recipes-kernel/systemtap/systemtap_5.4.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-kernel/systemtap/systemtap_5.4.bb +1 -1
index 254bac4d6f..f319aa54fd 100644
@@ -52,7 +52,7 @@ FILES:${PN}-runtime = "\
  ${bindir}/stapsh \
  ${libexecdir}/${BPN}/stapio \
 "
-RDEPENDS:${PN}:class-target += "${PN}-runtime"
+RDEPENDS:${PN}:append:class-target = " ${PN}-runtime"
 
 PACKAGES =+ "${PN}-examples"
 FILES:${PN}-examples = "${datadir}/${BPN}/examples/"
Signature · 1 line
2.53.0
#9 lore raw

PATCH v3 9/13 ovmf: Convert confusing append to override syntax

In reply to Michal Sieron

The only reason why this append wasn't overriding qemu-system-native entry from the line above is because that one was also defined with :class-target override. To avoid any surprises in the future let's use :append:class-target = syntax here.

---
 meta/recipes-core/ovmf/ovmf_git.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-core/ovmf/ovmf_git.bb +1 -1
index ec6c3b516c..6f9390e6d4 100644
@@ -247,7 +247,7 @@ FILES:ovmf-shell-efi = " \
 
 DEPLOYDEP = ""
 DEPLOYDEP:class-target = "qemu-system-native:do_populate_sysroot"
-DEPLOYDEP:class-target += " ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'openssl-native:do_populate_sysroot', '', d)}"
+DEPLOYDEP:append:class-target = " ${@bb.utils.contains('PACKAGECONFIG', 'secureboot', 'openssl-native:do_populate_sysroot', '', d)}"
 do_deploy[depends] += "${DEPLOYDEP}"
 
 do_deploy() {
Signature · 1 line
2.53.0
#10 lore raw

PATCH v3 10/13 dnf: Convert confusing append to override syntax

In reply to Michal Sieron

While in this case RRECOMMENDS:${PN}:class-target += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:class-target = syntax here.

---
 meta/recipes-devtools/dnf/dnf_4.24.0.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/dnf/dnf_4.24.0.bb +1 -1
index d40b85c4b0..832b96c929 100644
@@ -55,7 +55,7 @@ RDEPENDS:${PN} += " \
 
 RDEPENDS:${PN}:class-native = ""
 
-RRECOMMENDS:${PN}:class-target += "gnupg"
+RRECOMMENDS:${PN}:append:class-target = " gnupg"
 
 # Create a symlink called 'dnf' as 'make install' does not do it, but
 # .spec file in dnf source tree does (and then Fedora and dnf documentation
Signature · 1 line
2.53.0
#11 lore raw

PATCH v3 11/13 qemu: Convert confusing append to override syntax

In reply to Michal Sieron

While in this case RDEPENDS:${PN}-common:class-target += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:class-target = syntax here.

---
 meta/recipes-devtools/qemu/qemu_10.2.0.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/qemu/qemu_10.2.0.bb +1 -1
index 5d544d8d13..1abc035a47 100644
@@ -9,7 +9,7 @@ DEPENDS:append:libc-musl = " libucontext"
 CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '', '-DEGL_NO_X11=1', d)}"
 LDFLAGS:append:toolchain-clang:x86 = " -latomic"
 
-RDEPENDS:${PN}-common:class-target += "bash"
+RDEPENDS:${PN}-common:append:class-target = " bash"
 
 EXTRA_OECONF:append:class-target = " --target-list=${@get_qemu_target_list(d)}"
 EXTRA_OECONF:append:class-target:mipsarcho32 = "${@bb.utils.contains('BBEXTENDCURR', 'multilib', ' --disable-capstone', '', d)}"
Signature · 1 line
2.53.0
#12 lore raw

PATCH v3 12/13 recipes-devtools/python: Convert confusing appends to override syntax

In reply to Michal Sieron

While in this case RDEPENDS:class-native += wouldn't result in any unwanted override, there is no guarantee there won't be a change, which would be hidden by this override. To avoid any surprises in the future let's use :append:class-target = syntax here.

---
 meta/recipes-devtools/python/python3-asn1crypto_1.5.1.bb | 2 +-
 meta/recipes-devtools/python/python3-bcrypt_5.0.0.bb     | 2 +-
 meta/recipes-devtools/python/python3-chardet_5.2.0.bb    | 2 +-
 meta/recipes-devtools/python/python3-cython_3.2.4.bb     | 4 ++--
 meta/recipes-devtools/python/python3-ply_3.11.bb         | 2 +-
 meta/recipes-devtools/python/python3-pyasn1_0.6.2.bb     | 2 +-
 meta/recipes-devtools/python/python3-pycparser_3.0.bb    | 4 ++--
 meta/recipes-devtools/python/python3-pysocks_1.7.1.bb    | 2 +-
 meta/recipes-devtools/python/python3-pytz_2025.2.bb      | 2 +-
 9 files changed, 11 insertions(+), 11 deletions(-)
meta/recipes-devtools/python/python3-asn1crypto_1.5.1.bb +1 -1
index 322497b09b..0449438ebe 100644
@@ -10,7 +10,7 @@ SRC_URI[sha256sum] = "13ae38502be632115abf8a24cbe5f4da52e3b5231990aff31123c80530
 
 inherit pypi setuptools3
 
-RDEPENDS:${PN}:class-target += " \
+RDEPENDS:${PN}:append:class-target = " \
     python3-codecs \
     python3-crypt \
     python3-ctypes \
meta/recipes-devtools/python/python3-bcrypt_5.0.0.bb +1 -1
index 6397ecd818..f803f28ddf 100644
@@ -14,7 +14,7 @@ CARGO_SRC_DIR = "src/_bcrypt"
 
 require ${BPN}-crates.inc
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-cffi \
     python3-ctypes \
     python3-shell \
meta/recipes-devtools/python/python3-chardet_5.2.0.bb +1 -1
index 9acbeeb3f2..1b4600f00b 100644
@@ -14,7 +14,7 @@ FILES:${PN}-cli += " \
 
 RDEPENDS:${PN}-cli = "${PN} "
 
-RDEPENDS:${PN}:class-target += " \
+RDEPENDS:${PN}:append:class-target = " \
     python3-logging \
 "
 
meta/recipes-devtools/python/python3-cython_3.2.4.bb +2 -2
index 3e889857e1..c39473be7b 100644
@@ -25,7 +25,7 @@ do_install:append() {
     mv ${D}${bindir}/cygdb ${D}${bindir}/cygdb3
 }
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-misc \
     python3-netserver \
     python3-pkgutil \
@@ -35,7 +35,7 @@ RDEPENDS:${PN}:class-target += "\
     python3-xml \
 "
 
-RDEPENDS:${PN}:class-nativesdk += "\
+RDEPENDS:${PN}:append:class-nativesdk = " \
     nativesdk-python3-misc \
     nativesdk-python3-netserver \
     nativesdk-python3-pkgutil \
meta/recipes-devtools/python/python3-ply_3.11.bb +1 -1
index 2c5fa3f215..69c0b839c6 100644
@@ -9,7 +9,7 @@ SRC_URI[sha256sum] = "00c7c1aaa88358b9c765b6d3000c6eec0ba42abca5351b095321aef446
 
 inherit pypi setuptools3
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-netclient \
     python3-shell \
 "
meta/recipes-devtools/python/python3-pyasn1_0.6.2.bb +1 -1
index 01157e251e..a6eb561bf4 100644
@@ -7,7 +7,7 @@ SRC_URI[sha256sum] = "9b59a2b25ba7e4f8197db7686c09fb33e658b98339fadb826e95126290
 
 inherit pypi python_setuptools_build_meta ptest-python-pytest
 
-RDEPENDS:${PN}:class-target += " \
+RDEPENDS:${PN}:append:class-target = " \
     python3-codecs \
     python3-logging \
     python3-math \
meta/recipes-devtools/python/python3-pycparser_3.0.bb +2 -2
index c17be9b2d4..ef6f48d0e5 100644
@@ -9,11 +9,11 @@ inherit pypi python_setuptools_build_meta
 
 BBCLASSEXTEND = "native nativesdk"
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-netclient \
 "
 
-RSUGGESTS:${PN}:class-target += "\
+RSUGGESTS:${PN}:append:class-target = " \
     cpp \
     cpp-symlinks \
     "
meta/recipes-devtools/python/python3-pysocks_1.7.1.bb +1 -1
index 207d15d702..db1410ce82 100644
@@ -9,7 +9,7 @@ PYPI_PACKAGE = "PySocks"
 
 inherit pypi setuptools3
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-email \
     python3-io \
     python3-logging \
meta/recipes-devtools/python/python3-pytz_2025.2.bb +1 -1
index 86bfceadc8..07ae7ac702 100644
@@ -9,7 +9,7 @@ PTEST_PYTEST_DIR = "pytz/tests"
 
 SRC_URI[sha256sum] = "360b9e3dbb49a209c21ad61809c7fb453643e048b38924c765813546746e81c3"
 
-RDEPENDS:${PN}:class-target += "\
+RDEPENDS:${PN}:append:class-target = " \
     python3-datetime \
     python3-doctest \
     python3-io \
Signature · 1 line
2.53.0
#13 lore raw

PATCH v3 13/13 musl-locales: Fix locale-base-sr-sr typo

In reply to Michal Sieron

Package name is locale-base-sr->>rs<<.

---
 meta/recipes-core/musl/musl-locales_git.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-core/musl/musl-locales_git.bb +1 -1
index 3573a32062..f8369509e7 100644
@@ -96,7 +96,7 @@ RRECOMMENDS:locale-base-nb-no += "${PN}"
 RRECOMMENDS:locale-base-nl-nl += "${PN}"
 RRECOMMENDS:locale-base-pt-br += "${PN}"
 RRECOMMENDS:locale-base-ru-ru += "${PN}"
-RRECOMMENDS:locale-base-sr-sr += "${PN}"
+RRECOMMENDS:locale-base-sr-rs += "${PN}"
 RRECOMMENDS:locale-base-sv-se += "${PN}"
 
 UPSTREAM_CHECK_COMMITS = "1"
Signature · 1 line
2.53.0
#14 lore raw
In reply to Michal Sieron

this version looks good.

Quoted 87 lines · Michal Sieron via lists.openembedded.org

This patchset fixes several findings for variable assignments of form:

    A:someoverride += "foo"

and transforms them into:
A:append:someoverride = " foo"

In most of those cases I assume the original intent was to have a conditional append, but what was actually happening was append to a conditional override.

I first noticed such problem in our internal recipes and bbappends, but then I decided to check if similar issue exists upstream and turns out it does.

---
Changes in v3:
- Use normal assignment in libffi and expat instead
- Fix package name typo in musl-locales
- Link to v2:
https://lore.kernel.org/r/[email protected]

Changes in v2:
- Split initial single commit into smaller ones
- Described actual impact on the overriden variables
- Added some recipes that I missed last time
- Link to v1:
https://lore.kernel.org/r/[email protected]

---
Michal Sieron (13):
libffi: Convert confusing append to assignment
coreutils: Convert confusing append to override syntax
expat: Convert confusing append to assignment tune-power[567]: Remove confusing overrides
no-gplv3.inc: Convert confusing appends to override syntax
bootchart2: Convert confusing appends to override syntax
pigz: Convert confusing append to override syntax
systemtap: Convert confusing append to override syntax
ovmf: Convert confusing append to override syntax
dnf: Convert confusing append to override syntax
qemu: Convert confusing append to override syntax recipes-devtools/python: Convert confusing appends to override syntax
musl-locales: Fix locale-base-sr-sr typo

 meta/conf/distro/include/no-gplv3.inc                    |  4 ++--
 meta/conf/machine/include/powerpc/tune-power5.inc        |  3 +--
 meta/conf/machine/include/powerpc/tune-power6.inc        |  3 +--
 meta/conf/machine/include/powerpc/tune-power7.inc        |  3 +--
 meta/recipes-core/coreutils/coreutils_9.10.bb            |  4 ++--
 meta/recipes-core/expat/expat_2.7.4.bb                   |  2 +-
 meta/recipes-core/musl/musl-locales_git.bb               |  2 +-
 meta/recipes-core/ovmf/ovmf_git.bb                       |  2 +-
 meta/recipes-devtools/bootchart2/bootchart2_0.14.9.bb    | 10 +++++-----
 meta/recipes-devtools/dnf/dnf_4.24.0.bb                  |  2 +-
 meta/recipes-devtools/python/python3-asn1crypto_1.5.1.bb |  2 +-
 meta/recipes-devtools/python/python3-bcrypt_5.0.0.bb     |  2 +-
 meta/recipes-devtools/python/python3-chardet_5.2.0.bb    |  2 +-
 meta/recipes-devtools/python/python3-cython_3.2.4.bb     |  4 ++--
 meta/recipes-devtools/python/python3-ply_3.11.bb         |  2 +-
 meta/recipes-devtools/python/python3-pyasn1_0.6.2.bb     |  2 +-
 meta/recipes-devtools/python/python3-pycparser_3.0.bb    |  4 ++--
 meta/recipes-devtools/python/python3-pysocks_1.7.1.bb    |  2 +-
 meta/recipes-devtools/python/python3-pytz_2025.2.bb      |  2 +-
 meta/recipes-devtools/qemu/qemu_10.2.0.bb                |  2 +-
 meta/recipes-extended/pigz/pigz_2.8.bb                   |  2 +-
 meta/recipes-kernel/systemtap/systemtap_5.4.bb           |  2 +-
 meta/recipes-support/libffi/libffi_3.5.2.bb              |  2 +-
 23 files changed, 31 insertions(+), 34 deletions(-)

---
base-commit: 2dc4d2f8b5c7a6e87291385fb860436593767199
change-id: 20260314-fix-invalid-appends-cf5197ef2f07

Best regards,
--
Michal Sieron <[email protected]>

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#233335):
https://lists.openembedded.org/g/openembedded-core/message/233335
Mute This Topic: https://lists.openembedded.org/mt/118372180/1997914
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-