Bump CMake files to at least c++11.

Removed all configurations that explicitly test or set the c++ standard
flags. The only place the standard is now configured is at the top of
the main `CMakeLists.txt` file, which can easily be updated (e.g. if
we decide to move to c++14+). This can also be set via command-line using
```
> cmake -DCMAKE_CXX_STANDARD 14
```

Kept the `EIGEN_TEST_CXX11` flag for now - that still controls whether to
build/run the `cxx11_*` tests.  We will likely end up renaming these
tests and removing the `CXX11` subfolder.
This commit is contained in:
Antonio Sanchez
2021-08-25 11:02:42 -07:00
committed by Rasmus Munk Larsen
parent dc5b1f7d75
commit eeacbd26c8
9 changed files with 71 additions and 133 deletions

View File

@@ -286,10 +286,8 @@ ei_add_test(num_dimensions)
ei_add_test(stl_iterators)
ei_add_test(blasutil)
ei_add_test(random_matrix)
if(EIGEN_TEST_CXX11)
ei_add_test(initializer_list_construction)
ei_add_test(diagonal_matrix_variadic_ctor)
endif()
ei_add_test(initializer_list_construction)
ei_add_test(diagonal_matrix_variadic_ctor)
add_executable(bug1213 bug1213.cpp bug1213_main.cpp)
@@ -400,7 +398,6 @@ if(CUDA_FOUND)
set(CUDA_NVCC_FLAGS "-ccbin ${CMAKE_C_COMPILER}" CACHE STRING "nvcc flags" FORCE)
endif()
if(EIGEN_TEST_CUDA_CLANG)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
string(APPEND CMAKE_CXX_FLAGS " --cuda-path=${CUDA_TOOLKIT_ROOT_DIR}")
foreach(GPU IN LISTS EIGEN_CUDA_COMPUTE_ARCH)
string(APPEND CMAKE_CXX_FLAGS " --cuda-gpu-arch=sm_${GPU}")