2019-05-03 13:57:43 +08:00
|
|
|
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
|
|
|
|
2019-03-10 08:49:34 +08:00
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO capnproto/capnproto
|
2021-10-27 13:25:12 +08:00
|
|
|
REF v0.9.1
|
|
|
|
SHA512 BDC5960F26214139744D768CA4558B085E2D359C375A8849CA532A4C458A2DAF0EE1A1F4D00745DE5ABF353AA1E4084A2D85E5523006F23F591F21FAC2D847FD
|
2019-03-10 08:49:34 +08:00
|
|
|
HEAD_REF master
|
|
|
|
)
|
|
|
|
|
2021-10-27 13:25:12 +08:00
|
|
|
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
|
|
|
FEATURES
|
|
|
|
"openssl" OPENSSL_FEATURE
|
2019-08-01 04:01:02 +08:00
|
|
|
)
|
2019-03-10 08:49:34 +08:00
|
|
|
|
2021-10-27 13:25:12 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
|
|
|
OPTIONS
|
|
|
|
-DBUILD_TESTING=OFF
|
|
|
|
"-DWITH_OPENSSL=${OPENSSL_FEATURE}"
|
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_cmake_install()
|
2019-03-10 08:49:34 +08:00
|
|
|
|
2021-10-27 13:25:12 +08:00
|
|
|
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/CapnProto)
|
2019-03-10 08:49:34 +08:00
|
|
|
|
2020-09-28 08:54:12 +08:00
|
|
|
vcpkg_copy_tools(TOOL_NAMES capnp capnpc-c++ capnpc-capnp AUTO_CLEAN)
|
2019-03-10 08:49:34 +08:00
|
|
|
|
2021-10-27 13:25:12 +08:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/bin")
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin")
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
2019-03-10 08:49:34 +08:00
|
|
|
|
|
|
|
# Handle copyright
|
2021-10-27 13:25:12 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
2021-10-28 06:19:28 +08:00
|
|
|
|
|
|
|
vcpkg_fixup_pkgconfig()
|