summaryrefslogtreecommitdiffstats
path: root/Tests/CudaOnly/TryCompileTargetStatic
diff options
context:
space:
mode:
authorRobert Maynard <rmaynard@nvidia.com>2023-11-07 15:48:32 (GMT)
committerRobert Maynard <rmaynard@nvidia.com>2023-11-07 15:48:32 (GMT)
commitd7642a7d423aa5e182dd188849f2ce0453bf9515 (patch)
tree99ea8d2153e2e135897b929002c7a8faf1526814 /Tests/CudaOnly/TryCompileTargetStatic
parent5afd411ed0722869ae1be535ba0f9549009b5acc (diff)
downloadCMake-d7642a7d423aa5e182dd188849f2ce0453bf9515.zip
CMake-d7642a7d423aa5e182dd188849f2ce0453bf9515.tar.gz
CMake-d7642a7d423aa5e182dd188849f2ce0453bf9515.tar.bz2
CUDA: Support CMAKE_TRY_COMPILE_TARGET_TYPE of STATIC_LIBRARY
Diffstat (limited to 'Tests/CudaOnly/TryCompileTargetStatic')
-rw-r--r--Tests/CudaOnly/TryCompileTargetStatic/CMakeLists.txt6
-rw-r--r--Tests/CudaOnly/TryCompileTargetStatic/main.cu5
2 files changed, 11 insertions, 0 deletions
diff --git a/Tests/CudaOnly/TryCompileTargetStatic/CMakeLists.txt b/Tests/CudaOnly/TryCompileTargetStatic/CMakeLists.txt
new file mode 100644
index 0000000..340c1c9
--- /dev/null
+++ b/Tests/CudaOnly/TryCompileTargetStatic/CMakeLists.txt
@@ -0,0 +1,6 @@
+cmake_minimum_required(VERSION 3.25)
+
+set(CMAKE_TRY_COMPILE_TARGET_TYPE STATIC_LIBRARY)
+project(TryCompileTargetStatic LANGUAGES CUDA)
+
+add_executable(CudaOnlyTryCompileTargetStatic main.cu)
diff --git a/Tests/CudaOnly/TryCompileTargetStatic/main.cu b/Tests/CudaOnly/TryCompileTargetStatic/main.cu
new file mode 100644
index 0000000..766b775
--- /dev/null
+++ b/Tests/CudaOnly/TryCompileTargetStatic/main.cu
@@ -0,0 +1,5 @@
+
+int main()
+{
+ return 0;
+}