]> andersk Git - openssh.git/commitdiff
- (tim) [configure.ac] Bug 998. Make path for --with-opensc optional.
authortim <tim>
Thu, 17 Mar 2005 21:37:04 +0000 (21:37 +0000)
committertim <tim>
Thu, 17 Mar 2005 21:37:04 +0000 (21:37 +0000)
   Make --without-opensc work.

ChangeLog
configure.ac

index cd6bfd19ad0e589e4574866ce1ab8ce53ba3e156..3e66b2c3b435e049023c5b7ac3cd9fd6ea4702a7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+20050317
+ - (tim) [configure.ac] Bug 998. Make path for --with-opensc optional.
+   Make --without-opensc work.
+
 20050314
  - (dtucker) OpenBSD CVS Sync
    - dtucker@cvs.openbsd.org 2005/03/10 10:15:02
index e97b56652619d8884fc1325b8b9221ffeb069ae1..a999f7399d6ba8d3d288c78d3d24eb2dc4fc45eb 100644 (file)
@@ -2324,23 +2324,28 @@ AC_ARG_WITH(sectok,
 )
 
 # Check whether user wants OpenSC support
+OPENSC_CONFIG="no"
 AC_ARG_WITH(opensc,
-       AC_HELP_STRING([--with-opensc=PFX],
-                      [Enable smartcard support using OpenSC]),
-       opensc_config_prefix="$withval", opensc_config_prefix="")
-if test x$opensc_config_prefix != x ; then
-  OPENSC_CONFIG=$opensc_config_prefix/bin/opensc-config
-  AC_PATH_PROG(OPENSC_CONFIG, opensc-config, no)
-  if test "$OPENSC_CONFIG" != "no"; then
-    LIBOPENSC_CFLAGS=`$OPENSC_CONFIG --cflags`
-    LIBOPENSC_LIBS=`$OPENSC_CONFIG --libs`
-    CPPFLAGS="$CPPFLAGS $LIBOPENSC_CFLAGS"
-    LDFLAGS="$LDFLAGS $LIBOPENSC_LIBS"
-    AC_DEFINE(SMARTCARD)
-    AC_DEFINE(USE_OPENSC)
-    SCARD_MSG="yes, using OpenSC"
-  fi
-fi
+       [--with-opensc[[=PFX]]       Enable smartcard support using OpenSC (optionally in PATH)],
+       [
+           if test "x$withval" != "xno" ; then
+               if test "x$withval" != "xyes" ; then
+                       OPENSC_CONFIG=$withval/bin/opensc-config
+               else
+                       AC_PATH_PROG(OPENSC_CONFIG, opensc-config, no)
+               fi
+               if test "$OPENSC_CONFIG" != "no"; then
+                       LIBOPENSC_CFLAGS=`$OPENSC_CONFIG --cflags`
+                       LIBOPENSC_LIBS=`$OPENSC_CONFIG --libs`
+                       CPPFLAGS="$CPPFLAGS $LIBOPENSC_CFLAGS"
+                       LDFLAGS="$LDFLAGS $LIBOPENSC_LIBS"
+                       AC_DEFINE(SMARTCARD)
+                       AC_DEFINE(USE_OPENSC)
+                       SCARD_MSG="yes, using OpenSC"
+               fi
+           fi
+       ]
+)
 
 # Check libraries needed by DNS fingerprint support
 AC_SEARCH_LIBS(getrrsetbyname, resolv,
This page took 0.053996 seconds and 5 git commands to generate.