summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Withnall <philip@tecnocode.co.uk>2023-04-28 01:09:04 +0000
committerPhilip Withnall <philip@tecnocode.co.uk>2023-04-28 01:09:04 +0000
commit9b8369852b1de635124c97a7b15c987a9c9768b1 (patch)
tree91510ae8867a879cfa0eb918670c2e3038f19442
parent473063383df0ec135fd86b75b6f7f1dd20a8e2aa (diff)
parent0fa17ec3c7152cf0e1cbf965acf1426ac203bb1d (diff)
downloadglib-9b8369852b1de635124c97a7b15c987a9c9768b1.tar.gz
Merge branch 'html-doc-flag' into 'main'
meson: wrap html documentation generation with gtk_doc option See merge request GNOME/glib!3399
-rw-r--r--docs/reference/glib/meson.build58
1 files changed, 30 insertions, 28 deletions
diff --git a/docs/reference/glib/meson.build b/docs/reference/glib/meson.build
index 114de49da..3cfff2f0b 100644
--- a/docs/reference/glib/meson.build
+++ b/docs/reference/glib/meson.build
@@ -113,35 +113,37 @@ if get_option('man')
endforeach
endif
-# GVariant specification is currently standalone
-rst2html5 = find_program('rst2html5', 'rst2html5.py', required: false)
+if get_option('gtk_doc')
+ # GVariant specification is currently standalone
+ rst2html5 = find_program('rst2html5', 'rst2html5.py', required: false)
-if rst2html5.found()
- spec_path = glib_datadir / 'doc' / 'glib-2.0'
+ if rst2html5.found()
+ spec_path = glib_datadir / 'doc' / 'glib-2.0'
- figures = files(
- 'gvariant-byte-boundaries.svg',
- 'gvariant-integer-and-string-structure.svg',
- 'gvariant-integer-array.svg',
- 'gvariant-string-array.svg',
- )
+ figures = files(
+ 'gvariant-byte-boundaries.svg',
+ 'gvariant-integer-and-string-structure.svg',
+ 'gvariant-integer-array.svg',
+ 'gvariant-string-array.svg',
+ )
- custom_target('gvariant-specification-1.0',
- input: 'gvariant-specification-1.0.rst',
- output: 'gvariant-specification-1.0.html',
- command: [
- rst2html5,
- '@INPUT@',
- ],
- capture: true,
- install: true,
- install_dir: spec_path,
- install_tag: 'doc',
- depend_files: figures,
- )
+ custom_target('gvariant-specification-1.0',
+ input: 'gvariant-specification-1.0.rst',
+ output: 'gvariant-specification-1.0.html',
+ command: [
+ rst2html5,
+ '@INPUT@',
+ ],
+ capture: true,
+ install: true,
+ install_dir: spec_path,
+ install_tag: 'doc',
+ depend_files: figures,
+ )
- install_data(figures,
- install_dir : spec_path,
- install_tag : 'doc',
- )
-endif \ No newline at end of file
+ install_data(figures,
+ install_dir : spec_path,
+ install_tag : 'doc',
+ )
+ endif
+endif