]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
doc/meson: simplify checking of deps
authorVladimír Čunát <vladimir.cunat@nic.cz>
Wed, 11 Feb 2026 18:08:36 +0000 (19:08 +0100)
committerVladimír Čunát <vladimir.cunat@nic.cz>
Thu, 5 Mar 2026 09:59:40 +0000 (10:59 +0100)
This will give quite nice errors:
  doc/meson.build:39:19: ERROR: Command `/usr/bin/python3 -c 'import breathe'` failed with status 1.

doc/meson.build

index 7a36787e285f3d3e2792b96b6f6baedfdd081e1c..62ecbf9408710154de936e5ff60c5dcd7326a71c 100644 (file)
@@ -36,15 +36,8 @@ if get_option('doc') == 'enabled'
 
   # python dependencies: breathe, sphinx_rtd_theme
   python = find_program('python3')
-  python_breathe = run_command(python, '-c', 'import breathe', check: false)
-  if python_breathe.returncode() != 0
-    error('missing doc dependency: python breathe')
-  endif
-
-  python_sphinx_rtd_theme = run_command(python, '-c', 'import sphinx_rtd_theme', check: false)
-  if python_sphinx_rtd_theme.returncode() != 0
-    error('missing doc dependency: python sphinx_rtd_theme')
-  endif
+  python_breathe = run_command(python, '-c', 'import breathe', check: true)
+  python_sphinx_rtd_theme = run_command(python, '-c', 'import sphinx_rtd_theme', check: true)
 
   message('------------------------')