HAVE_CLOCK_GETTIME_IN_LIBRT now implies HAVE_CLOCK_GETTIME.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
#include <stdlib.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdio.h>
-#if !HAVE_CLOCK_GETTIME && !HAVE_CLOCK_GETTIME_IN_LIBRT
#include <sys/time.h>
struct timeabs time_now(void)
#include <sys/time.h>
struct timeabs time_now(void)
clock_gettime(CLOCK_REALTIME, &ret.ts);
return TIMEABS_CHECK(ret);
}
clock_gettime(CLOCK_REALTIME, &ret.ts);
return TIMEABS_CHECK(ret);
}
-#endif /* HAVE_CLOCK_GETTIME || HAVE_CLOCK_GETTIME_IN_LIBRT */
+#endif /* HAVE_CLOCK_GETTIME */
struct timemono time_mono(void)
{
struct timemono time_mono(void)
{
* Otherwise time_mono() just refers to time_now(). Your code might
* test this if you really need a monotonic clock.
*/
* Otherwise time_mono() just refers to time_now(). Your code might
* test this if you really need a monotonic clock.
*/
-#if (HAVE_CLOCK_GETTIME || HAVE_CLOCK_GETTIME_IN_LIBRT) && defined(CLOCK_MONOTONIC)
+#if HAVE_CLOCK_GETTIME && defined(CLOCK_MONOTONIC)
#define TIME_HAVE_MONOTONIC 1
#endif
#define TIME_HAVE_MONOTONIC 1
#endif