changeset 4427:ffafc8583e06 HEAD

Prefer sasl/sasl.h. Require SASL v2, otherwise disable it.
author Timo Sirainen <tss@iki.fi>
date Mon, 19 Jun 2006 19:14:47 +0300
parents b8089cf41c96
children 94dc3f73ffb9
files src/auth/db-ldap.c
diffstat 1 files changed, 6 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/auth/db-ldap.c	Mon Jun 19 19:10:16 2006 +0300
+++ b/src/auth/db-ldap.c	Mon Jun 19 19:14:47 2006 +0300
@@ -16,13 +16,16 @@
 #include <stdlib.h>
 
 #define HAVE_LDAP_SASL
-#ifdef HAVE_SASL_H
+#ifdef HAVE_SASL_SASL_H
+#  include <sasl/sasl.h>
+#elif defined (HAVE_SASL_H)
 #  include <sasl.h>
-#elif defined (HAVE_SASL_SASL_H)
-#  include <sasl/sasl.h>
 #else
 #  undef HAVE_LDAP_SASL
 #endif
+#if SASL_VERSION_MAJOR < 2
+#  undef HAVE_LDAP_SASL
+#endif
 
 /* Older versions may require calling ldap_result() twice */
 #if LDAP_VENDOR_VERSION <= 20112