From: Howard Chu Date: Sun, 10 Feb 2002 14:23:55 +0000 (+0000) Subject: Added check for Cyrus SASLv2 X-Git-Tag: OPENLDAP_REL_ENG_2_1_BP~65 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=0b54812c2c24ea0db58f9578eb4bdb7c22d84c95;p=openldap Added check for Cyrus SASLv2 --- diff --git a/configure.in b/configure.in index 5663c6ed4d..384bf0130c 100644 --- a/configure.in +++ b/configure.in @@ -2114,20 +2114,33 @@ dnl ---------------------------------------------------------------- dnl dnl Check for Cyrus SASL dnl +dnl HAVE_CYRUS_SASL2 implicitly defines HAVE_CYRUS_SASL ol_link_sasl=no ol_link_spasswd=no if test $ol_with_cyrus_sasl != no ; then - AC_CHECK_HEADERS(sasl.h) + AC_CHECK_HEADERS(sasl/sasl.h) - if test $ac_cv_header_sasl_h = yes ; then - AC_CHECK_LIB(sasl, sasl_client_init, - [have_cyrus_sasl=yes], [have_cyrus_sasl=no]) + if test $ac_cv_header_sasl_sasl_h = yes ; then + AC_CHECK_LIB(sasl2, sasl_client_init, + [have_cyrus_sasl2=yes], [have_cyrus_sasl2=no]) - if test $have_cyrus_sasl != no ; then - SASL_LIBS="-lsasl" - AC_DEFINE(HAVE_CYRUS_SASL,1,[define if you have Cyrus SASL]) + if test $have_cyrus_sasl2 != no ; then + SASL_LIBS="-lsasl2" + AC_DEFINE(HAVE_CYRUS_SASL2,1,[define if you have Cyrus SASL v2]) ol_link_sasl=yes fi + else + AC_CHECK_HEADERS(sasl.h) + + if test $ac_cv_header_sasl_h = yes ; then + AC_CHECK_LIB(sasl, sasl_client_init, + [have_cyrus_sasl=yes], [have_cyrus_sasl=no]) + + if test $have_cyrus_sasl != no ; then + SASL_LIBS="-lsasl" + ol_link_sasl=yes + fi + fi fi if test $ol_link_sasl = no ; then @@ -2140,9 +2153,11 @@ if test $ol_with_cyrus_sasl != no ; then AC_MSG_WARN([Strong authentication not supported!]) fi fi - - elif test $ol_enable_spasswd != no ; then - ol_link_spasswd=yes + else + AC_DEFINE(HAVE_CYRUS_SASL,1,[define if you have Cyrus SASL]) + if test $ol_enable_spasswd != no ; then + ol_link_spasswd=yes + fi fi else @@ -2154,7 +2169,7 @@ fi dnl ---------------------------------------------------------------- dnl Check for entropy sources -if test $cross_compiling != yes -a $ac_cv_mingw32 != yes ; then +if test $cross_compiling != yes -a "$ac_cv_mingw32" != yes ; then dev=no if test -r /dev/urandom ; then dev="/dev/urandom";