Commit d535b3b1 authored by Antoine Lemasson's avatar Antoine Lemasson
Browse files

addin c++ checks

parent f16596a0
......@@ -7,6 +7,16 @@ include ( CTest )
ENABLE_TESTING()
ADD_TEST ( MFMlibrary MFMtest.exe "-test -v=6")
include(CheckCXXCompilerFlag)
CHECK_CXX_COMPILER_FLAG("-std=c++11" WITH_CPP11)
if(WITH_CPP11)
set(CMAKE_CXX_FLAGS "-std=c++11 ${CMAKE_CXX_FLAGS}")
else(WITH_CPP11)
CHECK_CXX_COMPILER_FLAG("-std=c++0x" WITH_CPP0X)
if(WITH_CPP0X)
set(CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}")
endif(WITH_CPP0X)
endif(WITH_CPP11)
if(DEBUG)
set(CMAKE_BUILD_TYPE Debug)
......
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