2020-11-18 06:37:14 +08:00
|
|
|
if(VCPKG_TARGET_IS_WINDOWS)
|
|
|
|
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO google/libprotobuf-mutator
|
2023-06-22 13:16:23 +08:00
|
|
|
REF "v${VERSION}"
|
|
|
|
SHA512 cafc59c6c1e26a3e4873ec47f12db290739e98f229a17352c740aa17ac41f1435268eb0c45518b07e5c33280c18da1c4e363a31200569ffe636250e7c904b55e
|
2020-11-18 06:37:14 +08:00
|
|
|
HEAD_REF master
|
|
|
|
)
|
|
|
|
|
|
|
|
string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" STATIC_RUNTIME)
|
2023-03-08 06:14:52 +08:00
|
|
|
vcpkg_cmake_configure(
|
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2020-11-18 06:37:14 +08:00
|
|
|
OPTIONS
|
|
|
|
-DLIB_PROTO_MUTATOR_TESTING=OFF
|
|
|
|
-DLIB_PROTO_MUTATOR_MSVC_STATIC_RUNTIME=${STATIC_RUNTIME}
|
|
|
|
-DPKG_CONFIG_PATH=lib/pkgconfig
|
|
|
|
)
|
|
|
|
|
2023-03-08 06:14:52 +08:00
|
|
|
vcpkg_cmake_install()
|
2020-11-18 06:37:14 +08:00
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
vcpkg_fixup_pkgconfig()
|
2023-03-08 06:14:52 +08:00
|
|
|
vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/${PORT})
|
2020-11-18 06:37:14 +08:00
|
|
|
|
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
2023-03-08 06:14:52 +08:00
|
|
|
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|