Skip to content

Commit

Permalink
configure.ac: don't check for clock_ functions
Browse files Browse the repository at this point in the history
They shouldn't be exposed on Windows and lead to winpthread being linked in
  • Loading branch information
lazka committed Aug 25, 2023
1 parent 70f172b commit 184e0da
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -5209,6 +5209,9 @@ WITH_SAVE_ENV([
])
])

case $host in
*-*-mingw*) ;;
*)
AC_CHECK_FUNCS(clock_gettime, [], [
AC_CHECK_LIB(rt, clock_gettime, [
LIBS="$LIBS -lrt"
Expand All @@ -5229,6 +5232,8 @@ AC_CHECK_FUNCS(clock_settime, [], [
AC_DEFINE(HAVE_CLOCK_SETTIME, 1)
])
])
;;
esac

AC_CHECK_FUNCS(clock_nanosleep, [], [
AC_CHECK_LIB(rt, clock_nanosleep, [
Expand Down

0 comments on commit 184e0da

Please sign in to comment.