From 0992a06d7845b577ac03500bbc555b21e92d6c1a Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Fri, 11 Jan 2019 22:05:44 +0100 Subject: [PATCH] only ask one version of the standard for pybind11 --- CMakeLists.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 98817df26a..c399fbbf0e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -768,7 +768,6 @@ if(enable_java) endif() # Python binding, generated with pybind11 -set(PYBIND11_CPP_STANDARD -std=c++11) find_package(pybind11 2.2.0) if(NOT PYTHONLIBS_FOUND) set(pybind11_FOUND OFF) @@ -783,7 +782,7 @@ endif() if(enable_python) if(pybind11_FOUND) pybind11_add_module(python-bindings src/bindings/python/simgrid_python.cpp) - set_source_files_properties(src/bindings/python/simgrid_python.cpp PROPERTIES COMPILE_FLAGS -std=c++14) + target_compile_features(python-bindings PRIVATE cxx_std_14) target_link_libraries(python-bindings PUBLIC simgrid) set_target_properties(python-bindings PROPERTIES LIBRARY_OUTPUT_NAME simgrid) set_property(TARGET python-bindings -- 2.20.1