mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-01-02 22:35:31 +08:00
44 lines
1.4 KiB
CMake
44 lines
1.4 KiB
CMake
include(vcpkg_common_functions)
|
|
|
|
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
|
|
|
if("public-preview" IN_LIST FEATURES)
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO Azure/azure-umqtt-c
|
|
REF fd5796c7d7d3add8a43b4d5ddcf4b1fba32d37cf
|
|
SHA512 14fd4077539fcec177cf8b10fc42e4fb93748ab1939cfc742e8b6ec15512afe3a7eadcf5f219ff87c4118ef95f6aa0da2efbd56b7adf33383456d4a498ad4368
|
|
HEAD_REF master
|
|
)
|
|
else()
|
|
vcpkg_from_github(
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
|
REPO Azure/azure-umqtt-c
|
|
REF fd5796c7d7d3add8a43b4d5ddcf4b1fba32d37cf
|
|
SHA512 14fd4077539fcec177cf8b10fc42e4fb93748ab1939cfc742e8b6ec15512afe3a7eadcf5f219ff87c4118ef95f6aa0da2efbd56b7adf33383456d4a498ad4368
|
|
HEAD_REF master
|
|
)
|
|
endif()
|
|
|
|
file(COPY ${CURRENT_INSTALLED_DIR}/share/azure-c-shared-utility/azure_iot_build_rules.cmake DESTINATION ${SOURCE_PATH}/deps/c-utility/configs/)
|
|
|
|
vcpkg_configure_cmake(
|
|
SOURCE_PATH ${SOURCE_PATH}
|
|
PREFER_NINJA
|
|
OPTIONS
|
|
-Dskip_samples=ON
|
|
-Duse_installed_dependencies=ON
|
|
-Dbuild_as_dynamic=OFF
|
|
)
|
|
|
|
vcpkg_install_cmake()
|
|
|
|
vcpkg_fixup_cmake_targets(CONFIG_PATH cmake TARGET_PATH share/umqtt)
|
|
|
|
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/share)
|
|
|
|
configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/azure-umqtt-c/copyright COPYONLY)
|
|
|
|
vcpkg_copy_pdbs()
|
|
|