diff options
author | Brad King <brad.king@kitware.com> | 2022-04-28 18:46:45 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-04-29 13:07:53 (GMT) |
commit | 7bf520069938dcb106f9c0c7cc71ac079055ceed (patch) | |
tree | 87bfe43b50cdd8542178036298dd545f53f3707e /Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake | |
parent | d35f1c9beee14f1be1e39838b5d4be0906a48974 (diff) | |
download | CMake-7bf520069938dcb106f9c0c7cc71ac079055ceed.zip CMake-7bf520069938dcb106f9c0c7cc71ac079055ceed.tar.gz CMake-7bf520069938dcb106f9c0c7cc71ac079055ceed.tar.bz2 |
CUDA: Restore CMAKE_CUDA_ARCHITECTURES support for -real and -virtual suffixes
Fix the validation regex added by commit c267ed205a (CUDA: Defer
architecture testing to the compiler testing step, 2022-04-25) to
allow these values.
Diffstat (limited to 'Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake')
-rw-r--r-- | Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake b/Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake index e37d025..3e6b3a5 100644 --- a/Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake +++ b/Tests/RunCMake/CUDA_architectures/RunCMakeTest.cmake @@ -20,3 +20,8 @@ if(CMAKE_CUDA_COMPILER_ID STREQUAL "Clang" AND CMAKE_CUDA_ARCHITECTURES) endif() run_cmake(architectures-off) unset(RunCMake_TEST_OPTIONS) + +if(CMAKE_CUDA_ARCHITECTURES MATCHES "([0-9]+)") + set(arch "${CMAKE_MATCH_1}") + run_cmake_with_options(architectures-suffix -Darch=${arch}) +endif() |