]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
base.bbclass: fix RRECOMMENDS extend issue for multilib
authorChangqing Li <changqing.li@windriver.com>
Tue, 10 Dec 2024 06:24:55 +0000 (14:24 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 12 Dec 2024 12:59:32 +0000 (12:59 +0000)
During handle PACKAGECONFIG, DEPENDS/RDEPENDS/RRECOMMENDS is appended by
calling function appendVar according to the PACKAGECONFIG setting:
PACKAGECONFIG[f1] = "\
    --with-f1, \
    --without-f1, \
    build-deps-for-f1, \
    runtime-deps-for-f1, \
    runtime-recommends-for-f1, \
    packageconfig-conflicts-for-f1"

[snip of base.bbclass]
 pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {}
    if pkgconfigflags:
       ...
       appendVar('DEPENDS', extradeps)
       appendVar('RDEPENDS:${PN}', extrardeps)
       appendVar('RRECOMMENDS:${PN}', extrarrecs)
       ...
[snip of base.bbclass]

After following commit in meta-oe,
[fe3ba7ac5c cryptsetup: demote udev runtime dependency to recommendation]

'udev lvm2' changed from RDEPENDS to RRECOMMENDS, but RRECOMMENDS is not
handled in this process, and causes following error:
$bitbake lib32-cryptsetup
ERROR: QA Issue: lib32-cryptsetup package lib32-cryptsetup - suspicious values 'udev lvm2' in RRECOMMENDS [multilib]

In layer openembedded-core, we do have very few recipes that have
runtime-recommends-for-f1 in PACKAGECONFIG setting, but f1 is not
enabled in PACKAGECONFIGS, so not report error when multilib is enabled.

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes-global/base.bbclass

index b81e61fdb723cef51b5dd69206db3ea7477c75e0..101ecdcf0f18f201b1c9e2918f0329a7b679325f 100644 (file)
@@ -471,7 +471,7 @@ python () {
         def appendVar(varname, appends):
             if not appends:
                 return
-            if varname.find("DEPENDS") != -1:
+            if "DEPENDS" in varname or varname.startswith("RRECOMMENDS"):
                 if bb.data.inherits_class('nativesdk', d) or bb.data.inherits_class('cross-canadian', d) :
                     appends = expandFilter(appends, "", "nativesdk-")
                 elif bb.data.inherits_class('native', d):