Skip to content

Commit

Permalink
Automatically install dependent DLLs on Windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
levlam committed Nov 12, 2020
1 parent 5ce7448 commit f5dadbb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -882,6 +882,9 @@ install(FILES "${TL_TD_AUTO_INCLUDE_DIR}/td/telegram/td_api.h" "${TL_TD_AUTO_INC
if (TD_ENABLE_JNI)
install(FILES td/tl/tl_jni_object.h DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/td/tl")
endif()
if (MSVC AND VCPKG_TOOLCHAIN)
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/" DESTINATION "${CMAKE_INSTALL_BINDIR}" FILES_MATCHING PATTERN "*.dll")
endif()

include(CMakePackageConfigHelpers)
write_basic_package_version_file("TdConfigVersion.cmake"
Expand Down
3 changes: 3 additions & 0 deletions example/java/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,6 @@ install(TARGETS tdjni
LIBRARY DESTINATION bin
RUNTIME DESTINATION bin
)
if (MSVC AND VCPKG_TOOLCHAIN)
install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/$<CONFIG>/" DESTINATION bin FILES_MATCHING PATTERN "*.dll" PATTERN "*.pdb")
endif()

0 comments on commit f5dadbb

Please sign in to comment.