mirror of
https://git.yoctoproject.org/poky
synced 2026-05-09 17:39:31 +00:00
gtk-doc.bbclass: unify option setting for meson-based recipes
This is done similarly to gobject-introspection work by Andreas Müller, and allows dropping duplicate clutter from the recipes. (From OE-Core rev: ff578f4451a0a199202e576b647840910b4d3f59) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
8833afc0e0
commit
07d29e7cec
@@ -10,13 +10,24 @@
|
||||
GTKDOC_ENABLED ?= "${@bb.utils.contains('DISTRO_FEATURES', 'api-documentation', \
|
||||
bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'True', 'False', d), 'False', d)}"
|
||||
|
||||
# meson: default option name to enable/disable gtk-doc. This matches most
|
||||
# project's configuration. In doubts - check meson_options.txt in project's
|
||||
# source path.
|
||||
GTKDOC_MESON_OPTION ?= 'docs'
|
||||
GTKDOC_MESON_ENABLE_FLAG ?= 'true'
|
||||
GTKDOC_MESON_DISABLE_FLAG ?= 'false'
|
||||
|
||||
# Auto enable/disable based on GTKDOC_ENABLED
|
||||
EXTRA_OECONF_prepend_class-target = "${@bb.utils.contains('GTKDOC_ENABLED', 'True', '--enable-gtk-doc --enable-gtk-doc-html --disable-gtk-doc-pdf', \
|
||||
'--disable-gtk-doc', d)} "
|
||||
EXTRA_OEMESON_prepend_class-target = "-D${GTKDOC_MESON_OPTION}=${@bb.utils.contains('GTKDOC_ENABLED', 'True', '${GTKDOC_MESON_ENABLE_FLAG}', '${GTKDOC_MESON_DISABLE_FLAG}', d)} "
|
||||
|
||||
# When building native recipes, disable gtkdoc, as it is not necessary,
|
||||
# pulls in additional dependencies, and makes build times longer
|
||||
EXTRA_OECONF_prepend_class-native = "--disable-gtk-doc "
|
||||
EXTRA_OECONF_prepend_class-nativesdk = "--disable-gtk-doc "
|
||||
EXTRA_OEMESON_prepend_class-native = "-D${GTKDOC_MESON_OPTION}=${GTKDOC_MESON_DISABLE_FLAG} "
|
||||
EXTRA_OEMESON_prepend_class-nativesdk = "-D${GTKDOC_MESON_OPTION}=${GTKDOC_MESON_DISABLE_FLAG} "
|
||||
|
||||
# Even though gtkdoc is disabled on -native, gtk-doc package is still
|
||||
# needed for m4 macros.
|
||||
|
||||
Reference in New Issue
Block a user