* [PATCH 1/2] packagegroup.bbclass: Reinstate the configure task
@ 2026-03-18 21:59 Peter Kjellerstedt
2026-03-18 21:59 ` [PATCH 2/2] Revert "insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa" Peter Kjellerstedt
0 siblings, 1 reply; 3+ messages in thread
From: Peter Kjellerstedt @ 2026-03-18 21:59 UTC (permalink / raw)
To: openembedded-core
We need the qa_configure postfunc to run so that it will detect any
invalid PACKAGCONFIGs being used. Thus, the configure task needs to
exists (but it can be empty).
Signed-off-by: Peter Kjellerstedt <pkj@axis.com>
---
meta/classes-recipe/packagegroup.bbclass | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/meta/classes-recipe/packagegroup.bbclass b/meta/classes-recipe/packagegroup.bbclass
index cf6fc354a8..fe959a4284 100644
--- a/meta/classes-recipe/packagegroup.bbclass
+++ b/meta/classes-recipe/packagegroup.bbclass
@@ -49,11 +49,16 @@ DEPCHAIN_DBGDEFAULTDEPS = "1"
deltask do_fetch
deltask do_unpack
deltask do_patch
-deltask do_configure
deltask do_compile
deltask do_install
deltask do_populate_sysroot
+# We need the qa_configure postfunc to run so that it will detect any invalid
+# PACKAGCONFIGs being used. Thus, the configure task needs to remain.
+addtask configure before do_package
+do_configure() {
+}
+
do_create_runtime_spdx[deptask] = "do_create_spdx"
do_create_runtime_spdx[rdeptask] = ""
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] Revert "insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa"
2026-03-18 21:59 [PATCH 1/2] packagegroup.bbclass: Reinstate the configure task Peter Kjellerstedt
@ 2026-03-18 21:59 ` Peter Kjellerstedt
2026-03-18 23:38 ` [OE-core] " Richard Purdie
0 siblings, 1 reply; 3+ messages in thread
From: Peter Kjellerstedt @ 2026-03-18 21:59 UTC (permalink / raw)
To: openembedded-core
This reverts commit d3325c384a7df54c564cae093659cf7b692629f2.
Moving the QA test for invalid PACKAGECONFIGs to the recipe_qa task
turned out to be a bad idea as that task is expected to be architecture
independent. So move it back to the qa_configure function. The original
problem (that the configure task is not run for packagegroups) will have
to be solved in packagegroup.bbclass instead.
Signed-off-by: Peter Kjellerstedt <pkj@axis.com>
---
meta/classes-global/insane.bbclass | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass
index aeffee7983..7b13e932ff 100644
--- a/meta/classes-global/insane.bbclass
+++ b/meta/classes-global/insane.bbclass
@@ -1423,6 +1423,16 @@ Rerun configure task after fixing this."""
except subprocess.CalledProcessError:
pass
+ # Check invalid PACKAGECONFIG
+ pkgconfigs = (d.getVar("PACKAGECONFIG") or "").split()
+ if pkgconfigs:
+ pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {}
+ invalid_pkgconfigs = set(pkgconfigs) - set(pkgconfigflags)
+ if invalid_pkgconfigs:
+ pn = d.getVar('PN')
+ error_msg = "%s: invalid PACKAGECONFIG(s): %s" % (pn, " ".join(sorted(invalid_pkgconfigs)))
+ oe.qa.handle_error("invalid-packageconfig", error_msg, d)
+
oe.qa.exit_if_errors(d)
}
@@ -1484,21 +1494,11 @@ python do_recipe_qa() {
if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url) or "//codeload.github.com/" in url:
oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d)
- def test_packageconfig(pn, d):
- pkgconfigs = (d.getVar("PACKAGECONFIG") or "").split()
- if pkgconfigs:
- pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {}
- invalid_pkgconfigs = set(pkgconfigs) - set(pkgconfigflags)
- if invalid_pkgconfigs:
- error_msg = "%s: invalid PACKAGECONFIG(s): %s" % (pn, " ".join(sorted(invalid_pkgconfigs)))
- oe.qa.handle_error("invalid-packageconfig", error_msg, d)
-
pn = d.getVar('PN')
test_naming(pn, d)
test_missing_metadata(pn, d)
test_missing_maintainer(pn, d)
test_srcuri(pn, d)
- test_packageconfig(pn, d)
oe.qa.exit_if_errors(d)
}
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [OE-core] [PATCH 2/2] Revert "insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa"
2026-03-18 21:59 ` [PATCH 2/2] Revert "insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa" Peter Kjellerstedt
@ 2026-03-18 23:38 ` Richard Purdie
0 siblings, 0 replies; 3+ messages in thread
From: Richard Purdie @ 2026-03-18 23:38 UTC (permalink / raw)
To: peter.kjellerstedt, openembedded-core
Hi Peter,
On Wed, 2026-03-18 at 22:59 +0100, Peter Kjellerstedt via lists.openembedded.org wrote:
> This reverts commit d3325c384a7df54c564cae093659cf7b692629f2.
>
> Moving the QA test for invalid PACKAGECONFIGs to the recipe_qa task
> turned out to be a bad idea as that task is expected to be architecture
> independent. So move it back to the qa_configure function. The original
> problem (that the configure task is not run for packagegroups) will have
> to be solved in packagegroup.bbclass instead.
>
> Signed-off-by: Peter Kjellerstedt <pkj@axis.com>
> ---
> meta/classes-global/insane.bbclass | 20 ++++++++++----------
> 1 file changed, 10 insertions(+), 10 deletions(-)
>
> diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass
> index aeffee7983..7b13e932ff 100644
> --- a/meta/classes-global/insane.bbclass
> +++ b/meta/classes-global/insane.bbclass
> @@ -1423,6 +1423,16 @@ Rerun configure task after fixing this."""
> except subprocess.CalledProcessError:
> pass
>
> + # Check invalid PACKAGECONFIG
> + pkgconfigs = (d.getVar("PACKAGECONFIG") or "").split()
> + if pkgconfigs:
> + pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {}
> + invalid_pkgconfigs = set(pkgconfigs) - set(pkgconfigflags)
> + if invalid_pkgconfigs:
> + pn = d.getVar('PN')
> + error_msg = "%s: invalid PACKAGECONFIG(s): %s" % (pn, " ".join(sorted(invalid_pkgconfigs)))
> + oe.qa.handle_error("invalid-packageconfig", error_msg, d)
> +
> oe.qa.exit_if_errors(d)
> }
>
> @@ -1484,21 +1494,11 @@ python do_recipe_qa() {
> if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url) or "//codeload.github.com/" in url:
> oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d)
>
> - def test_packageconfig(pn, d):
> - pkgconfigs = (d.getVar("PACKAGECONFIG") or "").split()
> - if pkgconfigs:
> - pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {}
> - invalid_pkgconfigs = set(pkgconfigs) - set(pkgconfigflags)
> - if invalid_pkgconfigs:
> - error_msg = "%s: invalid PACKAGECONFIG(s): %s" % (pn, " ".join(sorted(invalid_pkgconfigs)))
> - oe.qa.handle_error("invalid-packageconfig", error_msg, d)
> -
> pn = d.getVar('PN')
> test_naming(pn, d)
> test_missing_metadata(pn, d)
> test_missing_maintainer(pn, d)
> test_srcuri(pn, d)
> - test_packageconfig(pn, d)
> oe.qa.exit_if_errors(d)
> }
Thanks for sending this. Atfer a bit of thought, I have a slightly
different idea which might be worth a try, perhaps we can put the
PACKAGECONFIG code into a function in lib/oe/qa.py and then call it
from the configure postfunc but also as a postfunc in one of the
packagegroup tasks?
I'd prefer not to reinstate the configure task if we can help it as
those tasks have "special" meanings and it is safer to remove
everything consistently if we can.
Cheers,
Richard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-03-18 23:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-18 21:59 [PATCH 1/2] packagegroup.bbclass: Reinstate the configure task Peter Kjellerstedt
2026-03-18 21:59 ` [PATCH 2/2] Revert "insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa" Peter Kjellerstedt
2026-03-18 23:38 ` [OE-core] " Richard Purdie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox