본문 바로가기

개발 Note/C++11,14 (modern C++)

C++11 사용 하는 방법

반응형

C++ 11 을 사용하기 위해서는 gcc 의 경우에는 -std=c++11를 넣어줘야 합니다.

 

CMake 를 이용할 경우 아래와 같이 사용할 수 있습니다.

SET(CMAKE_CXX_FLAGS "-std=c++0x")

 

 

  • GCC: 4.5. You must specify the -std=c++11 option.
  • Intel C++ Compiler: 11. Specify the /Qstd=c++0x option.
  • Microsoft Visual C++ 2010 (included in Visual Studio 2010).