[Spice-devel] [PATCH spice-gtk 22/34] build-sys: switch smartcard option to auto feature

Christophe Fergeau cfergeau at redhat.com
Mon Jan 7 15:59:35 UTC 2019


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

On Mon, Jan 07, 2019 at 12:00:51PM +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>
> ---
>  .gitlab-ci.yml    | 1 -
>  meson.build       | 5 +++--
>  meson_options.txt | 3 +--
>  3 files changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> index a3cb6ad..750e801 100644
> --- a/.gitlab-ci.yml
> +++ b/.gitlab-ci.yml
> @@ -45,7 +45,6 @@ makecheck_simple:
>  makecheck_simple-meson:
>    script:
>    - meson build -Dauto_features=disabled
> -                -Dsmartcard=false
>                  -Ddbus=false || (cat build/meson-logs/meson-log.txt && exit 1)
>    - ninja -C build
>    - (cd build && meson test) || (cat build/meson-logs/testlog.txt && exit 1)
> diff --git a/meson.build b/meson.build
> index d2df33e..26d19ed 100644
> --- a/meson.build
> +++ b/meson.build
> @@ -305,8 +305,9 @@ endif
>  
>  # smartcard check
>  spice_gtk_has_smartcard = false
> -if get_option('smartcard')
> -  spice_glib_deps += dependency('libcacard', version : '>= 2.5.1')
> +d = dependency('libcacard', version : '>= 2.5.1', required : get_option('smartcard'))
> +if d.found()
> +  spice_glib_deps += d
>    spice_gtk_config_data.set('USE_SMARTCARD', '1')
>  endif
>  
> diff --git a/meson_options.txt b/meson_options.txt
> index a16fe49..a3995f8 100644
> --- a/meson_options.txt
> +++ b/meson_options.txt
> @@ -79,6 +79,5 @@ option('opus',
>      description: 'Enable Opus audio codec')
>  
>  option('smartcard',
> -    type : 'boolean',
> -    value : true,
> +    type : 'feature',
>      description : 'Enable smartcard support')
> -- 
> 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/6be4d12d/attachment-0001.sig>


More information about the Spice-devel mailing list