diff --git a/src/utils/fluid_sys.c b/src/utils/fluid_sys.c index ee2fd677e..4a9babe19 100644 --- a/src/utils/fluid_sys.c +++ b/src/utils/fluid_sys.c @@ -30,6 +30,12 @@ #include "fluid_rtkit.h" #endif +#if HAVE_PTHREAD_H && !defined(WIN32) +// Do not include pthread on windows. It includes winsock.h, which collides with ws2tcpip.h from fluid_sys.h +// It isn't need on Windows anyway. +#include +#endif + /* WIN32 HACK - Flag used to differentiate between a file descriptor and a socket. * Should work, so long as no SOCKET or file descriptor ends up with this bit set. - JG */ #ifdef _WIN32 diff --git a/src/utils/fluid_sys.h b/src/utils/fluid_sys.h index 3d5a61244..9f2d6f6c7 100644 --- a/src/utils/fluid_sys.h +++ b/src/utils/fluid_sys.h @@ -97,10 +97,6 @@ #include #endif -#if HAVE_PTHREAD_H -#include -#endif - #if HAVE_OPENMP #include #endif