]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
add a --disable-pkcs11 knob
authorDamien Miller <djm@mindrot.org>
Fri, 15 Jul 2016 03:54:31 +0000 (13:54 +1000)
committerDamien Miller <djm@mindrot.org>
Fri, 15 Jul 2016 04:28:59 +0000 (14:28 +1000)
configure.ac

index 4f525b5d2eea563eb4c0c22f1f008ca5cea9d2f8..21ef389887881d09fb5f111489dd8d33b6a9d449 100644 (file)
@@ -1804,8 +1804,18 @@ AC_LINK_IFELSE(
        [AC_DEFINE([HAVE_ISBLANK], [1], [Define if you have isblank(3C).])
 ])
 
+disable_pkcs11=
+AC_ARG_ENABLE([pkcs11],
+       [  --disable-pkcs11        disable PKCS#11 support code [no]],
+       [
+               if test "x$enableval" = "xno" ; then
+                       disable_pkcs11=1
+               fi
+       ]
+)
+
 # PKCS11 depends on OpenSSL.
-if test "x$openssl" = "xyes" ; then
+if test "x$openssl" = "xyes" && test "x$disable_pkcs11" = "x"; then
        # PKCS#11 support requires dlopen() and co
        AC_SEARCH_LIBS([dlopen], [dl],
            [AC_DEFINE([ENABLE_PKCS11], [], [Enable for PKCS#11 support])]