]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commitdiff
classes/gtk-doc: inherit python3native only if gtk-doc is enabled
authorRoss Burton <ross.burton@arm.com>
Fri, 26 Jun 2026 15:13:25 +0000 (16:13 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 30 Jun 2026 07:10:14 +0000 (08:10 +0100)
Use inherit_defer to only inherit python3native (thus, a dependency on
python3-native) when gtk-doc is actually enabled.

This is useful in native builds where gtk-doc is disabled and so will no
longer depend on python3-native.

Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes-recipe/gtk-doc.bbclass

index 9d3911966bb798267d408c3b60a184a63914c80c..33f6617e1bd5a40346835561703da5f3dbae5716 100644 (file)
@@ -35,9 +35,11 @@ DEPENDS:append = " gtk-doc-native"
 
 export STAGING_DIR_HOST
 
-inherit python3native pkgconfig qemu
+inherit pkgconfig qemu
 DEPENDS:append = "${@' qemu-native' if d.getVar('GTKDOC_ENABLED') == 'True' else ''}"
 
+inherit_defer ${@bb.utils.contains('GTKDOC_ENABLED', 'True', 'python3native', '', d)}
+
 do_compile:prepend:class-target () {
     if [ ${GTKDOC_ENABLED} = True ]; then
         # Write out a qemu wrapper that will be given to gtkdoc-scangobj so that it