vcpkg/ports/configcat/portfile.cmake

26 lines
766 B
CMake
Raw Normal View History

if(VCPKG_TARGET_IS_WINDOWS)
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO configcat/cpp-sdk
REF "v${VERSION}"
SHA512 1c36121467df1567d3f83efe176a45adf1415fb0e62b3f6fda79d8249422010b80b8b3e1cb345166718b94171bf614693856caf1af8b9a49d4e9b89618fb008d
HEAD_REF master
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DCONFIGCAT_BUILD_TESTS=OFF
)
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(CONFIG_PATH "share/cmake/configcat")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)