Hash :
1fac141c
Author :
Date :
2023-08-11T10:24:46
clock-time: On mingw, avoid buggy clock_gettime from libwinpthread. * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_CANONICAL_HOST. On native Windows, avoid using clock_getres clock_gettime clock_settime from mingw's libwinpthread. * doc/posix-functions/clock_gettime.texi: Mention the mingw bug.
@node clock_gettime
@section @code{clock_gettime}
@findex clock_gettime
POSIX specification:@* @url{https://pubs.opengroup.org/onlinepubs/9699919799/functions/clock_gettime.html}
Gnulib module: ---
Portability problems fixed by Gnulib:
@itemize
@end itemize
Portability problems not fixed by Gnulib:
@itemize
@item
This function is missing on some platforms:
Mac OS X 10.11, Minix 3.1.8, mingw, MSVC 14.
@item
This function leaves the upper 32 bits of the @code{tv_sec} field of the result
uninitialized on some platforms:
mingw in 32-bit mode.
@end itemize
The Gnulib modules @code{gettime} and @code{timespec_get} are partial
substitutes; they implement the @code{CLOCK_REALTIME} functionality of
@code{clock_gettime}.