From d984da3fea0a6596741924bfc34ded899864abd4 Mon Sep 17 00:00:00 2001 From: Arnaud Rebillout Date: Fri, 19 Oct 2018 17:04:01 +0700 Subject: [PATCH] meson: Make avahi optional Signed-off-by: Arnaud Rebillout --- meson.build | 2 +- meson_options.txt | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index ab1ea25..03f872a 100644 --- a/meson.build +++ b/meson.build @@ -261,7 +261,7 @@ if cc.has_header('sys/soundcard.h') cdata.set_quoted('PULSEDSP_LOCATION', pulsedspdir) endif -avahi_dep = dependency('avahi-client', version : '>= 0.6.0', required : false) +avahi_dep = dependency('avahi-client', version : '>= 0.6.0', required : get_option('avahi')) if avahi_dep.found() cdata.set('HAVE_AVAHI', 1) endif diff --git a/meson_options.txt b/meson_options.txt index 683d258..3bd4b94 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -20,6 +20,9 @@ option('pulsedspdir', option('alsa', type : 'feature', value : 'auto', description : 'Optional ALSA support') +option('avahi', + type : 'feature', value : 'auto', + description : 'Optional Avahi support') option('dbus', type : 'feature', value : 'auto', description : 'Optional D-Bus support') -- 2.7.4