use monotonic time source in convar->timed_wait, and in the scheduler using it

This commit is contained in:
Martin Willi
2009-08-31 15:13:48 +02:00
parent 3f310c0d1f
commit 3d5818ec38
6 changed files with 50 additions and 21 deletions
+14
View File
@@ -927,6 +927,20 @@ AC_TRY_COMPILE(
[AC_MSG_RESULT([no])]
)
dnl check if pthread_condattr_setclock(CLOCK_MONOTONE) is supported
saved_LIBS=$LIBS
LIBS="-lpthread"
AC_MSG_CHECKING([for pthread_condattr_setclock(CLOCK_MONOTONE)])
AC_TRY_RUN(
[#include <pthread.h>
int main() { pthread_condattr_t attr;
pthread_condattr_init(&attr);
return pthread_condattr_setclock(&attr, CLOCK_MONOTONIC);}],
[AC_MSG_RESULT([yes]); AC_DEFINE([HAVE_CONDATTR_CLOCK_MONOTONIC])],
[AC_MSG_RESULT([no])]
)
LIBS=$saved_LIBS
AC_CHECK_FUNCS(prctl)
AC_CHECK_HEADERS(sys/sockio.h)