diff options
author | Markus Volk <f_l_k@t-online.de> | 2023-08-29 08:07:59 +0200 |
---|---|---|
committer | Bruce Ashfield <bruce.ashfield@gmail.com> | 2023-09-04 03:03:14 +0000 |
commit | ecdb3aa7e144035e80bd48988d00ac68ca94f5f6 (patch) | |
tree | 216b84c285242e9f014b9160ab5d2971a9b15609 /recipes-extended | |
parent | abf22f73d15fbf28d9e3ed0f7ae556d81f79433f (diff) | |
download | meta-virtualization-ecdb3aa7e144035e80bd48988d00ac68ca94f5f6.tar.gz |
libvirt-glib: fix introspection and documentation build
Building Gobject introspection during cross-compilation is not an easy task.
Therefore, the meson.build file disables the build for introspection and
also for gtkdoc by default.
This commit adds a patch to enable this, as introspection can be easily built
on newer platforms with yocto/oe.
The options to enable/disable introspection/doc are defined as feature
while the corresponding bbclass defines it as a boolean.
Override this so that it should be possible to be enabled/disabled by using DISTRO_FEATURES.
Inherit gettext bbclass as used in libvirt-glib.
Add a missing dependency on libxslt.
Signed-off-by: Markus Volk <f_l_k@t-online.de>
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Diffstat (limited to 'recipes-extended')
-rw-r--r-- | recipes-extended/libvirt/libvirt-glib/0001-meson.build-allow-crosscompiling-gir-and-doc.patch | 37 | ||||
-rw-r--r-- | recipes-extended/libvirt/libvirt-glib_4.0.0.bb | 15 |
2 files changed, 48 insertions, 4 deletions
diff --git a/recipes-extended/libvirt/libvirt-glib/0001-meson.build-allow-crosscompiling-gir-and-doc.patch b/recipes-extended/libvirt/libvirt-glib/0001-meson.build-allow-crosscompiling-gir-and-doc.patch new file mode 100644 index 00000000..cd17bbbf --- /dev/null +++ b/recipes-extended/libvirt/libvirt-glib/0001-meson.build-allow-crosscompiling-gir-and-doc.patch | |||
@@ -0,0 +1,37 @@ | |||
1 | From 019d727990d41b5d7911895b75bcb021e4cca3c6 Mon Sep 17 00:00:00 2001 | ||
2 | From: Markus Volk <f_l_k@t-online.de> | ||
3 | Date: Mon, 21 Aug 2023 10:23:08 +0200 | ||
4 | Subject: [PATCH] meson.build: allow crosscompiling gir and doc | ||
5 | |||
6 | Upstream-Status: Inappropriate [oe specific] | ||
7 | |||
8 | Signed-off-by: Markus Volk <f_l_k@t-online.de> | ||
9 | --- | ||
10 | meson.build | 2 +- | ||
11 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
12 | |||
13 | diff --git a/meson.build b/meson.build | ||
14 | index 134feb6..a089f42 100644 | ||
15 | --- a/meson.build | ||
16 | +++ b/meson.build | ||
17 | @@ -58,7 +58,7 @@ includedir = join_paths(prefix, get_option('includedir')) | ||
18 | |||
19 | # gobject introspection | ||
20 | gir = find_program('g-ir-scanner', required: get_option('introspection')) | ||
21 | -enable_introspection = gir.found() and not meson.is_cross_build() | ||
22 | +enable_introspection = gir.found() | ||
23 | |||
24 | # vala | ||
25 | vapi_opt = get_option('vapi') | ||
26 | @@ -73,7 +73,7 @@ endif | ||
27 | # gtk-doc | ||
28 | if not get_option('docs').disabled() | ||
29 | gtk_doc = find_program('gtkdoc-scan', required: get_option('docs')) | ||
30 | - enable_doc = gtk_doc.found() and not meson.is_cross_build() | ||
31 | + enable_doc = gtk_doc.found() | ||
32 | else | ||
33 | enable_doc = false | ||
34 | endif | ||
35 | -- | ||
36 | 2.41.0 | ||
37 | |||
diff --git a/recipes-extended/libvirt/libvirt-glib_4.0.0.bb b/recipes-extended/libvirt/libvirt-glib_4.0.0.bb index a5cd8276..7ca65a95 100644 --- a/recipes-extended/libvirt/libvirt-glib_4.0.0.bb +++ b/recipes-extended/libvirt/libvirt-glib_4.0.0.bb | |||
@@ -3,12 +3,19 @@ HOMEPAGE = "http://libvirt.org" | |||
3 | LICENSE = "LGPL-2.1-only" | 3 | LICENSE = "LGPL-2.1-only" |
4 | LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c" | 4 | LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c" |
5 | 5 | ||
6 | DEPENDS = "glib-2.0 libvirt libxml2" | 6 | DEPENDS = "glib-2.0 libvirt libxml2 libxslt" |
7 | 7 | ||
8 | SRC_URI = "git://gitlab.com/libvirt/libvirt-glib;protocol=https;branch=master" | 8 | SRC_URI = " \ |
9 | git://gitlab.com/libvirt/libvirt-glib;protocol=https;branch=master \ | ||
10 | file://0001-meson.build-allow-crosscompiling-gir-and-doc.patch \ | ||
11 | " | ||
9 | 12 | ||
10 | SRCREV = "e0bfc34682744a74b850fa217e9c206a9eb80612" | 13 | SRCREV = "e0bfc34682744a74b850fa217e9c206a9eb80612" |
11 | S = "${WORKDIR}/git" | 14 | S = "${WORKDIR}/git" |
12 | 15 | ||
13 | inherit meson pkgconfig gobject-introspection vala | 16 | inherit meson pkgconfig gobject-introspection gettext vala gtk-doc |
14 | GIR_MESON_OPTION = '' | 17 | |
18 | GIR_MESON_ENABLE_FLAG = 'enabled' | ||
19 | GIR_MESON_DISABLE_FLAG = 'disabled' | ||
20 | GTKDOC_MESON_ENABLE_FLAG = 'enabled' | ||
21 | GTKDOC_MESON_DISABLE_FLAG = 'disabled' | ||