2018-04-03 11:29:14 +08:00
|
|
|
if (VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
|
|
|
|
message(STATUS "Warning: Dynamic building not supported yet. Building static.")
|
|
|
|
set(VCPKG_LIBRARY_LINKAGE static)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
include(vcpkg_common_functions)
|
|
|
|
|
|
|
|
vcpkg_from_github(
|
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
|
|
REPO GoogleCloudPlatform/google-cloud-cpp
|
2018-11-15 07:20:54 +08:00
|
|
|
REF v0.3.0
|
|
|
|
SHA512 90f876ebf4bea40c5bc12d2bd20d27b48202f951d57a68b657c07b7d468b2ac5a00e39a3a6fca48f92030d89ba7d9706eb52b3c8e734b392aee63632af042b5d
|
2018-04-03 11:29:14 +08:00
|
|
|
HEAD_REF master
|
2018-11-15 07:20:54 +08:00
|
|
|
PATCHES include-protobuf.patch
|
2018-04-03 11:29:14 +08:00
|
|
|
)
|
|
|
|
|
2018-11-15 07:20:54 +08:00
|
|
|
set(GOOGLEAPIS_VERSION 6a3277c0656219174ff7c345f31fb20a90b30b97)
|
2018-04-03 11:29:14 +08:00
|
|
|
vcpkg_download_distfile(GOOGLEAPIS
|
2018-11-15 07:20:54 +08:00
|
|
|
URLS "https://github.com/google/googleapis/archive/${GOOGLEAPIS_VERSION}.zip"
|
2018-04-03 11:29:14 +08:00
|
|
|
FILENAME "googleapis-${GOOGLEAPIS_VERSION}.zip"
|
2018-11-15 07:20:54 +08:00
|
|
|
SHA512 809b7cf0429df9867c8ab558857785e9d7d70aea033c6d588b60d29d2754001e9aea5fcdd8cae22fad8145226375bedbd1516d86af7d1e9731fffea331995ad9
|
2018-04-03 11:29:14 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
file(REMOVE_RECURSE ${SOURCE_PATH}/third_party)
|
|
|
|
vcpkg_extract_source_archive(${GOOGLEAPIS} ${SOURCE_PATH}/third_party)
|
|
|
|
file(RENAME ${SOURCE_PATH}/third_party/googleapis-${GOOGLEAPIS_VERSION} ${SOURCE_PATH}/third_party/googleapis)
|
|
|
|
|
|
|
|
vcpkg_configure_cmake(
|
|
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
|
|
PREFER_NINJA
|
|
|
|
OPTIONS
|
2018-11-15 07:20:54 +08:00
|
|
|
-DGOOGLE_CLOUD_CPP_DEPENDENCY_PROVIDER=vcpkg
|
|
|
|
-DGOOGLE_CLOUD_CPP_ENABLE_MACOS_OPENSSL_CHECK=OFF
|
2018-04-03 11:29:14 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
vcpkg_install_cmake(ADD_BIN_TO_PATH)
|
|
|
|
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
|
2018-11-15 07:20:54 +08:00
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake TARGET_PATH share)
|
2018-04-03 11:29:14 +08:00
|
|
|
|
|
|
|
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/google-cloud-cpp RENAME copyright)
|
|
|
|
|
|
|
|
vcpkg_copy_pdbs()
|