mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-11 16:32:14 -06:00
Tests: Rename CudaOnly.{All => ArchSpecial}
The purpose of the test is to cover special values of `CMAKE_CUDA_ARCHITECTURES`. Prepare to add more than just `all` and `all-major`. While at it, fix the `project()` name in the test to match what we pass to `ctest` with `--build-project`.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
cmake_minimum_required(VERSION 3.20)
|
||||
project(CudaOnlyAll CUDA)
|
||||
project(ArchSpecial CUDA)
|
||||
|
||||
if(CMAKE_CUDA_COMPILER_ID STREQUAL "NVIDIA" AND
|
||||
CMAKE_CUDA_COMPILER_VERSION VERSION_GREATER_EQUAL 8.0)
|
||||
@@ -51,6 +51,6 @@ try_compile(all_major_archs_compiles
|
||||
verify_output(all-major)
|
||||
|
||||
if(all_archs_compiles AND all_major_archs_compiles)
|
||||
add_executable(CudaOnlyAll main.cu)
|
||||
target_compile_options(CudaOnlyAll PRIVATE ${compile_options})
|
||||
add_executable(CudaOnlyArchSpecial main.cu)
|
||||
target_compile_options(CudaOnlyArchSpecial PRIVATE ${compile_options})
|
||||
endif()
|
||||
@@ -4,8 +4,8 @@ macro (add_cuda_test_macro name)
|
||||
PROPERTY LABELS "CUDA")
|
||||
endmacro ()
|
||||
|
||||
add_cuda_test_macro(CudaOnly.All CudaOnlyAll)
|
||||
add_cuda_test_macro(CudaOnly.Architecture Architecture)
|
||||
add_cuda_test_macro(CudaOnly.ArchSpecial CudaOnlyArchSpecial)
|
||||
add_cuda_test_macro(CudaOnly.CompileFlags CudaOnlyCompileFlags)
|
||||
|
||||
add_cuda_test_macro(CudaOnly.EnableStandard CudaOnlyEnableStandard)
|
||||
|
||||
Reference in New Issue
Block a user