summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libc/unistd/sysconf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/unistd/sysconf.c b/libc/unistd/sysconf.c
index 8488f013b..549c13ca6 100644
--- a/libc/unistd/sysconf.c
+++ b/libc/unistd/sysconf.c
@@ -884,7 +884,7 @@ long int sysconf(int name)
#endif
case _SC_MONOTONIC_CLOCK:
-#ifdef __NR_clock_getres
+#if defined __UCLIBC_HAS_REALTIME__ && defined __NR_clock_getres
/* Check using the clock_getres system call. */
if (clock_getres(CLOCK_MONOTONIC, NULL) >= 0)
return _POSIX_VERSION;