svn commit: samba r15538 - in branches/SAMBA_4_0/source/lib/tls: .

jelmer at samba.org jelmer at samba.org
Thu May 11 21:21:36 GMT 2006


Author: jelmer
Date: 2006-05-11 21:21:36 +0000 (Thu, 11 May 2006)
New Revision: 15538

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=15538

Log:
Use pkg-config file where possible and 
only fall back to manual tests if that can't be found (for systems 
that have older versions of gnutls without the .pc file installed)

Modified:
   branches/SAMBA_4_0/source/lib/tls/config.m4


Changeset:
Modified: branches/SAMBA_4_0/source/lib/tls/config.m4
===================================================================
--- branches/SAMBA_4_0/source/lib/tls/config.m4	2006-05-11 18:59:41 UTC (rev 15537)
+++ branches/SAMBA_4_0/source/lib/tls/config.m4	2006-05-11 21:21:36 UTC (rev 15538)
@@ -1,19 +1,20 @@
 ###############################
 # start SMB_EXT_LIB_GNUTLS
 # check for gnutls/gnutls.h and -lgnutls
-#
-# Should eventually change to simply:
-# SMB_EXT_LIB_FROM_PKGCONFIG(GNUTLS, gnutls)
-AC_CHECK_HEADERS(gnutls/gnutls.h)
-AC_CHECK_LIB_EXT(gnutls, GNUTLS_LIBS, gnutls_global_init)
-if test x"$ac_cv_header_gnutls_gnutls_h" = x"yes" -a x"$ac_cv_lib_ext_gnutls_gnutls_global_init" = x"yes";then
-	SMB_ENABLE(GNUTLS,YES)
-	AC_CHECK_DECL(gnutls_x509_crt_set_subject_key_id,  
-	              [AC_DEFINE(HAVE_GNUTLS_X509_CRT_SET_SUBJECT_KEY_ID,1,gnutls subject_key)], [], [
-#include <gnutls/gnutls.h>
-#include <gnutls/x509.h>
-])
+SMB_EXT_LIB_FROM_PKGCONFIG(GNUTLS, gnutls)
+
+if test x$SMB_ENABLE_GNUTLS = xNO; then
+	AC_CHECK_HEADERS(gnutls/gnutls.h)
+	AC_CHECK_LIB_EXT(gnutls, GNUTLS_LIBS, gnutls_global_init)
+	if test x"$ac_cv_header_gnutls_gnutls_h" = x"yes" -a x"$ac_cv_lib_ext_gnutls_gnutls_global_init" = x"yes";then
+		SMB_ENABLE(GNUTLS,YES)
+		AC_CHECK_DECL(gnutls_x509_crt_set_subject_key_id,  
+		              [AC_DEFINE(HAVE_GNUTLS_X509_CRT_SET_SUBJECT_KEY_ID,1,gnutls subject_key)], [], [
+	#include <gnutls/gnutls.h>
+	#include <gnutls/x509.h>
+	])
+	fi
+	SMB_EXT_LIB(GNUTLS, $GNUTLS_LIBS)
 fi
-SMB_EXT_LIB(GNUTLS, $GNUTLS_LIBS)
 # end SMB_EXT_LIB_GNUTLS
 ###############################



More information about the samba-cvs mailing list