vcpkg/ports/msgpack-c/portfile.cmake

29 lines
900 B
CMake
Raw Normal View History

if (EXISTS ${CURRENT_INSTALLED_DIR}/include/msgpack/pack.h)
message(FATAL_ERROR "Cannot install ${PORT} when rest-rpc is already installed, please remove rest-rpc using \"./vcpkg remove rest-rpc:${TARGET_TRIPLET}\"")
endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO msgpack/msgpack-c
REF c-6.0.0
SHA512 ba7d1b649dd1318f99d45ba5fd44346e53924ba7a121104a080c3865e8c01db3842efa1dc9e01478b962274675ba4632d9daaeb163821d46531b30d6abcda161
HEAD_REF c_master
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DMSGPACK_BUILD_EXAMPLES=OFF
-DMSGPACK_BUILD_TESTS=OFF
)
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_cmake_config_fixup(PACKAGE_NAME msgpack-c CONFIG_PATH lib/cmake/msgpack-c)
vcpkg_fixup_pkgconfig()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")