diff options
author | Brad King <brad.king@kitware.com> | 2017-02-16 18:15:35 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2017-02-16 18:15:35 (GMT) |
commit | d1530cc9a5bf16c83d7ad9246d6a7e35a0235b3e (patch) | |
tree | 0e6a6ba6e0ec9eeb0e8ef5e97f086df97d61236a /Tests | |
parent | b9229944cf1b9f27e1fc97921e736ca17fc4eb0c (diff) | |
parent | 55fb46d273e8ab51d5df366286052c71b9008437 (diff) | |
download | CMake-d1530cc9a5bf16c83d7ad9246d6a7e35a0235b3e.zip CMake-d1530cc9a5bf16c83d7ad9246d6a7e35a0235b3e.tar.gz CMake-d1530cc9a5bf16c83d7ad9246d6a7e35a0235b3e.tar.bz2 |
Merge topic 'cuda-msvc-flags'
55fb46d2 CUDA: Fix default compiler flags on Windows
d7c80f60 CUDA: Fix test cases to not override CUDA flags
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/Cuda/Complex/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/Cuda/ProperLinkFlags/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/Cuda/WithC/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/CudaOnly/SeparateCompilation/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/CudaOnly/WithDefs/CMakeLists.txt | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/Tests/Cuda/Complex/CMakeLists.txt b/Tests/Cuda/Complex/CMakeLists.txt index 2dd6f73..450ef48 100644 --- a/Tests/Cuda/Complex/CMakeLists.txt +++ b/Tests/Cuda/Complex/CMakeLists.txt @@ -15,7 +15,7 @@ project (CudaComplex CXX CUDA) #and also bulding cpp targets that need cuda implicit libraries #verify that we can pass explicit cuda arch flags -set(CMAKE_CUDA_FLAGS "-gencode arch=compute_30,code=compute_30") +string(APPEND CMAKE_CUDA_FLAGS " -gencode arch=compute_30,code=compute_30") set(CMAKE_CUDA_STANDARD 11) set(CMAKE_CXX_STANDARD 11) set(CMAKE_CUDA_STANDARD_REQUIRED TRUE) diff --git a/Tests/Cuda/ProperLinkFlags/CMakeLists.txt b/Tests/Cuda/ProperLinkFlags/CMakeLists.txt index a9eb8bd..b6e0e39 100644 --- a/Tests/Cuda/ProperLinkFlags/CMakeLists.txt +++ b/Tests/Cuda/ProperLinkFlags/CMakeLists.txt @@ -9,7 +9,7 @@ project (ProperLinkFlags CUDA CXX) #Specify a set of valid CUDA flags and an invalid set of CXX flags ( for CUDA ) #to make sure we don't use the CXX flags when linking CUDA executables -set(CMAKE_CUDA_FLAGS "-arch=sm_35 --use_fast_math") +string(APPEND CMAKE_CUDA_FLAGS " -arch=sm_35 --use_fast_math") set(CMAKE_CXX_FLAGS "-Wall") set(CMAKE_CXX_STANDARD 11) diff --git a/Tests/Cuda/WithC/CMakeLists.txt b/Tests/Cuda/WithC/CMakeLists.txt index 7596804..1f25ab4 100644 --- a/Tests/Cuda/WithC/CMakeLists.txt +++ b/Tests/Cuda/WithC/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.7) project(CudaComplex CUDA C) -set(CMAKE_CUDA_FLAGS "-gencode arch=compute_30,code=compute_30") +string(APPEND CMAKE_CUDA_FLAGS " -gencode arch=compute_30,code=compute_30") add_executable(CudaWithC main.c cuda.cu) diff --git a/Tests/CudaOnly/SeparateCompilation/CMakeLists.txt b/Tests/CudaOnly/SeparateCompilation/CMakeLists.txt index 7055eef..d134b96 100644 --- a/Tests/CudaOnly/SeparateCompilation/CMakeLists.txt +++ b/Tests/CudaOnly/SeparateCompilation/CMakeLists.txt @@ -9,7 +9,7 @@ project (CudaOnlySeparateCompilation CUDA) #and executables. #We complicate the matter by also testing that multiple static libraries #all containing cuda separable compilation code links properly -set(CMAKE_CUDA_FLAGS "-gencode arch=compute_30,code=compute_30") +string(APPEND CMAKE_CUDA_FLAGS " -gencode arch=compute_30,code=compute_30") set(CMAKE_CXX_STANDARD 11) set(CMAKE_CUDA_STANDARD 11) add_library(CUDASerarateLibA STATIC file1.cu file2.cu file3.cu) diff --git a/Tests/CudaOnly/WithDefs/CMakeLists.txt b/Tests/CudaOnly/WithDefs/CMakeLists.txt index 6c4011c..2646d29 100644 --- a/Tests/CudaOnly/WithDefs/CMakeLists.txt +++ b/Tests/CudaOnly/WithDefs/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.7) project (CudaOnlyWithDefs CUDA) #verify that we can pass explicit cuda arch flags -set(CMAKE_CUDA_FLAGS "-gencode arch=compute_30,code=compute_30") +string(APPEND CMAKE_CUDA_FLAGS " -gencode arch=compute_30,code=compute_30") set(debug_compile_flags --generate-code arch=compute_20,code=sm_20) if(CMAKE_CUDA_SIMULATE_ID STREQUAL "MSVC") list(APPEND debug_compile_flags -Xcompiler=-WX) |