[Spice-commits] 3 commits - meson.build meson_options.txt server/meson.build server/smartcard.c subprojects/spice-common

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Feb 13 17:00:34 UTC 2019


 meson.build              |   30 ++++++++----------------------
 meson_options.txt        |    3 +--
 server/meson.build       |    3 ++-
 server/smartcard.c       |    4 ----
 subprojects/spice-common |    2 +-
 5 files changed, 12 insertions(+), 30 deletions(-)

New commits:
commit a8737c574081b4e437be5c5d9c57ae138df0b9ba
Author: Eduardo Lima (Etrunko) <etrunko at redhat.com>
Date:   Wed Feb 13 14:44:46 2019 -0200

    meson: switch smartcard option to auto feature
    
    Make it compatible with spice-common.
    
    Signed-off-by: Eduardo Lima (Etrunko) <etrunko at redhat.com>
    Acked-by: Frediano Ziglio <fziglio at redhat.com>

diff --git a/meson.build b/meson.build
index f822cc12..1b07f30d 100644
--- a/meson.build
+++ b/meson.build
@@ -167,14 +167,12 @@ endif
 
 # smartcard check
 spice_server_has_smartcard = false
-if get_option('smartcard')
-  smartcard_dep = dependency('libcacard', required : false, version : '>= 2.5.1')
-  if smartcard_dep.found()
-    spice_server_deps += smartcard_dep
-    spice_server_config_data.set('USE_SMARTCARD', '1')
-    spice_server_has_smartcard = true
-    spice_server_requires += 'libcacard >= 2.5.1 '
-  endif
+smartcard_dep = dependency('libcacard', required : get_option('smartcard'), version : '>= 2.5.1')
+if smartcard_dep.found()
+  spice_server_deps += smartcard_dep
+  spice_server_config_data.set('USE_SMARTCARD', '1')
+  spice_server_has_smartcard = true
+  spice_server_requires += 'libcacard >= 2.5.1 '
 endif
 
 #
diff --git a/meson_options.txt b/meson_options.txt
index 49f59cc4..d19cacb2 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -22,8 +22,7 @@ option('opus',
     description: 'Enable Opus audio codec')
 
 option('smartcard',
-    type : 'boolean',
-    value : true,
+    type : 'feature',
     description : 'Enable smartcard support')
 
 option('alignment-checks',
diff --git a/subprojects/spice-common b/subprojects/spice-common
index 2e914f33..02530a80 160000
--- a/subprojects/spice-common
+++ b/subprojects/spice-common
@@ -1 +1 @@
-Subproject commit 2e914f3305f685c82143fa04067ce9f57fbfd602
+Subproject commit 02530a80dfa45c936215c47b8e3aa56720eb46b8
commit afb2ec312bde342b8538451c6ae15a7f3bdd494f
Author: Eduardo Lima (Etrunko) <etrunko at redhat.com>
Date:   Wed Feb 13 14:44:45 2019 -0200

    meson: Bump libcacard requirement to 2.5.1
    
    This had already been done for autotools in spice-common commit
    924f47a653bd87fbd50229ee34b58d7b9a3f1ec8.
    
    Signed-off-by: Eduardo Lima (Etrunko) <etrunko at redhat.com>
    Acked-by: Frediano Ziglio <fziglio at redhat.com>

diff --git a/meson.build b/meson.build
index 459409f6..f822cc12 100644
--- a/meson.build
+++ b/meson.build
@@ -172,20 +172,9 @@ if get_option('smartcard')
   if smartcard_dep.found()
     spice_server_deps += smartcard_dep
     spice_server_config_data.set('USE_SMARTCARD', '1')
-  else
-    smartcard012_dep = dependency('libcacard', required : false, version : '>= 0.1.2')
-    if smartcard012_dep.found()
-      spice_server_deps += smartcard012_dep
-      spice_server_config_data.set('USE_SMARTCARD_012', '1')
-    endif
+    spice_server_has_smartcard = true
+    spice_server_requires += 'libcacard >= 2.5.1 '
   endif
-
-  spice_server_has_smartcard = smartcard_dep.found() or smartcard012_dep.found()
-  if not spice_server_has_smartcard
-    error('Building with smartcard support but dependency not found')
-  endif
-
-  spice_server_requires += 'libcacard >= 0.1.2 '
 endif
 
 #
diff --git a/server/smartcard.c b/server/smartcard.c
index 34cfca23..ef99056e 100644
--- a/server/smartcard.c
+++ b/server/smartcard.c
@@ -20,13 +20,9 @@
 #endif
 
 #include <arpa/inet.h>
-#ifdef USE_SMARTCARD_012
-#include <vscard_common.h>
-#else
 #ifdef USE_SMARTCARD
 #include <libcacard.h>
 #endif
-#endif
 
 #include "reds.h"
 #include "char-device.h"
commit 8abeda90f8b1f03fefa357eddaf25014dabfc22e
Author: Eduardo Lima (Etrunko) <etrunko at redhat.com>
Date:   Wed Feb 13 14:44:44 2019 -0200

    meson: Use gnu_symbol_visibility keyword introduced in meson 0.48
    
    Signed-off-by: Eduardo Lima (Etrunko) <etrunko at redhat.com>
    Acked-by: Frediano Ziglio <fziglio at redhat.com>

diff --git a/meson.build b/meson.build
index 811099c6..459409f6 100644
--- a/meson.build
+++ b/meson.build
@@ -4,7 +4,7 @@
 project('spice', 'c',
         version : run_command('build-aux/git-version-gen', '${MESON_SOURCE_ROOT}/.tarball-version', check : true).stdout().strip(),
         license : 'LGPLv2.1',
-        meson_version : '>= 0.47.2')
+        meson_version : '>= 0.48')
 
 message('Updating submodules')
 run_command('build-aux/meson/check-spice-common', check : true)
@@ -36,8 +36,7 @@ spice_server_so_version = '@0 at .@1 at .@2@'.format(spice_server_current - spice_serv
 message('libspice.so version: ' + spice_server_so_version)
 
 # some global vars
-spice_server_global_cflags = ['-fvisibility=hidden',
-                              '-DSPICE_SERVER_INTERNAL',
+spice_server_global_cflags = ['-DSPICE_SERVER_INTERNAL',
                               '-DG_LOG_DOMAIN="Spice"',
                               '-DHAVE_CONFIG_H',
                               #'-Werror',
diff --git a/server/meson.build b/server/meson.build
index 2c024120..63191d79 100644
--- a/server/meson.build
+++ b/server/meson.build
@@ -179,7 +179,8 @@ spice_server_libs = both_libraries('spice-server', spice_server_sources,
                                    include_directories : spice_server_include,
                                    link_args : compiler.get_supported_link_arguments(spice_server_link_args),
                                    link_depends : spice_server_syms,
-                                   dependencies : spice_server_deps)
+                                   dependencies : spice_server_deps,
+                                   gnu_symbol_visibility : 'hidden')
 
 spice_server_shared_lib = spice_server_libs.get_shared_lib()
 spice_server_static_lib = spice_server_libs.get_static_lib()


More information about the Spice-commits mailing list