"git@developer.sourcefind.cn:OpenDAS/dgl.git" did not exist on "7bad9178baa2742d633b030c44b3ea5db626942e"
Commit 5ba92d9f authored by Davis King's avatar Davis King
Browse files

Made this test try to enable C++11 via the compiler flag.

parent 51bc1dd4
cmake_minimum_required(VERSION 2.8.4) cmake_minimum_required(VERSION 2.8.4)
project(cpp11_test) project(cpp11_test)
add_library(cpp11_test STATIC cpp11_test.cpp ) # Try to enable C++11
include(CheckCXXCompilerFlag)
CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11)
CHECK_CXX_COMPILER_FLAG("-std=c++0x" COMPILER_SUPPORTS_CXX0X)
if(COMPILER_SUPPORTS_CXX11)
message(STATUS "C++11 activated.")
ADD_DEFINITIONS("-std=c++11")
elseif(COMPILER_SUPPORTS_CXX0X)
message(STATUS "C++0x activated.")
ADD_DEFINITIONS("-std=c++0x")
endif()
add_library(cpp11_test STATIC cpp11_test.cpp )
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment