Boost C++ Libraries: Ticket #6908: Compile error due to unprotected definitions of _WIN32_WINNT and WINVER https://svn.boost.org/trac10/ticket/6908 <p> Environment: Visual Studio 9 on Windows 7 SP1 64-bit (compiling for 32-bit) </p> <p> Boost versions: at least 1.47.0, up to trunk </p> <p> libs/thread/src/win32/thread.cpp defines _WIN32_WINNT and WINVER outside of #ifndef/#endif, leading to a macro redefinition that results in a compile error when _WIN32_IE is set to something other than 0x0600. Specifically, this error prevents compiling Boost.Threads when defining WINVER=_WIN32_WINNT=0x0601 for Windows 7, with _WIN32_IE=0x0700. </p> <p> Suggested solutions: Unless there is some technical reason for redefining them locally, these macros should either not be defined, or should be protected by #ifndef/#endif pairs. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/6908 Trac 1.4.3 viboes Mon, 28 May 2012 16:10:15 GMT owner, status changed https://svn.boost.org/trac10/ticket/6908#comment:1 https://svn.boost.org/trac10/ticket/6908#comment:1 <ul> <li><strong>owner</strong> changed from <span class="trac-author">Anthony Williams</span> to <span class="trac-author">viboes</span> </li> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">assigned</span> </li> </ul> <p> I don't know why this was defined. Please could you provide a working patch protecting the definition. </p> Ticket Demian Nave <dnave@…> Mon, 28 May 2012 18:10:43 GMT attachment set https://svn.boost.org/trac10/ticket/6908 https://svn.boost.org/trac10/ticket/6908 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">thread.cpp.patch</span> </li> </ul> Ticket viboes Sun, 03 Jun 2012 18:14:08 GMT milestone changed https://svn.boost.org/trac10/ticket/6908#comment:2 https://svn.boost.org/trac10/ticket/6908#comment:2 <ul> <li><strong>milestone</strong> <span class="trac-field-old">To Be Determined</span> → <span class="trac-field-new">Boost 1.51.0</span> </li> </ul> <p> Committed in trunk at revision 78802. </p> Ticket viboes Thu, 21 Jun 2012 21:18:50 GMT status, milestone changed; resolution set https://svn.boost.org/trac10/ticket/6908#comment:3 https://svn.boost.org/trac10/ticket/6908#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> <li><strong>milestone</strong> <span class="trac-field-old">Boost 1.51.0</span> → <span class="trac-field-new">Boost 1.50.0</span> </li> </ul> <p> Merged to release branch. </p> Ticket