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()
|
|
|
|
|
2023-03-02 02:39:29 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2019-09-28 01:41:02 +08:00
|
|
|
DISABLE_PARALLEL_CONFIGURE
|
2019-08-25 04:43:57 +08:00
|
|
|
OPTIONS
|
2023-03-02 02:39:29 +08:00
|
|
|
"-DGSL_INCLUDE_PATH=${CURRENT_INSTALLED_DIR}/include"
|
2019-08-25 04:43:57 +08:00
|
|
|
-DTELNETPP_WITH_ZLIB=${USE_ZLIB}
|
|
|
|
-DTELNETPP_WITH_TESTS=OFF
|
2017-10-03 18:58:22 +08:00
|
|
|
)
|
|
|
|
|
2023-03-02 02:39:29 +08:00
|
|
|
vcpkg_cmake_install()
|
2017-10-03 18:58:22 +08:00
|
|
|
|
2023-03-02 02:39:29 +08:00
|
|
|
vcpkg_cmake_config_fixup(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
|
2023-03-02 02:39:29 +08:00
|
|
|
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
|
2023-03-02 02:39:29 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|