From: Andrea Bolognani Date: Thu, 27 May 2021 14:09:54 +0000 (+0200) Subject: meson: Fix disabling netcf X-Git-Tag: v7.5.0-rc1~237 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=48fc84a22c8bc541a52fae7f1575a24d132811b0;p=thirdparty%2Flibvirt.git meson: Fix disabling netcf If the feature is disabled, the corresponding flags should not show up in the compiler command line. Signed-off-by: Andrea Bolognani Reviewed-by: Pavel Hrdina --- diff --git a/meson.build b/meson.build index f81271598c..a84396f302 100644 --- a/meson.build +++ b/meson.build @@ -1025,11 +1025,13 @@ libxml_dep = dependency('libxml-2.0', version: '>=' + libxml_version) libm_dep = cc.find_library('m') netcf_version = '0.1.8' -netcf_dep = dependency('netcf', version: '>=' + netcf_version, required: get_option('netcf')) if not get_option('netcf').disabled() + netcf_dep = dependency('netcf', version: '>=' + netcf_version, required: get_option('netcf')) if netcf_dep.found() conf.set('WITH_NETCF', 1) endif +else + netcf_dep = dependency('', required: false) endif have_gnu_gettext_tools = false