-
Notifications
You must be signed in to change notification settings - Fork 320
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[MinGW32] missing timespec_get() #830
Comments
Since you say that your MinGW does have clock_gettime(), why not:
|
But it is inlined only for |
Besides your |
Easy - just use a 32-bit MinGW toolchain :) |
MinGW 32-bit does not have timespec_get(). Strangely, the 64-bit version does have it. But both have clock_gettime(), so only use timespec_get() when building under Visual Studio. Fixes #830. Signed-off-by: Paul Cercueil <[email protected]>
MinGW 32-bit does not have timespec_get(). Strangely, the 64-bit version does have it. But both have clock_gettime(), so only use timespec_get() when building under Visual Studio. Fixes #830. Signed-off-by: Paul Cercueil <[email protected]>
Trying to build for MinGW with the minimal features possible:
Yields:
My MinGW (TDM / gcc version 10.3.0) do have an inlined
clock_gettime()
in it's<pthread_time.h>
(which gets included in
<time.h>
for_POSIX_C_SOURCE > 2
).But inlined only for
__MINGW64__
! So I tried this patch:The above compiles and links for both
-DBUILD_SHARED_LIBS=0
and-DBUILD_SHARED_LIBS=1
.The text was updated successfully, but these errors were encountered: