[Boost-bugs] [Boost C++ Libraries] #5661: Scoped enums used for Intel compiler but /Qstd=c++0x not used, causes error with operations.hpp

Subject: [Boost-bugs] [Boost C++ Libraries] #5661: Scoped enums used for Intel compiler but /Qstd=c++0x not used, causes error with operations.hpp
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-06-29 23:23:07


#5661: Scoped enums used for Intel compiler but /Qstd=c++0x not used, causes error
with operations.hpp
---------------------------------------------------------+------------------
 Reporter: Brandon Hewitt <brandon.l.hewitt@…> | Owner:
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: Building Boost
  Version: Boost 1.46.1 | Severity: Problem
 Keywords: |
---------------------------------------------------------+------------------
 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:

 .\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

 I get a problem compiling v2_operations.cpp:

 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//iclvars.bat"' is not
 recognized as an internal or external command,
 operable program or batch file.
 icl: command line remark #10010: option '/Og' is deprecated and will be
 removed in a future release. See '/help deprecated'
 icl: command line warning #10148: option '/Oy' not supported
 icl: command line remark #10010: 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
       BOOST_SCOPED_ENUM_START(copy_option)
       ^
 This happens because BOOST_SCOPED_ENUM_START(copy_option) is preprocessed
 into:

   enum class copy_option

 which happens because of the following code in
 boost\config\compiler\intel.hpp:

 #if defined(_MSC_VER) && (_MSC_VER >= 1600)
 # define BOOST_INTEL_STDCXX0X
 #endif

 and then later:

 #if defined(BOOST_INTEL_STDCXX0X) && (BOOST_INTEL_CXX_VERSION >= 1200)
 # undef BOOST_NO_RVALUE_REFERENCES
 # undef BOOST_NO_SCOPED_ENUMS
 <snip>

 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.

 You can see http://software.intel.com/en-us/forums/showthread.php?t=83556
 for a reference for a customer running into this.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/5661>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:06 UTC