Skip to content

Commit 4b02177

Browse files
author
Git for Windows Build Agent
committed
Update 7 packages
mingw-w64-i686-crt-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) mingw-w64-i686-headers-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) mingw-w64-i686-libmangle-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) mingw-w64-i686-libwinpthread-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) mingw-w64-i686-mpdecimal (4.0.0-1 -> 4.0.1-1) mingw-w64-i686-tools-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) mingw-w64-i686-winpthreads-git (12.0.0.r688.g6b2176247-1 -> 12.0.0.r720.g01c28cf2e-1) Signed-off-by: Git for Windows Build Agent <[email protected]>
1 parent 6a513f1 commit 4b02177

File tree

164 files changed

+335
-242
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+335
-242
lines changed

mingw32/bin/gendef.exe

0 Bytes
Binary file not shown.

mingw32/bin/genidl.exe

0 Bytes
Binary file not shown.

mingw32/bin/genpeimg.exe

0 Bytes
Binary file not shown.

mingw32/bin/libmpdec++-4.dll

-133 Bytes
Binary file not shown.

mingw32/bin/libmpdec-4.dll

3.53 KB
Binary file not shown.

mingw32/bin/libwinpthread-1.dll

6.16 KB
Binary file not shown.

mingw32/bin/widl.exe

0 Bytes
Binary file not shown.

mingw32/include/_mingw.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ typedef int __int128 __attribute__ ((__mode__ (TI)));
390390

391391
#ifndef __WIDL__
392392

393-
#if defined (_WIN32) && !defined (_WIN64) && !defined (__MINGW_USE_VC2005_COMPAT) && !defined (_UCRT)
393+
#if defined (_WIN32) && !defined (_WIN64) && !defined (__MINGW_USE_VC2005_COMPAT) && !defined (_UCRT) && !(defined (_TIME_BITS) && _TIME_BITS == 64)
394394
#ifndef _USE_32BIT_TIME_T
395395
#define _USE_32BIT_TIME_T
396396
#endif

mingw32/include/_mingw_stat64.h

Lines changed: 3 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
#ifndef _STAT_DEFINED
22

3+
/* __stat64 is needed for compatibility with msvc */
4+
#define __stat64 _stat64
5+
36
#ifdef _USE_32BIT_TIME_T
47
#define _fstat _fstat32
58
#define _fstati64 _fstat32i64
@@ -30,22 +33,6 @@
3033
__time32_t st_ctime;
3134
};
3235

33-
#ifndef NO_OLDNAMES
34-
struct stat {
35-
_dev_t st_dev;
36-
_ino_t st_ino;
37-
unsigned short st_mode;
38-
short st_nlink;
39-
short st_uid;
40-
short st_gid;
41-
_dev_t st_rdev;
42-
_off_t st_size;
43-
time_t st_atime;
44-
time_t st_mtime;
45-
time_t st_ctime;
46-
};
47-
#endif /* NO_OLDNAMES */
48-
4936
struct _stat32i64 {
5037
_dev_t st_dev;
5138
_ino_t st_ino;
@@ -88,9 +75,5 @@
8875
__time64_t st_ctime;
8976
};
9077

91-
#define __stat64 _stat64
92-
#define stat64 _stat64 /* for POSIX */
93-
#define fstat64 _fstat64 /* for POSIX */
94-
9578
#define _STAT_DEFINED
9679
#endif /* _STAT_DEFINED */

mingw32/include/decimal.hh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2020-2024 Stefan Krah. All rights reserved.
2+
* Copyright (c) 2020-2025 Stefan Krah. All rights reserved.
33
*
44
* Redistribution and use in source and binary forms, with or without
55
* modification, are permitted provided that the following conditions

