summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler/NVIDIA-CUDA.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2016-12-06 21:22:25 (GMT)
committerBrad King <brad.king@kitware.com>2016-12-09 19:19:22 (GMT)
commit7552d16d1a9ccfc86490b1052ed4719a704ae358 (patch)
treedcbe6e120b1670979f450cef63bb555b32860136 /Modules/Compiler/NVIDIA-CUDA.cmake
parent0c38000393aef700b22a596e35c7975c7a7b1ad4 (diff)
downloadCMake-7552d16d1a9ccfc86490b1052ed4719a704ae358.zip
CMake-7552d16d1a9ccfc86490b1052ed4719a704ae358.tar.gz
CMake-7552d16d1a9ccfc86490b1052ed4719a704ae358.tar.bz2
CUDA: Fix default compiler flag initialization
Since commit v3.7.0-rc1~392^2 (Honor CMAKE_<LANG>_FLAGS[_<CONFIG>]_INIT set in toolchain files, 2016-07-05) our convention is to initialize compiler flag variables via `string(APPEND)` rather than `set()`. Fix the convention for `CMAKE_CUDA_FLAGS[_<CONFIG>]_INIT`.
Diffstat (limited to 'Modules/Compiler/NVIDIA-CUDA.cmake')
-rw-r--r--Modules/Compiler/NVIDIA-CUDA.cmake10
1 files changed, 5 insertions, 5 deletions
diff --git a/Modules/Compiler/NVIDIA-CUDA.cmake b/Modules/Compiler/NVIDIA-CUDA.cmake
index e3ff5e3..605d555 100644
--- a/Modules/Compiler/NVIDIA-CUDA.cmake
+++ b/Modules/Compiler/NVIDIA-CUDA.cmake
@@ -10,11 +10,11 @@ set(CMAKE_SHARED_LIBRARY_CREATE_CUDA_FLAGS -shared)
set(CMAKE_INCLUDE_SYSTEM_FLAG_CUDA -isystem=)
set(CMAKE_CUDA_COMPILE_OPTIONS_VISIBILITY -Xcompiler=-fvisibility=)
-set(CMAKE_CUDA_FLAGS_INIT " ")
-set(CMAKE_CUDA_FLAGS_DEBUG_INIT " -g")
-set(CMAKE_CUDA_FLAGS_MINSIZEREL_INIT " -Os -DNDEBUG")
-set(CMAKE_CUDA_FLAGS_RELEASE_INIT " -O3 -DNDEBUG")
-set(CMAKE_CUDA_FLAGS_RELWITHDEBINFO_INIT " -O2 -g -DNDEBUG")
+string(APPEND CMAKE_CUDA_FLAGS_INIT " ")
+string(APPEND CMAKE_CUDA_FLAGS_DEBUG_INIT " -g")
+string(APPEND CMAKE_CUDA_FLAGS_MINSIZEREL_INIT " -Os -DNDEBUG")
+string(APPEND CMAKE_CUDA_FLAGS_RELEASE_INIT " -O3 -DNDEBUG")
+string(APPEND CMAKE_CUDA_FLAGS_RELWITHDEBINFO_INIT " -O2 -g -DNDEBUG")
set(CMAKE_CUDA98_STANDARD_COMPILE_OPTION "")
set(CMAKE_CUDA98_EXTENSION_COMPILE_OPTION "")