]> andersk Git - openssh.git/commitdiff
- (dtucker) Bug #1160: use pkg-config for opensc config if it's available.
authordtucker <dtucker>
Mon, 7 Dec 2009 00:15:43 +0000 (00:15 +0000)
committerdtucker <dtucker>
Mon, 7 Dec 2009 00:15:43 +0000 (00:15 +0000)
   Tested by Martin Paljak.

ChangeLog
configure.ac

index 41c272ec9521c316adc8c23d6d4ff04f27f5d03d..1c3c93b63b8a9eb058700b656acfd6618253aa30 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+20091207
+ - (dtucker) Bug #1160: use pkg-config for opensc config if it's available.
+   Tested by Martin Paljak.
+
 20091121
  - (tim) [opensshd.init.in] If PidFile is set in sshd_config, use it.
    Bug 1628. OK dtucker@
index a0c50e30021637023cbb124f260a4f6aa17d57d1..2de30f338b212b5d72eaadf5f6d04a91ea757c30 100644 (file)
@@ -3295,11 +3295,18 @@ AC_ARG_WITH(opensc,
        [  --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
+               AC_PATH_PROG(PKGCONFIG, pkg-config, no)
+               AC_MSG_CHECKING(how to get opensc config)
+               if test "x$withval" != "xyes" -a "x$PKGCONFIG" = "xno"; then
+                       OPENSC_CONFIG="$withval/bin/opensc-config"
+               elif test -f "$withval/src/libopensc/libopensc.pc"; then
+                       OPENSC_CONFIG="$PKGCONFIG $withval/src/libopensc/libopensc.pc"
+               elif test "x$PKGCONFIG" != "xno"; then
+                       OPENSC_CONFIG="$PKGCONFIG libopensc"
                else
-                       AC_PATH_PROG(OPENSC_CONFIG, opensc-config, no)
+                       AC_PATH_PROG(OPENSC_CONFIG, opensc-config, no)
                fi
+               AC_MSG_RESULT($OPENSC_CONFIG)
                if test "$OPENSC_CONFIG" != "no"; then
                        LIBOPENSC_CFLAGS=`$OPENSC_CONFIG --cflags`
                        LIBOPENSC_LIBS=`$OPENSC_CONFIG --libs`
This page took 0.134814 seconds and 5 git commands to generate.