Commit 70096743 authored by Eli Zaretskii's avatar Eli Zaretskii

MS-Windows follow-up for recent TZ-related changes

* nt/ (ac_cv_header_pthread_h)
(gl_cv_sys_struct_timespec_in_pthread_h): Force to "no", to avoid
picking up 'struct timespec' from pthread.h, if it is installed on
the user's system.  We want either the definitions from MinGW
system headers, if available, or the Gnulib replacements if not.

* nt/inc/ms-w32.h <struct timespec>: Don't define, as we now use

* lib/ Don't let __need_* symbols affect what happens on
MinGW.  These symbols are defined by MinGW system headers, but we
don't want that to affect whether Gnulib portions of the header
are or aren't used.
parent 075f8d96
......@@ -24,9 +24,11 @@
declare a few standard symbols, rather than to declare all the
symbols. Also, Solaris 8 <time.h> eventually includes itself
recursively; if that is happening, just include the system <time.h>
without adding our own declarations. */
#if (defined __need_time_t || defined __need_clock_t \
|| defined __need_timespec \
without adding our own declarations. MinGW system headers use
these symbols as well, but we don't want to exclude MinGW from the
'else' branch below. */
#if (((defined __need_time_t || defined __need_clock_t \
|| defined __need_timespec) && !defined __MINGW32__) \
|| defined _@GUARD_PREFIX@_TIME_H)
......@@ -306,21 +306,6 @@ int _getpid (void);
#include <time.h>
#define tzname _tzname
/* 'struct timespec' is used by time-related functions in lib/ and
elsewhere, but we don't use lib/time.h where the structure is
defined. */
/* MinGW64 defines 'struct timespec' and _TIMESPEC_DEFINED in sys/types.h. */
/*'s MinGW runtime versions 3.22 and upward define 'struct
timespec' and __struct_timespec_defined in parts/time.h, which is
included by time.h. */
#if !defined (_TIMESPEC_DEFINED) && !defined (__struct_timespec_defined)
struct timespec
time_t tv_sec; /* seconds */
long int tv_nsec; /* nanoseconds */
/* Required for functions in lib/time_r.c, since we don't use lib/time.h. */
extern struct tm *gmtime_r (time_t const * restrict, struct tm * restrict);
extern struct tm *localtime_r (time_t const * restrict, struct tm * restrict);
......@@ -35,6 +35,11 @@ ac_cv_header_getopt_h=no
# We don't want our struct timeval replaced due to Posix conformance
# We don't want pthread.h to be picked up just because it defines timespec
# Or at all...
# ACL functions are implemented in w32.c
ac_cv_search_acl_get_file="none required"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment