]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: docs: introduce docs_rst2html_gen generator
authorPavel Hrdina <phrdina@redhat.com>
Thu, 18 Jun 2020 00:23:00 +0000 (02:23 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:06 +0000 (09:27 +0200)
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
docs/Makefile.am
docs/meson.build

index 0584702f7a1725e812c494a57682bc33c1e79c37..a2fe2fbdc751c1ba7467a7afde2168f97113d357 100644 (file)
@@ -320,10 +320,6 @@ news.html.in: $(top_srcdir)/NEWS.rst
        $(AM_V_GEN)$(MKDIR_P) `dirname $@` && \
          $(RST2HTML) --strict $< > $@ || { rm $@ && exit 1; }
 
-%.html.in: %.rst
-       $(AM_V_GEN)$(MKDIR_P) `dirname $@` && \
-         $(RST2HTML) --strict $< > $@ || { rm $@ && exit 1; }
-
 %.html.tmp: %.html.in site.xsl subsite.xsl page.xsl \
                $(acl_generated)
        $(AM_V_GEN)name=`echo $@ | sed -e 's/.tmp//'`; \
index f271c0aa2334b39796a1332b346e496d4469166f..2812c85c054cc6b3dee151f481010cce9f249d55 100644 (file)
@@ -73,3 +73,10 @@ docs_api_xml = docs_api_generated[0]
 docs_lxc_api_xml = docs_api_generated[1]
 docs_qemu_api_xml = docs_api_generated[2]
 docs_admin_api_xml = docs_api_generated[3]
+
+docs_rst2html_gen = generator(
+  rst2html_prog,
+  output: '@BASENAME@.html.in',
+  arguments: [ '--strict', '@INPUT@' ],
+  capture: true,
+)