diff --git a/configure b/configure index ac543f09a2e..d3253a2ca76 100755 --- a/configure +++ b/configure @@ -17688,8 +17688,10 @@ fi done -ac_save_LIBS=$LIBS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 +case $host_os in + darwin*|macosx*) ;; + *) ac_save_LIBS=$LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 $as_echo_n "checking for library containing clock_gettime... " >&6; } if ${ac_cv_search_clock_gettime+:} false; then : $as_echo_n "(cached) " >&6 @@ -17749,7 +17751,9 @@ $as_echo "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h fi -LIBS=$ac_save_LIBS + LIBS=$ac_save_LIBS + ;; +esac if test "x$with_ldap" != "xno" then diff --git a/configure.ac b/configure.ac index 10cef9c7b7a..c7f5236cf85 100644 --- a/configure.ac +++ b/configure.ac @@ -2169,11 +2169,15 @@ AC_CHECK_FUNCS(\ ) dnl Check for clock_gettime which may be in -lrt -ac_save_LIBS=$LIBS -AC_SEARCH_LIBS(clock_gettime, rt, - [AC_DEFINE(HAVE_CLOCK_GETTIME, 1, [Define to 1 if you have the `clock_gettime' function.]) +case $host_os in + darwin*|macosx*) ;; + *) ac_save_LIBS=$LIBS + AC_SEARCH_LIBS(clock_gettime, rt, + [AC_DEFINE(HAVE_CLOCK_GETTIME, 1, [Define to 1 if you have the `clock_gettime' function.]) test "$ac_res" = "none required" || AC_SUBST(RT_LIBS,"$ac_res")]) -LIBS=$ac_save_LIBS + LIBS=$ac_save_LIBS + ;; +esac dnl **** Check for OpenLDAP *** if test "x$with_ldap" != "xno"