The error message sounds like macro related.
With some tests we found this issue is limited to WinSDK 16299 (I also tested 19041 and that works), and can be solve by defining WIN32_LEAN_AND_MEAN.
I think it should be better to ask for fix in upstream, as guarding #define around #include <windows.h>.
When building pthreadpool as part of pytorch on Windows, we got strange compile errors. Issue is originally filed in: https://github.com/pytorch/pytorch/issues/48895
The error message sounds like macro related. With some tests we found this issue is limited to WinSDK 16299 (I also tested 19041 and that works), and can be solve by defining
WIN32_LEAN_AND_MEAN
. I think it should be better to ask for fix in upstream, as guarding#define
around#include <windows.h>
.