dnl dnl SVN_LIB_SASL dnl dnl Check configure options and assign variables related to dnl the sasl library. dnl dnl If we find the library, set the shell variable dnl `svn_lib_sasl' to `yes'. Otherwise, set `svn_lib_sasl' dnl to `no'. AC_DEFUN(SVN_LIB_SASL, [ AC_ARG_WITH(sasl, [ --with-sasl=PATH Compile with libsasl2 in PATH], with_sasl="$withval", with_sasl="no") if test "${with_sasl}" = "no"; then svn_lib_sasl=no else AC_MSG_CHECKING([for availability of Cyrus SASL v2]) saved_LDFLAGS="$LDFLAGS" saved_CPPFLAGS="$CPPFLAGS" if test -d ${with_sasl}; then SVN_SASL_INCLUDES="-I${with_sasl}/include" CPPFLAGS="$CPPFLAGS $SVN_SASL_INCLUDES" LDFLAGS="$LDFLAGS -L${with_sasl}/lib" fi AC_CHECK_HEADER(sasl/sasl.h, [AC_CHECK_HEADER(sasl/saslutil.h, [AC_CHECK_LIB(sasl2, prop_get, svn_lib_sasl=yes, svn_lib_sasl=no)], svn_lib_sasl=no)], svn_lib_sasl=no) if test "$svn_lib_sasl" = "yes"; then SVN_SASL_LIBS="-lsasl2" AC_MSG_RESULT([yes]) else LDFLAGS="$saved_LDFLAGS" SVN_SASL_INCLUDES="" SVN_SASL_LIBS="" AC_MSG_RESULT([no]) fi CPPFLAGS="$saved_CPPFLAGS" fi AC_SUBST(SVN_SASL_INCLUDES) AC_SUBST(SVN_SASL_LIBS) ])