diff options
| author | Alexander Kanavin <alex.kanavin@gmail.com> | 2021-05-05 17:18:47 +0200 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-05-09 23:30:14 +0100 |
| commit | 7572042364dcb601f8078dff303fb6a3cc4a8466 (patch) | |
| tree | 7b25e256bd298052b308284516a7deafecc9c36f /meta/classes | |
| parent | 13e4ff2250ad965db333a9bdfb918e574fd00235 (diff) | |
| download | poky-7572042364dcb601f8078dff303fb6a3cc4a8466.tar.gz | |
gi-docgen: add a recipe and class
This seems to be the gtk-doc successor, and gnome
projects such as pango and gdk-pixbuf have started
transitioning to it.
(From OE-Core rev: f87bb7d848015c371095ef3ff423eee81e6d8ecd)
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
| -rw-r--r-- | meta/classes/gi-docgen.bbclass | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/meta/classes/gi-docgen.bbclass b/meta/classes/gi-docgen.bbclass new file mode 100644 index 0000000000..5750f7028d --- /dev/null +++ b/meta/classes/gi-docgen.bbclass | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | # gi-docgen is a new gnome documentation generator, which | ||
| 2 | # seems to be a successor to gtk-doc: | ||
| 3 | # https://gitlab.gnome.org/GNOME/gi-docgen | ||
| 4 | |||
| 5 | # This variable is set to True if api-documentation is in | ||
| 6 | # DISTRO_FEATURES, and False otherwise. | ||
| 7 | GIDOCGEN_ENABLED ?= "${@bb.utils.contains('DISTRO_FEATURES', 'api-documentation', 'True', 'False', d)}" | ||
| 8 | # When building native recipes, disable gi-docgen, as it is not necessary, | ||
| 9 | # pulls in additional dependencies, and makes build times longer | ||
| 10 | GIDOCGEN_ENABLED_class-native = "False" | ||
| 11 | GIDOCGEN_ENABLED_class-nativesdk = "False" | ||
| 12 | |||
| 13 | # meson: default option name to enable/disable gi-docgen. This matches most | ||
| 14 | # projects' configuration. In doubts - check meson_options.txt in project's | ||
| 15 | # source path. | ||
| 16 | GIDOCGEN_MESON_OPTION ?= 'gtk_doc' | ||
| 17 | GIDOCGEN_MESON_ENABLE_FLAG ?= 'true' | ||
| 18 | GIDOCGEN_MESON_DISABLE_FLAG ?= 'false' | ||
| 19 | |||
| 20 | # Auto enable/disable based on GIDOCGEN_ENABLED | ||
| 21 | EXTRA_OEMESON_prepend = "-D${GIDOCGEN_MESON_OPTION}=${@bb.utils.contains('GIDOCGEN_ENABLED', 'True', '${GIDOCGEN_MESON_ENABLE_FLAG}', '${GIDOCGEN_MESON_DISABLE_FLAG}', d)} " | ||
| 22 | |||
| 23 | DEPENDS_append = "${@' gi-docgen-native gi-docgen' if d.getVar('GIDOCGEN_ENABLED') == 'True' else ''}" | ||
| 24 | |||
