From 23f70099513254eb2559e887a2a9b5539a217e10 Mon Sep 17 00:00:00 2001 From: Alexander Karatarakis Date: Thu, 7 Feb 2019 10:43:50 -0800 Subject: [PATCH] [strict-variant] Add new header-only library (#5320) --- ports/strict-variant/CONTROL | 3 +++ ports/strict-variant/portfile.cmake | 17 +++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 ports/strict-variant/CONTROL create mode 100644 ports/strict-variant/portfile.cmake diff --git a/ports/strict-variant/CONTROL b/ports/strict-variant/CONTROL new file mode 100644 index 00000000000000..cc8af9ef08fd35 --- /dev/null +++ b/ports/strict-variant/CONTROL @@ -0,0 +1,3 @@ +Source: strict-variant +Version: v0.5 +Description: Tagged union implementation that will never throw an exception or make a dynamic allocation in the effort of supporting types that have throwing moves. diff --git a/ports/strict-variant/portfile.cmake b/ports/strict-variant/portfile.cmake new file mode 100644 index 00000000000000..ef0b34361da5b5 --- /dev/null +++ b/ports/strict-variant/portfile.cmake @@ -0,0 +1,17 @@ +# header-only +include(vcpkg_common_functions) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO cbeck88/strict-variant + REF 5ab330edcb5e3eea67fbedf8ac89648e5bc1e9a1 + SHA512 c80e5cd7cff389174447f5825af57ddea079956b2a4cb89337479e02289e89df19713ff031e914bdff2c823e8d2518311a1118701ae4e173f6557c770e553cd0 + HEAD_REF master +) + +# Copy header files +file(COPY ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR} FILES_MATCHING PATTERN "*.hpp") + +# Handle copyright +file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/strict-variant) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/strict-variant/LICENSE ${CURRENT_PACKAGES_DIR}/share/strict-variant/copyright)