From fdd0d90a4a2de8048d27ea6d05dd94cce0b2b2f6 Mon Sep 17 00:00:00 2001 From: Christoph Reiter Date: Sun, 1 Aug 2021 18:35:17 +0200 Subject: [PATCH] configure.ac: don't check for clock_ functions They shouldn't be exposed on Windows and lead to winpthread being linked in --- configure.ac | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/configure.ac b/configure.ac index 5a543d5915cfd9..30942537f8480e 100644 --- a/configure.ac +++ b/configure.ac @@ -5205,6 +5205,9 @@ WITH_SAVE_ENV([ ]) ]) +case $host in + *-*-mingw*) ;; + *) AC_CHECK_FUNCS(clock_gettime, [], [ AC_CHECK_LIB(rt, clock_gettime, [ LIBS="$LIBS -lrt" @@ -5225,6 +5228,8 @@ AC_CHECK_FUNCS(clock_settime, [], [ AC_DEFINE(HAVE_CLOCK_SETTIME, 1) ]) ]) + ;; +esac AC_CHECK_FUNCS(clock_nanosleep, [], [ AC_CHECK_LIB(rt, clock_nanosleep, [