X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/d624a13aa65e36f2a7c55ca8b2b4cb7d2aa37916..2434cd24de2d531a46c3b7089f490ddce659c566:/CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt index 945f9ef3f4..94a78f409f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -412,9 +412,6 @@ if (enable_model-checking AND enable_ns3) endif() get_property(known_features GLOBAL PROPERTY CMAKE_CXX_KNOWN_FEATURES) -if (enable_model-checking AND (NOT ("cxx_std_14" IN_LIST known_features))) - message(FATAL_ERROR "Model-checking requires C++14. Please upgrade your compiler") -endif() if(enable_smpi) SET(HAVE_SMPI 1) @@ -778,6 +775,14 @@ if(enable_java) include(${CMAKE_HOME_DIRECTORY}/tools/cmake/Java.cmake) endif() +if (enable_model-checking AND (NOT ("cxx_std_14" IN_LIST known_features))) + message(WARNING "C++14 not found. The model-checker will use a slow hash function. You should upgrade your compiler") + set(SG_HAVE_CPP14 0) +else() + set(SG_HAVE_CPP14 1) + set_property(TARGET simgrid PROPERTY CXX_STANDARD 14) +endif() + # Python binding (with pybind11) ################ # Our usage of pybind11::overload_cast mandates C++14