From 824bbb1f4cd062d66b457faca50f904b34dfd96c Mon Sep 17 00:00:00 2001 From: Tomi Valkeinen Date: Fri, 6 Aug 2021 13:06:14 +0300 Subject: meson: simplify pybind dependency handling --- py/pykms/meson.build | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'py/pykms') diff --git a/py/pykms/meson.build b/py/pykms/meson.build index b29cd9f..e030ce8 100644 --- a/py/pykms/meson.build +++ b/py/pykms/meson.build @@ -4,13 +4,11 @@ if py3_dep.found() == false subdir_done() endif -if get_option('system-pybind11').enabled() - pybind11_dep = dependency('pybind11') -elif get_option('system-pybind11').disabled() - pybind11_proj = subproject('pybind11') - pybind11_dep = pybind11_proj.get_variable('pybind11_dep') -else - pybind11_dep = dependency('pybind11', fallback : ['pybind11', 'pybind11_dep']) +pybind11_dep = dependency('pybind11', fallback : ['pybind11', 'pybind11_dep'], + required : get_option('pykms')) + +if pybind11_dep.found() == false + subdir_done() endif pykms_sources = files([ -- cgit v1.2.3