[Swan-dev] pluto: Fix CLOCK_BOOTTIME build failure
Herbert Xu
herbert at gondor.apana.org.au
Tue Apr 21 07:24:19 EEST 2015
Without this patch the build fails for me with:
programs/pluto/defs.c: In function \u2018mononow\u2019:
programs/pluto/defs.c:76:8: error: "CLOCK_BOOTTIME" is not defined [-Werror=undef]
diff --git a/programs/pluto/defs.c b/programs/pluto/defs.c
index 4db713b..31f02d8 100644
--- a/programs/pluto/defs.c
+++ b/programs/pluto/defs.c
@@ -73,7 +73,7 @@ monotime_t mononow(void)
#ifdef _POSIX_MONOTONIC_CLOCK
struct timespec t;
int r = clock_gettime(
-# if CLOCK_BOOTTIME
+# ifdef CLOCK_BOOTTIME
CLOCK_BOOTTIME /* best */
# else
CLOCK_MONOTONIC /* second best */
--
Email: Herbert Xu <herbert at gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
More information about the Swan-dev
mailing list