2017-10-03 18:58:22 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO KazDragon/telnetpp
|
2020-12-24 09:16:42 +08:00
|
|
|
REF f370ebd0c0dc6505708065ee5afdc59a6de54387 # v2.1.2 + MSVC patches
|
|
|
|
SHA512 c58cb9159a8fb6c4b089a0212a995f70f08b93877d98828aa263e9f065f42a932d98749b56741d9e711c0805dcc2dcf0607dc86b0553c4e34bd3fad99e0bf157
|
2017-10-03 18:58:22 +08:00
|
|
|
HEAD_REF master
|
2020-12-24 09:16:42 +08:00
|
|
|
PATCHES fix-install-paths.patch
|
2017-10-03 18:58:22 +08:00
|
|
|
)
|
|
|
|
|
2019-08-25 04:43:57 +08:00
|
|
|
set(USE_ZLIB OFF)
|
|
|
|
if("zlib" IN_LIST FEATURES)
|
|
|
|
set(USE_ZLIB ON)
|
|
|
|
endif()
|
|
|
|
|
2017-10-03 18:58:22 +08:00
|
|
|
vcpkg_configure_cmake(
|
|
|
|
SOURCE_PATH ${SOURCE_PATH}
|
2019-09-28 01:41:02 +08:00
|
|
|
DISABLE_PARALLEL_CONFIGURE
|
2017-10-03 18:58:22 +08:00
|
|
|
PREFER_NINJA
|
2019-08-25 04:43:57 +08:00
|
|
|
OPTIONS
|
|
|
|
-DGSL_INCLUDE_PATH=${CURRENT_INSTALLED_DIR}/include
|
|
|
|
-DTELNETPP_WITH_ZLIB=${USE_ZLIB}
|
|
|
|
-DTELNETPP_WITH_TESTS=OFF
|
2017-10-03 18:58:22 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_install_cmake()
|
|
|
|
|
2019-08-25 04:43:57 +08:00
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH share/telnetpp)
|
2017-10-03 18:58:22 +08:00
|
|
|
|
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
2019-08-25 04:43:57 +08:00
|
|
|
# Remove duplicate header files and CMake input file
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
|
|
|
file(REMOVE ${CURRENT_PACKAGES_DIR}/include/telnetpp/version.hpp.in)
|
2017-10-03 18:58:22 +08:00
|
|
|
# Handle copyright
|
2018-03-12 14:41:51 +08:00
|
|
|
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/telnetpp RENAME copyright)
|