diff options
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/meson.build b/meson.build index 81415fe5..cefc0ef2 100644 --- a/meson.build +++ b/meson.build @@ -203,6 +203,27 @@ if is_variable('cpp') subdir('bindings/cpp') endif +# Find system programs we might need for the build +cython = find_program('cython3', required: get_option('bindings_py')) +doxygen = find_program('doxygen', required: get_option('docs')) +sphinx_build = find_program( + 'sphinx-build', + required: (get_option('docs').enabled() or + (get_option('bindings_py').enabled() and + get_option('tests')))) + +docdir = get_option('datadir') / 'doc' + +# Python bindings +if not get_option('bindings_py').disabled() + pymod = import('python') + py = pymod.find_installation('python3') + py_dep = py.dependency(required: get_option('bindings_py')) + if py_dep.found() and cython.found() + subdir('bindings/python') + endif +endif + if meson.version().version_compare('>=0.53.0') summary('Tests', get_option('tests'), bool_yn: true) summary('Utilities', get_option('utils'), bool_yn: true) |