|
@ -21,10 +21,13 @@ include(CMakeParseArguments) |
|
|
function(select_cxx_standard) |
|
|
function(select_cxx_standard) |
|
|
if(NOT PYBIND11_CPP_STANDARD) |
|
|
if(NOT PYBIND11_CPP_STANDARD) |
|
|
if(NOT MSVC) |
|
|
if(NOT MSVC) |
|
|
|
|
|
check_cxx_compiler_flag("-std=c++17" HAS_CPP17_FLAG) |
|
|
check_cxx_compiler_flag("-std=c++14" HAS_CPP14_FLAG) |
|
|
check_cxx_compiler_flag("-std=c++14" HAS_CPP14_FLAG) |
|
|
check_cxx_compiler_flag("-std=c++11" HAS_CPP11_FLAG) |
|
|
check_cxx_compiler_flag("-std=c++11" HAS_CPP11_FLAG) |
|
|
|
|
|
|
|
|
if (HAS_CPP14_FLAG) |
|
|
|
|
|
|
|
|
if (HAS_CPP17_FLAG) |
|
|
|
|
|
set(PYBIND11_CPP_STANDARD -std=c++17) |
|
|
|
|
|
elseif (HAS_CPP14_FLAG) |
|
|
set(PYBIND11_CPP_STANDARD -std=c++14) |
|
|
set(PYBIND11_CPP_STANDARD -std=c++14) |
|
|
elseif (HAS_CPP11_FLAG) |
|
|
elseif (HAS_CPP11_FLAG) |
|
|
set(PYBIND11_CPP_STANDARD -std=c++11) |
|
|
set(PYBIND11_CPP_STANDARD -std=c++11) |
|
|