Update .dll copy for 7_libNVVM

This commit is contained in:
shawnz 2025-02-12 18:12:26 +08:00
parent 7ee6db679e
commit cc3d94f81c
5 changed files with 33 additions and 24 deletions

View File

@ -81,3 +81,12 @@ set_target_properties(mathfuncs64 PROPERTIES PREFIX "lib"
OUTPUT_NAME "mathfuncs64"
SUFFIX ".a" CUDA_SEPERABLE_COMPILATION ON)
install(TARGETS cuda-c-linking mathfuncs64 DESTINATION bin)
if (WIN32)
add_custom_command(
TARGET cuda-c-linking
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:cuda-c-linking>"
)
endif ()

View File

@ -53,10 +53,10 @@ add_custom_command(
"${CMAKE_CURRENT_SOURCE_DIR}/dsl-gpu64.ll" "$<TARGET_FILE_DIR:dsl>"
)
if (WIN32)
add_custom_command(
TARGET dsl
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:dsl>"
)
add_custom_command(
TARGET dsl
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:dsl>"
)
endif ()

View File

@ -51,10 +51,10 @@ add_custom_command(
"${CMAKE_CURRENT_SOURCE_DIR}/test.ll" "$<TARGET_FILE_DIR:ptxgen>"
)
if (WIN32)
add_custom_command(
TARGET ptxgen
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:ptxgen>"
)
add_custom_command(
TARGET ptxgen
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:ptxgen>"
)
endif ()

View File

@ -52,10 +52,10 @@ add_custom_command(
"${CMAKE_CURRENT_SOURCE_DIR}/simple-gpu64.ll" "$<TARGET_FILE_DIR:simple>"
)
if (WIN32)
add_custom_command(
TARGET simple
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:simple>"
)
add_custom_command(
TARGET simple
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:simple>"
)
endif ()

View File

@ -56,10 +56,10 @@ add_custom_command(
"${CMAKE_CURRENT_SOURCE_DIR}/uvmlite64.ll" "$<TARGET_FILE_DIR:uvmlite>"
)
if (WIN32)
add_custom_command(
TARGET uvmlite
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:uvmlite>"
)
add_custom_command(
TARGET uvmlite
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
"${CMAKE_BINARY_DIR}/nvvm64_40_0.dll" "$<TARGET_FILE_DIR:uvmlite>"
)
endif ()