[Spice-devel] [PATCH spice-gtk 14/34] meson: switch gtk option to auto feature

Christophe Fergeau cfergeau at redhat.com
Mon Jan 7 14:13:57 UTC 2019


Reviewed-by: Christophe Fergeau <cfergeau at redhat.com>

On Mon, Jan 07, 2019 at 12:00:43PM +0400, marcandre.lureau at redhat.com wrote:
> From: Marc-André Lureau <marcandre.lureau at redhat.com>
> 
> Signed-off-by: Marc-André Lureau <marcandre.lureau at redhat.com>
> ---
>  meson.build       | 6 ++++--
>  meson_options.txt | 3 +--
>  2 files changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/meson.build b/meson.build
> index 91d0742..ebc846e 100644
> --- a/meson.build
> +++ b/meson.build
> @@ -128,8 +128,10 @@ endforeach
>  # gtk
>  spice_gtk_has_gtk = false
>  gtk_version_required = '3.22'
> -if get_option('gtk')
> -  spice_gtk_deps += dependency('gtk+-3.0', version : '>= @0@'.format(gtk_version_required))
> +d = dependency('gtk+-3.0', version : '>= @0@'.format(gtk_version_required),
> +               required: get_option('gtk'))
> +if d.found()
> +  spice_gtk_deps += d
>    if spice_gtk_host_system != 'windows'
>      spice_gtk_deps += dependency('epoxy')
>      spice_gtk_deps += dependency('x11')
> diff --git a/meson_options.txt b/meson_options.txt
> index 515a86b..fc130dc 100644
> --- a/meson_options.txt
> +++ b/meson_options.txt
> @@ -1,6 +1,5 @@
>  option('gtk',
> -    type : 'boolean',
> -    value : true,
> +    type : 'feature',
>      description: 'Enable gtk+')
>  
>  option('webdav',
> -- 
> 2.20.1.2.gb21ebb671b
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/spice-devel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/spice-devel/attachments/20190107/984cdf36/attachment.sig>


More information about the Spice-devel mailing list