mingw32/include/ftw.h

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,34 @@ extern "C" {
5353
/* Continue with FTW_DP callback for current directory (if FTW_DEPTH) and then its siblings. */
5454
#define FTW_SKIP_SIBLINGS 3
5555

56-
int ftw (const char *, int (*) (const char *, const struct stat *, int), int);
57-
int ftw64 (const char *, int (*) (const char *, const struct stat64 *, int), int);
56+
/*
57+
* When building mingw-w64 CRT files it is required that the ftw and
58+
* nftw functions are not declared with __MINGW_ASM_CALL redirection.
59+
* Otherwise the mingw-w64 would provide broken ftw and nftw symbols.
60+
* To prevent ABI issues, the mingw-w64 runtime should not call the ftw,
61+
* and nftw functions, instead it should call the fixed-size variants.
62+
*/
63+
#ifndef _CRTBLD
64+
#if defined(_FILE_OFFSET_BITS) && (_FILE_OFFSET_BITS == 64)
65+
#ifdef _USE_32BIT_TIME_T
66+
int ftw (const char *, int (*) (const char *, const struct stat *, int), int) __MINGW_ASM_CALL(ftw32i64);
67+
int nftw (const char *, int (*) (const char *, const struct stat *, int , struct FTW *), int, int) __MINGW_ASM_CALL(nftw32i64);
68+
#else
69+
int ftw (const char *, int (*) (const char *, const struct stat *, int), int) __MINGW_ASM_CALL(ftw64);
70+
int nftw (const char *, int (*) (const char *, const struct stat *, int , struct FTW *), int, int) __MINGW_ASM_CALL(nftw64);
71+
#endif
72+
#else
73+
#ifdef _USE_32BIT_TIME_T
74+
int ftw (const char *, int (*) (const char *, const struct stat *, int), int) __MINGW_ASM_CALL(ftw32);
75+
int nftw (const char *, int (*) (const char *, const struct stat *, int , struct FTW *), int, int) __MINGW_ASM_CALL(nftw32);
76+
#else
77+
int ftw (const char *, int (*) (const char *, const struct stat *, int), int) __MINGW_ASM_CALL(ftw64i32);
78+
int nftw (const char *, int (*) (const char *, const struct stat *, int , struct FTW *), int, int) __MINGW_ASM_CALL(nftw64i32);
79+
#endif
80+
#endif
81+
#endif
5882

59-
int nftw (const char *, int (*) (const char *, const struct stat *, int , struct FTW *), int, int);
83+
int ftw64 (const char *, int (*) (const char *, const struct stat64 *, int), int);
6084
int nftw64 (const char *, int (*) (const char *, const struct stat64 *, int , struct FTW *), int, int);
6185

6286
#ifdef __cplusplus

mingw32/include/mpdecimal.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2008-2024 Stefan Krah. All rights reserved.
2+
* Copyright (c) 2008-2025 Stefan Krah. All rights reserved.
33
*
44
* Redistribution and use in source and binary forms, with or without
55
* modification, are permitted provided that the following conditions
@@ -65,9 +65,9 @@ extern "C" {
6565

6666
#define MPD_MAJOR_VERSION 4
6767
#define MPD_MINOR_VERSION 0
68-
#define MPD_MICRO_VERSION 0
68+
#define MPD_MICRO_VERSION 1
6969

70-
#define MPD_VERSION "4.0.0"
70+
#define MPD_VERSION "4.0.1"
7171

7272
#define MPD_VERSION_HEX ((MPD_MAJOR_VERSION << 24) | \
7373
(MPD_MINOR_VERSION << 16) | \

mingw32/include/pthread.h

Lines changed: 60 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,6 @@ extern "C" {
8686
/* MSB 8-bit major version, 8-bit minor version, 16-bit patch level. */
8787
#define __WINPTHREADS_VERSION 0x00050000
8888

89-
/* #define WINPTHREAD_DBG 1 */
90-
9189
/* Compatibility stuff: */
9290
#define RWLS_PER_THREAD 8
9391

@@ -141,7 +139,16 @@ extern "C" {
141139
#define PTHREAD_MUTEX_RECURSIVE_NP PTHREAD_MUTEX_RECURSIVE
142140

143141
WINPTHREAD_API void * pthread_timechange_handler_np(void * dummy);
144-
WINPTHREAD_API int pthread_delay_np (const struct timespec *interval);
142+
WINPTHREAD_API int pthread_delay32_np (const struct _timespec32 *interval);
143+
WINPTHREAD_API int pthread_delay64_np (const struct _timespec64 *interval);
144+
WINPTHREAD_THREAD_DECL int pthread_delay_np (const struct timespec *interval)
145+
{
146+
#if WINPTHREADS_TIME_BITS == 32
147+
return pthread_delay32_np ((const struct _timespec32 *) interval);
148+
#else
149+
return pthread_delay64_np ((const struct _timespec64 *) interval);
150+
#endif
151+
}
145152
WINPTHREAD_API int pthread_num_processors_np(void);
146153
WINPTHREAD_API int pthread_set_num_processors_np(int n);
147154

@@ -271,12 +278,29 @@ WINPTHREAD_API int pthread_detach(pthread_t t);
271278
WINPTHREAD_API int pthread_setname_np(pthread_t thread, const char *name);
272279
WINPTHREAD_API int pthread_getname_np(pthread_t thread, char *name, size_t len);
273280

274-
275281
WINPTHREAD_API int pthread_rwlock_init(pthread_rwlock_t *rwlock_, const pthread_rwlockattr_t *attr);
276282
WINPTHREAD_API int pthread_rwlock_wrlock(pthread_rwlock_t *l);
277-
WINPTHREAD_API int pthread_rwlock_timedwrlock(pthread_rwlock_t *rwlock, const struct timespec *ts);
283+
WINPTHREAD_API int pthread_rwlock_timedwrlock32(pthread_rwlock_t *rwlock, const struct _timespec32 *ts);
284+
WINPTHREAD_API int pthread_rwlock_timedwrlock64(pthread_rwlock_t *rwlock, const struct _timespec64 *ts);
285+
WINPTHREAD_RWLOCK_DECL int pthread_rwlock_timedwrlock(pthread_rwlock_t *rwlock, const struct timespec *ts)
286+
{
287+
#if WINPTHREADS_TIME_BITS == 32
288+
return pthread_rwlock_timedwrlock32 (rwlock, (const struct _timespec32 *) ts);
289+
#else
290+
return pthread_rwlock_timedwrlock64 (rwlock, (const struct _timespec64 *) ts);
291+
#endif
292+
}
278293
WINPTHREAD_API int pthread_rwlock_rdlock(pthread_rwlock_t *l);
279-
WINPTHREAD_API int pthread_rwlock_timedrdlock(pthread_rwlock_t *l, const struct timespec *ts);
294+
WINPTHREAD_API int pthread_rwlock_timedrdlock32(pthread_rwlock_t *l, const struct _timespec32 *ts);
295+
WINPTHREAD_API int pthread_rwlock_timedrdlock64(pthread_rwlock_t *l, const struct _timespec64 *ts);
296+
WINPTHREAD_RWLOCK_DECL int pthread_rwlock_timedrdlock(pthread_rwlock_t *l, const struct timespec *ts)
297+
{
298+
#if WINPTHREADS_TIME_BITS == 32
299+
return pthread_rwlock_timedrdlock32 (l, (const struct _timespec32 *) ts);
300+
#else
301+
return pthread_rwlock_timedrdlock64 (l, (const struct _timespec64 *) ts);
302+
#endif
303+
}
280304
WINPTHREAD_API int pthread_rwlock_unlock(pthread_rwlock_t *l);
281305
WINPTHREAD_API int pthread_rwlock_tryrdlock(pthread_rwlock_t *l);
282306
WINPTHREAD_API int pthread_rwlock_trywrlock(pthread_rwlock_t *l);
@@ -287,11 +311,38 @@ WINPTHREAD_API int pthread_cond_destroy(pthread_cond_t *cv);
287311
WINPTHREAD_API int pthread_cond_signal (pthread_cond_t *cv);
288312
WINPTHREAD_API int pthread_cond_broadcast (pthread_cond_t *cv);
289313
WINPTHREAD_API int pthread_cond_wait (pthread_cond_t *cv, pthread_mutex_t *external_mutex);
290-
WINPTHREAD_API int pthread_cond_timedwait(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct timespec *t);
291-
WINPTHREAD_API int pthread_cond_timedwait_relative_np(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct timespec *t);
314+
WINPTHREAD_API int pthread_cond_timedwait32(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct _timespec32 *t);
315+
WINPTHREAD_API int pthread_cond_timedwait64(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct _timespec64 *t);
316+
WINPTHREAD_COND_DECL int pthread_cond_timedwait(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct timespec *t)
317+
{
318+
#if WINPTHREADS_TIME_BITS == 32
319+
return pthread_cond_timedwait32 (cv, external_mutex, (const struct _timespec32 *) t);
320+
#else
321+
return pthread_cond_timedwait64 (cv, external_mutex, (const struct _timespec64 *) t);
322+
#endif
323+
}
324+
WINPTHREAD_API int pthread_cond_timedwait32_relative_np(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct _timespec32 *t);
325+
WINPTHREAD_API int pthread_cond_timedwait64_relative_np(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct _timespec64 *t);
326+
WINPTHREAD_COND_DECL int pthread_cond_timedwait_relative_np(pthread_cond_t *cv, pthread_mutex_t *external_mutex, const struct timespec *t)
327+
{
328+
#if WINPTHREADS_TIME_BITS == 32
329+
return pthread_cond_timedwait32_relative_np (cv, external_mutex, (const struct _timespec32 *) t);
330+
#else
331+
return pthread_cond_timedwait64_relative_np (cv, external_mutex, (const struct _timespec64 *) t);
332+
#endif
333+
}
292334

293335
WINPTHREAD_API int pthread_mutex_lock(pthread_mutex_t *m);
294-
WINPTHREAD_API int pthread_mutex_timedlock(pthread_mutex_t *m, const struct timespec *ts);
336+
WINPTHREAD_API int pthread_mutex_timedlock32(pthread_mutex_t *m, const struct _timespec32 *ts);
337+
WINPTHREAD_API int pthread_mutex_timedlock64(pthread_mutex_t *m, const struct _timespec64 *ts);
338+
WINPTHREAD_MUTEX_DECL int pthread_mutex_timedlock(pthread_mutex_t *m, const struct timespec *ts)
339+
{
340+
#if WINPTHREADS_TIME_BITS == 32
341+
return pthread_mutex_timedlock32 (m, (const struct _timespec32 *) ts);
342+
#else
343+
return pthread_mutex_timedlock64 (m, (const struct _timespec64 *) ts);
344+
#endif
345+
}
295346
WINPTHREAD_API int pthread_mutex_unlock(pthread_mutex_t *m);
296347
WINPTHREAD_API int pthread_mutex_trylock(pthread_mutex_t *m);
297348
WINPTHREAD_API int pthread_mutex_init(pthread_mutex_t *m, const pthread_mutexattr_t *a);
@@ -345,7 +396,6 @@ WINPTHREAD_API int pthread_condattr_getclock (const pthread_condattr_t *attr,
345396
clockid_t *clock_id);
346397
WINPTHREAD_API int pthread_condattr_setclock(pthread_condattr_t *attr,
347398
clockid_t clock_id);
348-
WINPTHREAD_API int __pthread_clock_nanosleep(clockid_t clock_id, int flags, const struct timespec *rqtp, struct timespec *rmtp);
349399

350400
WINPTHREAD_API int pthread_barrierattr_init(void **attr);
351401
WINPTHREAD_API int pthread_barrierattr_destroy(void **attr);
@@ -357,9 +407,6 @@ WINPTHREAD_API struct _pthread_cleanup ** pthread_getclean (void);
357407
WINPTHREAD_API void * pthread_gethandle (pthread_t t);
358408
WINPTHREAD_API void * pthread_getevent (void);
359409

360-
WINPTHREAD_API unsigned long long _pthread_rel_time_in_ms(const struct timespec *ts);
361-
WINPTHREAD_API unsigned long long _pthread_time_in_ms(void);
362-
WINPTHREAD_API unsigned long long _pthread_time_in_ms_from_timespec(const struct timespec *ts);
363410
WINPTHREAD_API int _pthread_tryjoin (pthread_t t, void **res);
364411
WINPTHREAD_API int pthread_rwlockattr_destroy(pthread_rwlockattr_t *a);
365412
WINPTHREAD_API int pthread_rwlockattr_getpshared(pthread_rwlockattr_t *a, int *s);

mingw32/include/pthread_compat.h

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,12 @@
6060
#ifndef WIN_PTHREADS_PTHREAD_COMPAT_H
6161
#define WIN_PTHREADS_PTHREAD_COMPAT_H
6262

63+
#if defined(_USE_32BIT_TIME_T) || (defined(_TIME_BITS) && _TIME_BITS == 32)
64+
#define WINPTHREADS_TIME_BITS 32
65+
#else
66+
#define WINPTHREADS_TIME_BITS 64
67+
#endif
68+
6369
#if defined(IN_WINPTHREAD)
6470
# if defined(DLL_EXPORT)
6571
# define WINPTHREAD_API __declspec(dllexport) /* building the DLL */
@@ -97,7 +103,8 @@ typedef unsigned short mode_t;
97103

98104
#ifdef __GNUC__
99105

100-
#define WINPTHREADS_INLINE inline
106+
#define WINPTHREADS_INLINE __inline__
107+
#define WINPTHREADS_ALWAYS_INLINE __inline__ __attribute__((__always_inline__))
101108
#define WINPTHREADS_ATTRIBUTE(X) __attribute__(X)
102109
#define WINPTHREADS_SECTION(X) __section__(X)
103110

@@ -110,9 +117,32 @@ typedef int pid_t;
110117
#endif
111118

112119
#define WINPTHREADS_INLINE __inline
120+
#define WINPTHREADS_ALWAYS_INLINE __inline __forceinline
113121
#define WINPTHREADS_ATTRIBUTE(X) __declspec X
114122
#define WINPTHREADS_SECTION(X) allocate(X)
115123

116124
#endif
117125

126+
#ifndef WINPTHREAD_CLOCK_DECL
127+
#define WINPTHREAD_CLOCK_DECL static WINPTHREADS_ALWAYS_INLINE
128+
#endif
129+
#ifndef WINPTHREAD_COND_DECL
130+
#define WINPTHREAD_COND_DECL static WINPTHREADS_ALWAYS_INLINE
131+
#endif
132+
#ifndef WINPTHREAD_MUTEX_DECL
133+
#define WINPTHREAD_MUTEX_DECL static WINPTHREADS_ALWAYS_INLINE
134+
#endif
135+
#ifndef WINPTHREAD_NANOSLEEP_DECL
136+
#define WINPTHREAD_NANOSLEEP_DECL static WINPTHREADS_ALWAYS_INLINE
137+
#endif
138+
#ifndef WINPTHREAD_RWLOCK_DECL
139+
#define WINPTHREAD_RWLOCK_DECL static WINPTHREADS_ALWAYS_INLINE
140+
#endif
141+
#ifndef WINPTHREAD_SEM_DECL
142+
#define WINPTHREAD_SEM_DECL static WINPTHREADS_ALWAYS_INLINE
143+
#endif
144+
#ifndef WINPTHREAD_THREAD_DECL
145+
#define WINPTHREAD_THREAD_DECL static WINPTHREADS_ALWAYS_INLINE
146+
#endif
147+
118148
#endif

mingw32/include/pthread_time.h

Lines changed: 53 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -73,12 +73,60 @@
7373
extern "C" {
7474
#endif
7575

76-
WINPTHREAD_API int __cdecl nanosleep(const struct timespec *request, struct timespec *remain);
76+
WINPTHREAD_API int __cdecl nanosleep32(const struct _timespec32 *request, struct _timespec32 *remain);
77+
WINPTHREAD_API int __cdecl nanosleep64(const struct _timespec64 *request, struct _timespec64 *remain);
78+
WINPTHREAD_NANOSLEEP_DECL int __cdecl nanosleep(const struct timespec *request, struct timespec *remain)
79+
{
80+
#if WINPTHREADS_TIME_BITS == 32
81+
return nanosleep32 ((struct _timespec32 *)request, (struct _timespec32 *)remain);
82+
#else
83+
return nanosleep64 ((struct _timespec64 *)request, (struct _timespec64 *)remain);
84+
#endif
85+
}
7786

78-
WINPTHREAD_API int __cdecl clock_nanosleep(clockid_t clock_id, int flags, const struct timespec *request, struct timespec *remain);
79-
WINPTHREAD_API int __cdecl clock_getres(clockid_t clock_id, struct timespec *res);
80-
WINPTHREAD_API int __cdecl clock_gettime(clockid_t clock_id, struct timespec *tp);
81-
WINPTHREAD_API int __cdecl clock_settime(clockid_t clock_id, const struct timespec *tp);
87+
WINPTHREAD_API int __cdecl clock_nanosleep32(clockid_t clock_id, int flags, const struct _timespec32 *request, struct _timespec32 *remain);
88+
WINPTHREAD_API int __cdecl clock_nanosleep64(clockid_t clock_id, int flags, const struct _timespec64 *request, struct _timespec64 *remain);
89+
WINPTHREAD_CLOCK_DECL int __cdecl clock_nanosleep(clockid_t clock_id, int flags, const struct timespec *request, struct timespec *remain)
90+
{
91+
#if WINPTHREADS_TIME_BITS == 32
92+
return clock_nanosleep32 (clock_id, flags, (struct _timespec32 *)request, (struct _timespec32 *)remain);
93+
#else
94+
return clock_nanosleep64 (clock_id, flags, (struct _timespec64 *)request, (struct _timespec64 *)remain);
95+
#endif
96+
}
97+
98+
WINPTHREAD_API int __cdecl clock_getres32(clockid_t clock_id, struct _timespec32 *res);
99+
WINPTHREAD_API int __cdecl clock_getres64(clockid_t clock_id, struct _timespec64 *res);
100+
WINPTHREAD_CLOCK_DECL int __cdecl clock_getres(clockid_t clock_id, struct timespec *res)
101+
{
102+
#if WINPTHREADS_TIME_BITS == 32
103+
return clock_getres32 (clock_id, (struct _timespec32 *)res);
104+
#else
105+
return clock_getres64 (clock_id, (struct _timespec64 *)res);
106+
#endif
107+
}
108+
109+
WINPTHREAD_API int __cdecl clock_gettime32(clockid_t clock_id, struct _timespec32 *tp);
110+
WINPTHREAD_API int __cdecl clock_gettime64(clockid_t clock_id, struct _timespec64 *tp);
111+
WINPTHREAD_CLOCK_DECL int __cdecl clock_gettime(clockid_t clock_id, struct timespec *tp)
112+
{
113+
#if WINPTHREADS_TIME_BITS == 32
114+
return clock_gettime32 (clock_id, (struct _timespec32 *)tp);
115+
#else
116+
return clock_gettime64 (clock_id, (struct _timespec64 *)tp);
117+
#endif
118+
}
119+
120+
WINPTHREAD_API int __cdecl clock_settime32(clockid_t clock_id, const struct _timespec32 *tp);
121+
WINPTHREAD_API int __cdecl clock_settime64(clockid_t clock_id, const struct _timespec64 *tp);
122+
WINPTHREAD_CLOCK_DECL int __cdecl clock_settime(clockid_t clock_id, const struct timespec *tp)
123+
{
124+
#if WINPTHREADS_TIME_BITS == 32
125+
return clock_settime32 (clock_id, (struct _timespec32 *)tp);
126+
#else
127+
return clock_settime64 (clock_id, (struct _timespec64 *)tp);
128+
#endif
129+
}
82130

83131
#ifdef __cplusplus
84132
}

mingw32/include/semaphore.h

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,16 @@ WINPTHREAD_API int sem_trywait(sem_t *sem);
4343

4444
WINPTHREAD_API int sem_wait(sem_t *sem);
4545

46-
WINPTHREAD_API int sem_timedwait(sem_t * sem, const struct timespec *t);
46+
WINPTHREAD_API int sem_timedwait32(sem_t * sem, const struct _timespec32 *t);
47+
WINPTHREAD_API int sem_timedwait64(sem_t * sem, const struct _timespec64 *t);
48+
WINPTHREAD_SEM_DECL int sem_timedwait(sem_t * sem, const struct timespec *t)
49+
{
50+
#if WINPTHREADS_TIME_BITS == 32
51+
return sem_timedwait32 (sem, (const struct _timespec32 *) t);
52+
#else
53+
return sem_timedwait64 (sem, (const struct _timespec64 *) t);
54+
#endif
55+
}
4756

4857
WINPTHREAD_API int sem_post(sem_t *sem);
4958

0 commit comments

Comments
 (0)