[PATCH v2 03/13] build-sys: add --enable-pcsc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Marc-André Lureau <marcandre.lureau@xxxxxxxxxx>

Signed-off-by: Marc-André Lureau <marcandre.lureau@xxxxxxxxxx>
---
 configure.ac | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/configure.ac b/configure.ac
index b841ec1..2bc5c73 100644
--- a/configure.ac
+++ b/configure.ac
@@ -36,9 +36,36 @@ AX_CODE_COVERAGE()
 PKG_CHECK_MODULES(CACARD, [glib-2.0 >= 2.22 nss >= 3.12.8])
 PKG_CHECK_MODULES(GTHREAD, [gthread-2.0])
 
+dnl === --enable-pcsc ==========================================================
+
+AC_ARG_ENABLE([pcsc],
+              AS_HELP_STRING([--disable-pcsc],
+                             [do not build passthrough support]),,
+              [enable_pcsc=auto])
+if test "x$enable_pcsc" != "xno"; then
+   PKG_CHECK_MODULES(PCSC, [libpcsclite], [have_pcsc=yes], [have_pcsc=no])
+   if test "x$have_pcsc" = "xno" -a "x$enable_pcsc" = "xyes"; then
+      AC_MSG_ERROR([pcsc support explicitly requested, but libpcsclite couldn't be found])
+   fi
+   if test "x$have_pcsc" = "xyes"; then
+      enable_pcsc=yes
+      AC_DEFINE([ENABLE_PCSC], 1, [pcsc support])
+   fi
+fi
+AM_CONDITIONAL(ENABLE_PCSC, test "x$enable_pcsc" = "xyes")
+
 AC_CONFIG_FILES([
 Makefile
 src/Makefile
 libcacard.pc
 ])
 AC_OUTPUT
+
+AC_MSG_NOTICE([
+
+libcacard - $VERSION
+
+• Prefix: $prefix
+• PCSC enabled: $enable_pcsc
+
+])
-- 
2.4.3

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]