[gnome-builder/gnome-builder-3-28] help: fix get_option() to check for proper value



commit c18a0d4409b9f168df3115cbf9ccf1f95151dcbf
Author: Christian Hergert <chergert redhat com>
Date:   Wed Aug 8 13:03:50 2018 -0700

    help: fix get_option() to check for proper value
    
    We want to check for help docs, not sdk docs. Also, if enabled, don't be
    automatic about it. Fail hard so the caller knows there is an issue.

 doc/help/meson.build | 18 ++++++++----------
 1 file changed, 8 insertions(+), 10 deletions(-)
---
diff --git a/doc/help/meson.build b/doc/help/meson.build
index 1336e6a26..e684f078c 100644
--- a/doc/help/meson.build
+++ b/doc/help/meson.build
@@ -1,15 +1,13 @@
-if get_option('with_docs')
+if get_option('with_help')
 
-sphinx = find_program(['sphinx-build-3', 'sphinx-build'], required: false)
+sphinx = find_program(['sphinx-build-3', 'sphinx-build'], required: true)
 
-if sphinx.found()
-    custom_target('en user documentation',
-                  command: [sphinx, '-b', 'html', '-c', meson.current_source_dir(), 
meson.current_source_dir(), '@OUTPUT@'],
-                   output: 'en',
-         build_by_default: true)
+custom_target('en user documentation',
+           command: [sphinx, '-b', 'html', '-c', meson.current_source_dir(), meson.current_source_dir(), 
'@OUTPUT@'],
+            output: 'en',
+  build_by_default: true
+)
 
-
-    install_subdir(meson.current_build_dir() + '/en', install_dir: pkgdocdir_abs)
-endif
+install_subdir(meson.current_build_dir() + '/en', install_dir: pkgdocdir_abs)
 
 endif


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