diff options
author | Robert Maynard <robert.maynard@kitware.com> | 2020-09-02 18:53:41 (GMT) |
---|---|---|
committer | Zack Galbreath <zack.galbreath@kitware.com> | 2021-06-07 19:25:33 (GMT) |
commit | 947dbed0aa502c70a9e165757450bd8409036980 (patch) | |
tree | 0a45b31986184368c7ad6df72d9f9186c7a24b4c /Modules/Compiler | |
parent | b50bfc89131e55685aa41146254b37d26049b4d5 (diff) | |
download | CMake-947dbed0aa502c70a9e165757450bd8409036980.zip CMake-947dbed0aa502c70a9e165757450bd8409036980.tar.gz CMake-947dbed0aa502c70a9e165757450bd8409036980.tar.bz2 |
HIP: Automatically inject the `hip::device` runtime target
Any target that might need to link to hip code needs the `hip::device`
target
Diffstat (limited to 'Modules/Compiler')
-rw-r--r-- | Modules/Compiler/Clang-HIP.cmake | 4 | ||||
-rw-r--r-- | Modules/Compiler/ROCMClang-HIP.cmake | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/Modules/Compiler/Clang-HIP.cmake b/Modules/Compiler/Clang-HIP.cmake index 6ac39de..1030a43 100644 --- a/Modules/Compiler/Clang-HIP.cmake +++ b/Modules/Compiler/Clang-HIP.cmake @@ -14,3 +14,7 @@ endif() set(CMAKE_HIP_RUNTIME_LIBRARY_DEFAULT "SHARED") set(CMAKE_HIP_RUNTIME_LIBRARY_LINK_OPTIONS_STATIC "") set(CMAKE_HIP_RUNTIME_LIBRARY_LINK_OPTIONS_SHARED "") + +# Populated by CMakeHIPRuntime.cmake +set(CMAKE_HIP_RUNTIME_LIBRARIES_STATIC "") +set(CMAKE_HIP_RUNTIME_LIBRARIES_SHARED "") diff --git a/Modules/Compiler/ROCMClang-HIP.cmake b/Modules/Compiler/ROCMClang-HIP.cmake index 9e792b5..7af7699 100644 --- a/Modules/Compiler/ROCMClang-HIP.cmake +++ b/Modules/Compiler/ROCMClang-HIP.cmake @@ -42,4 +42,8 @@ set(CMAKE_HIP_RUNTIME_LIBRARY_DEFAULT "SHARED") set(CMAKE_HIP_RUNTIME_LIBRARY_LINK_OPTIONS_STATIC "") set(CMAKE_HIP_RUNTIME_LIBRARY_LINK_OPTIONS_SHARED "") +# Populated by CMakeHIPRuntime.cmake +set(CMAKE_HIP_RUNTIME_LIBRARIES_STATIC "") +set(CMAKE_HIP_RUNTIME_LIBRARIES_SHARED "") + __compiler_check_default_language_standard(HIP 3.5 11) |