meson: check for gtkdoc-scan
authorTim-Philipp Müller <tim@centricular.com>
Sat, 3 Nov 2018 00:10:19 +0000 (00:10 +0000)
committerOlivier Crête <olivier.crete@collabora.com>
Fri, 14 Dec 2018 19:47:01 +0000 (14:47 -0500)
meson.build

index 7233dea..22c9081 100644 (file)
@@ -229,8 +229,14 @@ if gst_dep.found()
   subdir('gst')
 endif
 
-if not get_option('gtk_doc').disabled()
-  subdir('docs/reference/libnice')
+if build_machine.system() == 'windows'
+  message('Disabling gtk-doc while building on Windows')
+else
+  if find_program('gtkdoc-scan', required: get_option('gtk_doc')).found()
+    subdir('docs/reference/libnice')
+  else
+    message('Not building documentation as gtk-doc was not found')
+  endif
 endif
 
 if not get_option('tests').disabled()