From 20276b09f0b71131450f70a9acc53e05fbb9fda1 Mon Sep 17 00:00:00 2001 From: Thomas Chou Date: Wed, 2 Oct 2024 22:30:17 -0700 Subject: [PATCH] clock_gettime: check posix timer support (#156) The recent changes in arduino pico breaks the check. Fix it by checking the _POSIX_TIMERS not defined or zero. Signed-off-by: Thomas Chou --- platform_code/arduino/clock_gettime.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform_code/arduino/clock_gettime.cpp b/platform_code/arduino/clock_gettime.cpp index 8428a1f..2422498 100644 --- a/platform_code/arduino/clock_gettime.cpp +++ b/platform_code/arduino/clock_gettime.cpp @@ -3,7 +3,7 @@ #include #define micro_rollover_useconds 4294967295 -#ifndef _POSIX_TIMERS +#if !defined(_POSIX_TIMERS) || !_POSIX_TIMERS extern "C" int clock_gettime(clockid_t unused, struct timespec *tp) {