vcpkg/ports/azure-uhttp-c/portfile.cmake

34 lines
1.0 KiB
CMake
Raw Normal View History

include(vcpkg_common_functions)
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO Azure/azure-uhttp-c
REF 8ec55bb8596dae1154ae897b5064b8eba34c136c
SHA512 73b861409dede5c1936711ec04e76e8467dadc08acda6ac1b832046a4f9b2f6d35403c01acb818b5655c2c43f700d9f83edf11b8b00f7a565f260700a12c9f7c
HEAD_REF master
)
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
-DCMAKE_INSTALL_INCLUDEDIR=include
)
vcpkg_install_cmake()
vcpkg_fixup_cmake_targets(CONFIG_PATH cmake TARGET_PATH share/uhttp)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include ${CURRENT_PACKAGES_DIR}/debug/share)
configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/azure-uhttp-c/copyright COPYONLY)
vcpkg_copy_pdbs()