From 7af3ba340d608860d519210032d190c26c6f6eae Mon Sep 17 00:00:00 2001 From: Brent Cook Date: Sun, 6 Jan 2019 13:20:29 -0600 Subject: add configure-time check for timespecsub --- include/compat/time.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/compat/time.h b/include/compat/time.h index ccedba3..540807d 100644 --- a/include/compat/time.h +++ b/include/compat/time.h @@ -39,7 +39,11 @@ typedef int clockid_t; int clock_gettime(clockid_t clock_id, struct timespec *tp); #endif -#ifndef timespecsub +#ifdef timespecsub +#define HAVE_TIMESPECSUB +#endif + +#ifndef HAVE_TIMESPECSUB #define timespecsub(tsp, usp, vsp) \ do { \ (vsp)->tv_sec = (tsp)->tv_sec - (usp)->tv_sec; \ @@ -50,6 +54,7 @@ int clock_gettime(clockid_t clock_id, struct timespec *tp); } \ } while (0) #endif + #endif #endif -- cgit v1.2.3-55-g6feb