--- configure.ac~ 2009-08-09 18:30:32 +0400 +++ configure.ac 2009-08-12 20:04:15 +0400 @@ -760,27 +760,27 @@ msg_krb5="no" if test "x${with_krb5}" != "xno"; then - LDFLAGS_save="$LDFLAGS" + LIBS_save="$LIBS" mitlibs="-lkrb5 -lk5crypto -lcom_err -lgssapi_krb5" heimlibs="-lkrb5 -lcrypto -lasn1 -lcom_err -lroken -lgssapi" sunlibs="-lkrb5 -lgss" AC_CACHE_CHECK([for Kerberos 5], [ac_cv_lib_kerberos5], [ - LDFLAGS="$LDFLAGS -L$with_krb5_libs $mitlibs" - AC_LINK_IFELSE([AC_LANG_CALL([], [krb5_init_context,])], + LIBS="$LIBS -L$with_krb5_libs $mitlibs" + AC_LINK_IFELSE([AC_LANG_CALL([], [krb5_init_context])], [ac_cv_lib_kerberos5="$mitlibs"], [ - LDFLAGS="$LDFLAGS_save -L$with_krb5_libs $heimlibs" + LIBS="$LIBS_save -L$with_krb5_libs $heimlibs" AC_LINK_IFELSE([AC_LANG_CALL([], [krb5_init_context])], [ac_cv_lib_kerberos5="$heimlibs"], [ - LDFLAGS="$LDFLAGS_save -L$with_krb5_libs $sunlibs" + LIBS="$LIBS_save -L$with_krb5_libs $sunlibs" AC_LINK_IFELSE([AC_LANG_CALL([], [krb5_init_context])], [ac_cv_lib_kerberos5="$sunlibs"], [ac_cv_lib_kerberos5="no"]) ]) ]) - LDFLAGS="$LDFLAGS_save" + LIBS="$LIBS_save" ]) if test "$ac_cv_lib_kerberos5" != "no"; then AC_DEFINE(HAVE_KRB5,1,[Define if you have Krb5])