You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
masterleinad opened this issue
Mar 27, 2024
· 1 comment
Labels
BugBroken / incorrect code; it could be Kokkos' responsibility, or others’ (e.g., Trilinos)CMakeInDevelopEnhancement, fix, etc. has been merged into the develop branch;
CMake Error at /app/kokkos-install/lib/cmake/Kokkos/KokkosConfig.cmake:41 (SET_TARGET_PROPERTIES):
The link interface of target "CUDA::cudart" contains:
CUDA::cudart_static_deps
but the target was not found. Possible reasons include:
* There is a typo in the target name.
* A find_package call is missing for an IMPORTED target.
* An ALIAS target is missing.
Call Stack (most recent call first):
CMakeLists.txt:10 (find_package)
if(NOT TARGET CUDA::cudart_static_deps)
add_library(CUDA::cudart_static_deps IMPORTED INTERFACE)
if(UNIX AND (CMAKE_C_COMPILER OR CMAKE_CXX_COMPILER))
find_package(Threads REQUIRED)
target_link_libraries(CUDA::cudart_static_deps INTERFACE Threads::Threads ${CMAKE_DL_LIBS})
endif()
if(UNIX AND NOT APPLE AND NOT (CMAKE_SYSTEM_NAME STREQUAL "QNX"))
# On Linux, you must link against librt when using the static cuda runtime.
find_library(CUDAToolkit_rt_LIBRARY rt)
mark_as_advanced(CUDAToolkit_rt_LIBRARY)
if(NOT CUDAToolkit_rt_LIBRARY)
message(WARNING "Could not find librt library, needed by CUDA::cudart_static")
else()
target_link_libraries(CUDA::cudart_static_deps INTERFACE ${CUDAToolkit_rt_LIBRARY})
endif()
endif()
endif()
which means that we need to export CUDA::cudart_static_deps, and Threads::Threads as well (and refind Threads).
The text was updated successfully, but these errors were encountered:
#6902 provides a hotfix but we should revisit in #6164.
ajpowelsnl
added
CMake
Bug
Broken / incorrect code; it could be Kokkos' responsibility, or others’ (e.g., Trilinos)
InDevelop
Enhancement, fix, etc. has been merged into the develop branch;
labels
Apr 1, 2024
BugBroken / incorrect code; it could be Kokkos' responsibility, or others’ (e.g., Trilinos)CMakeInDevelopEnhancement, fix, etc. has been merged into the develop branch;
With
CMake 3.28.4
, we are gettingwhen trying to link against
Kokkos::kokkos
. Kitware/CMake@4a3cafe to fix https://gitlab.kitware.com/cmake/cmake/-/issues/25665 seems responsible. Basically,FindCUDAToolkit.cmake
now adds more dependencies to targets that we don't export. More precisely it'swhich means that we need to export
CUDA::cudart_static_deps
, andThreads::Threads
as well (and refindThreads
).The text was updated successfully, but these errors were encountered: