Commit e04498e5 e04498e53df13127402e7c7841d024ec90f27386 by Sergey Poznyakoff

Drop a superfluous dependency on libgcrypt.

* am/tls.m4 (MU_CHECK_GNUTLS): Newer GNU TLS does not require
libgcrypt. It is required only for v. 2.11 and prior versions.
1 parent 34128509
Showing 1 changed file with 11 additions and 3 deletions
...@@ -35,9 +35,17 @@ AC_DEFUN([MU_CHECK_GNUTLS], ...@@ -35,9 +35,17 @@ AC_DEFUN([MU_CHECK_GNUTLS],
35 [mu_cv_lib_gnutls=no]) 35 [mu_cv_lib_gnutls=no])
36 if test "$mu_cv_lib_gnutls" != "no"; then 36 if test "$mu_cv_lib_gnutls" != "no"; then
37 saved_LIBS=$LIBS 37 saved_LIBS=$LIBS
38 AC_CHECK_LIB(gcrypt, main, 38 AC_PREPROC_IFELSE(
39 [TLS_LIBS="-lgcrypt"], 39 [AC_LANG_PROGRAM([#include <gnutls/gnutls.h>
40 [mu_cv_lib_gnutls=no]) 40 #include <gnutls/x509.h>
41 #if GNUTLS_VERSION_NUMBER <= 0x020b00
42 # error "Need gcrypt"
43 #endif
44 ],[])],
45 [],
46 [AC_CHECK_LIB(gcrypt, main,
47 [TLS_LIBS="-lgcrypt"],
48 [mu_cv_lib_gnutls=no])])
41 LIBS="$LIBS $TLS_LIBS" 49 LIBS="$LIBS $TLS_LIBS"
42 AC_CHECK_LIB(gnutls, gnutls_global_init, 50 AC_CHECK_LIB(gnutls, gnutls_global_init,
43 [TLS_LIBS="-lgnutls $TLS_LIBS"], 51 [TLS_LIBS="-lgnutls $TLS_LIBS"],
......