Skip to content

Commit

Permalink
cmake: copy ftd2xx.dll to exe folder
Browse files Browse the repository at this point in the history
  • Loading branch information
CosmoCortney committed Nov 22, 2024
1 parent 782e34c commit 2204acc
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions MungPlex/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -181,13 +181,23 @@ if (CMAKE_BUILD_TYPE STREQUAL "Debug")
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${LOVENSE_LIB_DIR}/Debug/LovenseToys.dll
${OUT_DIR}/x64-Debug/MungPlex)

add_custom_command(TARGET MungPlex POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${FT_LIB_FOLDER}/amd64/ftd2xx64.dll
${OUT_DIR}/x64-Debug/MungPlex/ftd2xx.dll)
elseif (CMAKE_BUILD_TYPE STREQUAL "Release")
target_link_libraries(MungPlex PRIVATE ${LOVENSE_LIB_DIR}/Release/LovenseToys.lib)

add_custom_command(TARGET MungPlex POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${LOVENSE_LIB_DIR}/Release/LovenseToys.dll
${OUT_DIR}/x64-Release/MungPlex)

add_custom_command(TARGET MungPlex POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${FT_LIB_FOLDER}/amd64/ftd2xx64.dll
${OUT_DIR}/x64-Release/MungPlex/ftd2xx.dll)
endif()

# Set C++ version
Expand Down

0 comments on commit 2204acc

Please sign in to comment.