diff --git a/src/OpenGl/OpenGl_SceneGeometry.cxx b/src/OpenGl/OpenGl_SceneGeometry.cxx index aca6a47438..05f83ca43e 100755 --- a/src/OpenGl/OpenGl_SceneGeometry.cxx +++ b/src/OpenGl/OpenGl_SceneGeometry.cxx @@ -22,6 +22,14 @@ #include #ifdef HAVE_TBB + // On Windows, function TryEnterCriticalSection has appeared in Windows NT + // and is surrounded by #ifdef in MS VC++ 7.1 headers. + // Thus to use it we need to define appropriate macro saying that we wil + // run on Windows NT 4.0 at least + #if ((defined(_WIN32) || defined(__WIN32__)) && !defined(_WIN32_WINNT)) + #define _WIN32_WINNT 0x0501 + #endif + #include #endif