Running meson configure with '-Ddriver_hyperv=disabled' fails with
meson.build:1252:0: ERROR: Dependency "openwsman" not found, tried
pkgconfig and cmake
openwsman is only required if the hyperv driver is enabled. Don't
check for it if hyperv is disabled.
Signed-off-by: Jim Fehlig <jfehlig(a)suse.com>
---
There are likely other ways to fix the problem, this being a meson
noobish one :-).
meson.build | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/meson.build b/meson.build
index dabd4196e6..e3e768cab6 100644
--- a/meson.build
+++ b/meson.build
@@ -1249,7 +1249,11 @@ if numactl_dep.found()
endif
openwsman_version = '2.2.3'
-openwsman_dep = dependency('openwsman', version: '>=' +
openwsman_version, required: get_option('openwsman'))
+if get_option('driver_hyperv').enabled()
+ openwsman_dep = dependency('openwsman', version: '>=' +
openwsman_version, required: get_option('openwsman'))
+else
+ openwsman_dep = dependency('', required: false)
+endif
parallels_sdk_version = '7.0.22'
parallels_sdk_dep = dependency('parallels-sdk', version: '>=' +
parallels_sdk_version, required: false)
--
2.28.0