diff options
author | Peter Kjellerstedt <pkj@axis.com> | 2025-04-05 03:32:57 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-04-08 15:49:17 +0100 |
commit | 35e4c46d068215250e5f89269f2012d0e051f5f5 (patch) | |
tree | ed844e7a0ef09216f862eb8f31e4e15698da93bc | |
parent | 381f21f86126905a51d13d129241159c3778b181 (diff) | |
download | poky-35e4c46d068215250e5f89269f2012d0e051f5f5.tar.gz |
insane.bbclass: Move test for invalid PACKAGECONFIGs to do_recipe_qa
This makes sure invalid PACKAGECONFIGs are reported also for recipes
that have no do_configure task, e.g., packagegroups.
(From OE-Core rev: d3325c384a7df54c564cae093659cf7b692629f2)
Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes-global/insane.bbclass | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/meta/classes-global/insane.bbclass b/meta/classes-global/insane.bbclass index fc4ca84b35..748de050e0 100644 --- a/meta/classes-global/insane.bbclass +++ b/meta/classes-global/insane.bbclass | |||
@@ -1418,16 +1418,6 @@ Rerun configure task after fixing this.""" | |||
1418 | except subprocess.CalledProcessError: | 1418 | except subprocess.CalledProcessError: |
1419 | pass | 1419 | pass |
1420 | 1420 | ||
1421 | # Check invalid PACKAGECONFIG | ||
1422 | pkgconfig = (d.getVar("PACKAGECONFIG") or "").split() | ||
1423 | if pkgconfig: | ||
1424 | pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {} | ||
1425 | for pconfig in pkgconfig: | ||
1426 | if pconfig not in pkgconfigflags: | ||
1427 | pn = d.getVar('PN') | ||
1428 | error_msg = "%s: invalid PACKAGECONFIG: %s" % (pn, pconfig) | ||
1429 | oe.qa.handle_error("invalid-packageconfig", error_msg, d) | ||
1430 | |||
1431 | oe.qa.exit_if_errors(d) | 1421 | oe.qa.exit_if_errors(d) |
1432 | } | 1422 | } |
1433 | 1423 | ||
@@ -1475,10 +1465,20 @@ python do_recipe_qa() { | |||
1475 | if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url) or "//codeload.github.com/" in url: | 1465 | if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url) or "//codeload.github.com/" in url: |
1476 | oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) | 1466 | oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) |
1477 | 1467 | ||
1468 | def test_packageconfig(pn, d): | ||
1469 | pkgconfigs = (d.getVar("PACKAGECONFIG") or "").split() | ||
1470 | if pkgconfigs: | ||
1471 | pkgconfigflags = d.getVarFlags("PACKAGECONFIG") or {} | ||
1472 | for pkgconfig in pkgconfigs: | ||
1473 | if pkgconfig not in pkgconfigflags: | ||
1474 | error_msg = "%s: invalid PACKAGECONFIG: %s" % (pn, pkgconfig) | ||
1475 | oe.qa.handle_error("invalid-packageconfig", error_msg, d) | ||
1476 | |||
1478 | pn = d.getVar('PN') | 1477 | pn = d.getVar('PN') |
1479 | test_missing_metadata(pn, d) | 1478 | test_missing_metadata(pn, d) |
1480 | test_missing_maintainer(pn, d) | 1479 | test_missing_maintainer(pn, d) |
1481 | test_srcuri(pn, d) | 1480 | test_srcuri(pn, d) |
1481 | test_packageconfig(pn, d) | ||
1482 | oe.qa.exit_if_errors(d) | 1482 | oe.qa.exit_if_errors(d) |
1483 | } | 1483 | } |
1484 | 1484 | ||