Boost C++ Libraries: Ticket #5661: Scoped enums used for Intel compiler but /Qstd=c++0x not used, causes error with operations.hpp https://svn.boost.org/trac10/ticket/5661 <p> I'm using Intel C++ Composer XE 2011 update 4 (i.e. icl 12.0) for Windows on Intel 64 with Visual Studio 2010. When trying to build Boost 1.46.1 with the following command line: </p> <p> .\bjam stage --toolset=intel address-model=64 variant=release -- build-type=complete threading=multi --without-wave --without-python --without-mpi --without-graph --without-graph_parallel </p> <p> I get a problem compiling v2_operations.cpp: </p> <p> compile-c-c++ bin.v2\libs\filesystem\build\intel-win\release\address-model-64\threading-multi\v2\src\v2_operations.obj '"C:\Program Files (x86)\Intel\ComposerXE-2011.4.196\bin\intel64<em>iclvars.bat"' is not recognized as an internal or external command, operable program or batch file. icl: command line remark <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/10010" title="#10010: Feature Requests: Boost 1.55 does not support setting language of description in exception (closed: wontfix)">#10010</a>: option '/Og' is deprecated and will be removed in a future release. See '/help deprecated' icl: command line warning <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/10148" title="#10148: Bugs: Can't build on Solaris SPARC (closed: fixed)">#10148</a>: option '/Oy' not supported icl: command line remark <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/10010" title="#10010: Feature Requests: Boost 1.55 does not support setting language of description in exception (closed: wontfix)">#10010</a>: option '/Op' is deprecated and will be removed in a future release. See '/help deprecated' v2_operations.cpp .\boost/filesystem/v2/operations.hpp(511): error: expected either a definition or a tag name </em></p> <blockquote> <p> BOOST_SCOPED_ENUM_START(copy_option) <sup> </sup></p> </blockquote> <p> This happens because BOOST_SCOPED_ENUM_START(copy_option) is preprocessed into: </p> <blockquote> <p> enum class copy_option </p> </blockquote> <p> which happens because of the following code in boost\config\compiler\intel.hpp: </p> <p> #if defined(_MSC_VER) &amp;&amp; (_MSC_VER &gt;= 1600) # define BOOST_INTEL_STDCXX0X #endif </p> <p> and then later: </p> <p> #if defined(BOOST_INTEL_STDCXX0X) &amp;&amp; (BOOST_INTEL_CXX_VERSION &gt;= 1200) # undef BOOST_NO_RVALUE_REFERENCES # undef BOOST_NO_SCOPED_ENUMS &lt;snip&gt; </p> <p> The problem becomes then that the assumption is made that the compiler will support C++0x, but the Intel compiler requires the /Qstd=c++0x command line option to support this mode, and this is not used when v2_operations.cpp is compiled. If I add /Qstd=c++0x to intel-win.jam, then the build works. </p> <p> You can see <a class="ext-link" href="http://software.intel.com/en-us/forums/showthread.php?t=83556"><span class="icon">​</span>http://software.intel.com/en-us/forums/showthread.php?t=83556</a> for a reference for a customer running into this. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/5661 Trac 1.4.3 anonymous Thu, 30 Jun 2011 05:03:51 GMT component changed; owner set https://svn.boost.org/trac10/ticket/5661#comment:1 https://svn.boost.org/trac10/ticket/5661#comment:1 <ul> <li><strong>owner</strong> set to <span class="trac-author">John Maddock</span> </li> <li><strong>component</strong> <span class="trac-field-old">Building Boost</span> → <span class="trac-field-new">config</span> </li> </ul> Ticket John Maddock Sat, 02 Jul 2011 12:01:34 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/5661#comment:2 https://svn.boost.org/trac10/ticket/5661#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> This has actually already been fixed - and will will released in 1.47. </p> <p> Do you know is there a way to tell when /Qstd=c++0x has been passed to the compiler? </p> Ticket