MINGW-packages/mingw-w64-python/0061-configure.ac-don-t-check-for-clock_-functions.patch
2024-11-03 19:29:19 +01:00

34 lines
894 B
Diff

From 7326d72e9228a85e9a1aaac294bdb8e40ff4f8bc Mon Sep 17 00:00:00 2001
From: Christoph Reiter <reiter.christoph@gmail.com>
Date: Sun, 1 Aug 2021 18:35:17 +0200
Subject: [PATCH 061/N] 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 8a37ec9..63630f4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5516,6 +5516,9 @@ WITH_SAVE_ENV([
])
])
+case $host in
+ *-*-mingw*) ;;
+ *)
AC_CHECK_FUNCS([clock_gettime], [], [
AC_CHECK_LIB([rt], [clock_gettime], [
LIBS="$LIBS -lrt"
@@ -5536,6 +5539,8 @@ AC_CHECK_FUNCS([clock_settime], [], [
AC_DEFINE([HAVE_CLOCK_SETTIME], [1])
])
])
+ ;;
+esac
AC_CHECK_FUNCS([clock_nanosleep], [], [
AC_CHECK_LIB([rt], [clock_nanosleep], [