From 8e0ba4ecd3897c748ac2f06028406604ae7baced Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Fri, 7 Feb 2014 13:46:36 +0100 Subject: Allow disabling of card support. * configure.ac: Add option --disable-card-support. Also add am_conditional and do not build scd if card support is enabled. --- configure.ac | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 9476dc48b..1db7bc882 100644 --- a/configure.ac +++ b/configure.ac @@ -1,6 +1,7 @@ # configure.ac - for GnuPG 2.1 # Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, # 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc. +# Copyright (C) 2013, 2014 Werner Koch # # This file is part of GnuPG. # @@ -87,6 +88,7 @@ use_zip=yes use_bzip2=yes use_exec=yes disable_keyserver_path=no +card_support=yes use_ccid_driver=yes use_standard_socket=yes dirmngr_auto_start=no @@ -388,6 +390,19 @@ AC_ARG_WITH(capabilities, [use_capabilities="$withval"],[use_capabilities=no]) AC_MSG_RESULT($use_capabilities) +# +# Check whether to disable the card support +AC_MSG_CHECKING([whether smartcard support is requested]) +AC_ARG_ENABLE(card-support, + AC_HELP_STRING([--disable-card-support], + [disable smartcard support]), + card_support=$enableval) +AC_MSG_RESULT($card_support) +if test "$card_support" = yes ; then + AC_DEFINE(ENABLE_CARD_SUPPORT,1,[Define to include smartcard support]) +else + build_scdaemon=no +fi # # Allow disabling of internal CCID support. @@ -547,9 +562,6 @@ AH_BOTTOM([ handler. */ #define HTTP_NO_WSASTARTUP -/* We always include support for the OpenPGP card. */ -#define ENABLE_CARD_SUPPORT 1 - /* We want to use the libgcrypt provided memory allocation for asprintf. */ #define _ESTREAM_PRINTF_REALLOC gcry_realloc @@ -1561,7 +1573,7 @@ if test "$build_agent_only" = "yes" ; then fi # -# Set variables for use by th automake makefile. +# Set variables for use by automake makefiles. # AM_CONDITIONAL(BUILD_GPG, test "$build_gpg" = "yes") AM_CONDITIONAL(BUILD_GPGSM, test "$build_gpgsm" = "yes") @@ -1574,6 +1586,8 @@ AM_CONDITIONAL(BUILD_DOC, test "$build_doc" = "yes") AM_CONDITIONAL(BUILD_SYMCRYPTRUN, test "$build_symcryptrun" = "yes") AM_CONDITIONAL(BUILD_GPGTAR, test "$build_gpgtar" = "yes") +AM_CONDITIONAL(ENABLE_CARD_SUPPORT, test "$card_support" = yes) + AM_CONDITIONAL(RUN_GPG_TESTS, test x$cross_compiling = xno -a "$build_gpg" = yes ) -- cgit v1.2.3