winpthreads: add support for _USE_32BIT_TIME_T and _TIME_BITS
This patch adds handling for CRT's _USE_32BIT_TIME_T and
POSIX _TIME_BITS macros.
This patch adds two versions of each public function which uses
`struct timespec`. One version with suffix `32`, which uses
`struct _timespec32` and one version with suffix `64`, which uses
`struct _timespec64`.
The plain versions without the suffix are implemented as static inline functions
which call explicitly sized version and perform type cast from
`struct timespec*` to explicitly sized version of the structure.
External symbols for plain versions are still provided.
They use either 32- or 64-suffixed version internally.
pthread_compat.h:
- new macro `WINPTHREADS_TIME_BITS` has been added
- new macro `WINPTHREADS_ALWAYS_INLINE` has been added
- a few new supplementary macros have been added
pthread.h:
Function `__pthread_clock_nanosleep` has been removed.
winpthreads now provides `clock_nanosleep` with standard POSIX name.
Signed-off-by: Kirill Makurin <maiddaisuki@outlook.com>
Signed-off-by: LIU Hao <lh_mouse@126.com>
13 files changed