[taocpp-json] Add new port (#6253)

* [taocpp-json] Add new port
This commit is contained in:
myd7349 2019-04-29 13:50:58 -05:00 committed by Phil Christensen
parent 5936262b24
commit 51dc766e79
2 changed files with 41 additions and 0 deletions

View File

@ -0,0 +1,3 @@
Source: taocpp-json
Version: 2019-04-29-1
Description: C++ header-only JSON library

View File

@ -0,0 +1,38 @@
# header-only library
include(vcpkg_common_functions)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO taocpp/json
REF 8520fca2a054be775e406eaec66f33f02a7076e3
SHA512 44bfd0252ed42d2619ca65e92d0f483895fd735b98a81e7f844526f78893a8624133ba356ad41f8c691571bf9f56823f62bfc0f294394e6e0f780b44a0b085fd
HEAD_REF master
)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
DISABLE_PARALLEL_CONFIGURE
PREFER_NINJA
OPTIONS
-DTAOCPP_JSON_BUILD_TESTS=OFF
-DTAOCPP_JSON_BUILD_EXAMPLES=OFF
)
vcpkg_install_cmake()
vcpkg_fixup_cmake_targets(CONFIG_PATH share/taocpp-json/cmake)
file(REMOVE_RECURSE
${CURRENT_PACKAGES_DIR}/debug
${CURRENT_PACKAGES_DIR}/share/doc
)
# Handle copyright
configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright COPYONLY)
file(COPY ${SOURCE_PATH}/LICENSE.double-conversion DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(COPY ${SOURCE_PATH}/LICENSE.itoa DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(COPY ${SOURCE_PATH}/LICENSE.ryu DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
# CMake integration test
vcpkg_test_cmake(PACKAGE_NAME ${PORT})