diff mbox series

[1/2] blueprint-compiler: Skip on target when GI data is not available

Message ID 20261005165412.1120027-2-luciano.dittgen@ossystems.com.br
State New
Headers show
Series Use GI_DATA_ENABLED for the python3-pygobject consumers | expand

Commit Message

Luciano Dittgen Oct. 5, 2026, 4:54 p.m. UTC
The compiler needs python3-pygobject, which skips itself on target unless
GI_DATA_ENABLED, which also needs qemu-usermode in MACHINE_FEATURES, so on
e5500/e6500 machines world has no provider for it. Skip on the same
condition; blueprint-compiler-native is unaffected. Checked with
bitbake -S none world for p5040ds, t4240rdb and t2080rdb-64b.

Signed-off-by: Luciano Dittgen <luciano.dittgen@ossystems.com.br>
---
 .../blueprint-compiler/blueprint-compiler_0.20.4.bb      | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/meta/recipes-gnome/blueprint-compiler/blueprint-compiler_0.20.4.bb b/meta/recipes-gnome/blueprint-compiler/blueprint-compiler_0.20.4.bb
index 5bd3a5439c..199a9b0f55 100644
--- a/meta/recipes-gnome/blueprint-compiler/blueprint-compiler_0.20.4.bb
+++ b/meta/recipes-gnome/blueprint-compiler/blueprint-compiler_0.20.4.bb
@@ -6,7 +6,14 @@  LIC_FILES_CHKSUM = "file://COPYING;md5=3000208d539ec061b899bce1d9ce9404"
 SRC_URI = "git://gitlab.gnome.org/GNOME/blueprint-compiler;protocol=https;branch=blueprint-0-20;tag=v${PV}"
 SRCREV = "31b62c24a72c1670d2d93dcdf2d130f1ae12778e"
 
-inherit meson pkgconfig python3-dir
+inherit meson pkgconfig python3-dir gobject-introspection-data
+
+# The compiler needs python3-pygobject on target, which is skipped without
+# GI data (which also depends on qemu-usermode), so skip along with it.
+python() {
+    if d.getVar('CLASSOVERRIDE') == "class-target" and not bb.utils.to_boolean(d.getVar("GI_DATA_ENABLED")):
+        raise bb.parse.SkipRecipe("GI not available")
+}
 
 PACKAGES += "${PN}-python"