From 667b5721c71480b4e5dbd2f91d7668a2b92bf00b Mon Sep 17 00:00:00 2001 From: dmitrykos Date: Thu, 4 Oct 2018 21:31:23 +0300 Subject: cmake: test and set missed defines during configuration Added configuration checks for HAVE_BUILTIN_AVAILABLE and HAVE_CLOCK_GETTIME_MONOTONIC. Closes #3097 --- CMake/CurlTests.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'CMake') diff --git a/CMake/CurlTests.c b/CMake/CurlTests.c index ab244ac39..9388c835b 100644 --- a/CMake/CurlTests.c +++ b/CMake/CurlTests.c @@ -549,3 +549,19 @@ main() { return 0; } #endif +#ifdef HAVE_CLOCK_GETTIME_MONOTONIC +#include +int +main() { + struct timespec ts = {0, 0}; + clock_gettime(CLOCK_MONOTONIC, &ts); + return 0; +} +#endif +#ifdef HAVE_BUILTIN_AVAILABLE +int +main() { + if(__builtin_available(macOS 10.12, *)) {} + return 0; +} +#endif -- cgit v1.2.3