[libvirt PATCH 325/351] meson: docs: build hvsupport.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Pavel Hrdina <phrdina@xxxxxxxxxx>
---
 docs/Makefile.am | 13 -------------
 docs/meson.build | 25 +++++++++++++++++++++++++
 src/meson.build  |  4 +++-
 3 files changed, 28 insertions(+), 14 deletions(-)

diff --git a/docs/Makefile.am b/docs/Makefile.am
index f1ac68f1d50..73d3d26422a 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -277,10 +277,6 @@ manpages/virkeyname-%.rst: $(top_srcdir)/src/keycodemapdb/data/keymaps.csv \
 manpagesdir = $(HTML_DIR)/manpages
 manpages_DATA = $(manpages_html)
 
-# Generate hvsupport.html first, since it takes one extra step.
-dot_html_generated_in = \
-  hvsupport.html.in \
-  $(NULL)
 dot_rst_html_in = \
   news.html.in \
   $(NULL)
@@ -295,15 +291,6 @@ html_DATA = $(dot_html)
 schemadir = $(pkgdatadir)/schemas
 schema_DATA = $(wildcard $(srcdir)/schemas/*.rng)
 
-hvsupport.html: hvsupport.html.in
-
-hvsupport.html.in: $(top_srcdir)/scripts/hvsupport.py $(api_DATA) \
-		$(top_srcdir)/src/libvirt_public.syms \
-	$(top_srcdir)/src/libvirt_qemu.syms $(top_srcdir)/src/libvirt_lxc.syms \
-	$(top_srcdir)/src/driver.h
-	$(AM_V_GEN)$(RUNUTF8) $(PYTHON) $(top_srcdir)/scripts/hvsupport.py \
-		$(top_srcdir) $(top_builddir) > $@ || { rm $@ && exit 1; }
-
 manpages/%.html.in: manpages/%.rst
 	$(AM_V_GEN)$(MKDIR_P) `dirname $@` && \
 	 grep -v '^:Manual ' < $< | \
diff --git a/docs/meson.build b/docs/meson.build
index 2da051e75ed..252f16262be 100644
--- a/docs/meson.build
+++ b/docs/meson.build
@@ -225,6 +225,31 @@ foreach name : docs_rst_files
   }
 endforeach
 
+hvsupport_html_in = custom_target(
+  'hvsupport.html.in',
+  output: 'hvsupport.html.in',
+  command: [
+    meson_python_prog,
+    hvsupport_prog,
+    meson.source_root(),
+    meson.build_root(),
+  ],
+  capture: true,
+  depend_files: [
+    public_sym_file,
+    libvirt_qemu_syms,
+    libvirt_lxc_syms,
+    driver_header,
+  ],
+  depends: [
+    docs_api_generated,
+  ],
+)
+docs_html_in_gen += {
+  'name': 'hvsupport',
+  'file': hvsupport_html_in,
+}
+
 foreach data : docs_html_in_gen
   html_file = '@0@.html'.format(data['name'])
 
diff --git a/src/meson.build b/src/meson.build
index b8ad300e558..66aa6201550 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -80,7 +80,7 @@ rpc_probe_files = []
 
 # symbol files
 
-public_sym_file = 'libvirt_public.syms'
+public_sym_file = files('libvirt_public.syms')
 
 used_sym_files = [
   'libvirt_private.syms',
@@ -299,6 +299,8 @@ driver_headers = [
   'driver-stream.h',
 ]
 
+driver_header = files('driver.h')
+
 driver_lib = static_library(
   'virt_driver',
   [
-- 
2.26.2




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux