diff options
author | Peter Bell <peterbell10@live.co.uk> | 2022-04-22 23:28:53 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-04-26 17:48:02 (GMT) |
commit | e6b51a1b01be2da0cbe0260861334a3b0b3f17e7 (patch) | |
tree | 266620359e4ae86fe024ccaaed36f332f274bbb0 /Tests/Cuda | |
parent | bcd98b5f9846d7b9d2a6518501eb7ac56139665e (diff) | |
download | CMake-e6b51a1b01be2da0cbe0260861334a3b0b3f17e7.zip CMake-e6b51a1b01be2da0cbe0260861334a3b0b3f17e7.tar.gz CMake-e6b51a1b01be2da0cbe0260861334a3b0b3f17e7.tar.bz2 |
CUDAToolkit: Add include paths for CUDA::cupti
CUDA's cupti library has its headers in a seperate directory on a
standard CUDA install, but `CUDA::cupti` only adds the default cuda
include directory.
Issue: #22761
Diffstat (limited to 'Tests/Cuda')
-rw-r--r-- | Tests/Cuda/Toolkit/CMakeLists.txt | 6 | ||||
-rw-r--r-- | Tests/Cuda/Toolkit/cupti.cpp | 7 |
2 files changed, 13 insertions, 0 deletions
diff --git a/Tests/Cuda/Toolkit/CMakeLists.txt b/Tests/Cuda/Toolkit/CMakeLists.txt index 8b42296..4df29fa 100644 --- a/Tests/Cuda/Toolkit/CMakeLists.txt +++ b/Tests/Cuda/Toolkit/CMakeLists.txt @@ -54,3 +54,9 @@ endforeach() add_executable(Toolkit main.cpp) target_link_libraries(Toolkit PRIVATE CUDA::toolkit) + +# cupti is an optional component of the CUDA toolkit +if(TARGET CUDA::cupti) + add_executable(cupti cupti.cpp) + target_link_libraries(cupti PRIVATE CUDA::cupti) +endif() diff --git a/Tests/Cuda/Toolkit/cupti.cpp b/Tests/Cuda/Toolkit/cupti.cpp new file mode 100644 index 0000000..62f7f65 --- /dev/null +++ b/Tests/Cuda/Toolkit/cupti.cpp @@ -0,0 +1,7 @@ +// Only thing we care about is that these headers are found +#include <cupti.h> + +int main() +{ + return 0; +} |