* configure.ac: Removed OpenSC detection and options.
[gnupg.git] / acinclude.m4
index 31f5406..b8af932 100644 (file)
@@ -246,7 +246,7 @@ AC_DEFUN([GNUPG_PTH_VERSION_CHECK],
          _gnupg_pth_save_cflags=$CFLAGS
          _gnupg_pth_save_ldflags=$LDFLAGS
          _gnupg_pth_save_libs=$LIBS
-         CFLAGS="$CFLAGS `$PTH_CONFIG --ldflags`"
+         CFLAGS="$CFLAGS `$PTH_CONFIG --cflags`"
          LDFLAGS="$LDFLAGS `$PTH_CONFIG --ldflags`"
          LIBS="$LIBS `$PTH_CONFIG --libs`"
          AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <pth.h>
@@ -390,70 +390,3 @@ fi
 
 
 
-dnl AM_PATH_OPENSC([MINIMUM-VERSION,
-dnl               [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]])
-dnl Test for OpenSC and define OPENSC_CFLAGS and OPENSC_LIBS
-dnl
-AC_DEFUN([AM_PATH_OPENSC],
-[ AC_ARG_WITH(opensc-prefix,
-            AC_HELP_STRING([--with-opensc-prefix=PFX],
-                           [prefix where OpenSC is installed (optional)]),
-     opensc_config_prefix="$withval", opensc_config_prefix="")
-  if test x$opensc_config_prefix != x ; then
-     opensc_config_args="$opensc_config_args --prefix=$opensc_config_prefix"
-     if test x${OPENSC_CONFIG+set} != xset ; then
-        OPENSC_CONFIG=$opensc_config_prefix/bin/opensc-config
-     fi
-  fi
-
-  AC_PATH_PROG(OPENSC_CONFIG, opensc-config, no)
-  min_opensc_version=ifelse([$1], ,0.7.0,$1)
-  AC_MSG_CHECKING(for OpenSC - version >= $min_opensc_version)
-  ok=no
-  if test "$OPENSC_CONFIG" != "no" ; then
-    req_major=`echo $min_opensc_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\1/'`
-    req_minor=`echo $min_opensc_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\2/'`
-    req_micro=`echo $min_opensc_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\)/\3/'`
-    opensc_config_version=`$OPENSC_CONFIG $opensc_config_args --version 2>/dev/null || echo 0.0.0`
-    major=`echo $opensc_config_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\1/'`
-    minor=`echo $opensc_config_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\2/'`
-    micro=`echo $opensc_config_version | \
-               sed 's/\([[0-9]]*\)\.\([[0-9]]*\)\.\([[0-9]]*\).*/\3/'`
-    if test "$major" -gt "$req_major"; then
-        ok=yes
-    else 
-        if test "$major" -eq "$req_major"; then
-            if test "$minor" -gt "$req_minor"; then
-               ok=yes
-            else
-               if test "$minor" -eq "$req_minor"; then
-                   if test "$micro" -ge "$req_micro"; then
-                     ok=yes
-                   fi
-               fi
-            fi
-        fi
-    fi
-  fi
-  if test $ok = yes; then
-    OPENSC_CFLAGS=`$OPENSC_CONFIG $opensc_config_args --cflags`
-    OPENSC_LIBS=`$OPENSC_CONFIG $opensc_config_args --libs`
-    OPENSC_LIBS="$OPENSC_LIBS -lpcsclite -lpthread"
-    AC_MSG_RESULT(yes)
-    ifelse([$2], , :, [$2])
-  else
-    OPENSC_CFLAGS=""
-    OPENSC_LIBS=""
-    AC_MSG_RESULT(no)
-    ifelse([$3], , :, [$3])
-  fi
-  AC_SUBST(OPENSC_CFLAGS)
-  AC_SUBST(OPENSC_LIBS)
-])
-
-