diff options
| author | Park DongHa <luncliff@gmail.com> | 2021-02-20 06:02:46 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-19 13:02:46 -0800 |
| commit | eb1ba2a1130bfc782402c57a0a5a4e5d33321d9b (patch) | |
| tree | c7fa3c43ac346625cb5c0dd690756f6f521ea950 | |
| parent | 82dac2695073b6113c566226329d63f2fbc2ec78 (diff) | |
| download | vcpkg-eb1ba2a1130bfc782402c57a0a5a4e5d33321d9b.tar.gz vcpkg-eb1ba2a1130bfc782402c57a0a5a4e5d33321d9b.zip | |
[continuable] add a new port (#16261)
* [continuable] add a new port
* todo: create a patch for `find_package(function2)`
* [continuable] add patch to edit cmakelists
* [continuable] add port SHA
* [continuable] minimize patch
* update port SHA
| -rw-r--r-- | ports/continuable/fix-cmakelists.patch | 55 | ||||
| -rw-r--r-- | ports/continuable/portfile.cmake | 30 | ||||
| -rw-r--r-- | ports/continuable/vcpkg.json | 9 | ||||
| -rw-r--r-- | versions/baseline.json | 4 | ||||
| -rw-r--r-- | versions/c-/continuable.json | 9 |
5 files changed, 107 insertions, 0 deletions
diff --git a/ports/continuable/fix-cmakelists.patch b/ports/continuable/fix-cmakelists.patch new file mode 100644 index 000000000..a2d73ad5b --- /dev/null +++ b/ports/continuable/fix-cmakelists.patch @@ -0,0 +1,55 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -23,13 +23,6 @@ cmake_minimum_required(VERSION 3.11) + + project(continuable VERSION 4.0.0 LANGUAGES C CXX) + +-if (CTI_CONTINUABLE_IS_FIND_INCLUDED) +- set(CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT OFF) +-else() +- string(COMPARE EQUAL ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_SOURCE_DIR} +- CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT) +-endif() +- + option(CTI_CONTINUABLE_WITH_INSTALL + "Add the continuable install targets" + ${CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT}) +@@ -80,7 +73,7 @@ if(NOT TARGET Threads::Threads) + find_package(Threads REQUIRED) + endif() + +-if (CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT) ++if (FALSE) + include(cmake/CMakeLists.txt) + add_subdirectory(dep) + else() +@@ -90,7 +83,7 @@ else() + endif() + + # continuable-base +-if (CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT) ++if (TRUE) + add_library(continuable-base INTERFACE) + else() + add_library(continuable-base INTERFACE IMPORTED GLOBAL) +@@ -146,7 +139,7 @@ if (CTI_CONTINUABLE_WITH_UNHANDLED_EXCEPTIONS) + CONTINUABLE_WITH_UNHANDLED_EXCEPTIONS) + endif() + +-if (CTI_CONTINUABLE_IS_TOP_LEVEL_PROJECT) ++if (TRUE) + add_library(continuable INTERFACE) + else() + add_library(continuable INTERFACE IMPORTED GLOBAL) +@@ -168,8 +161,8 @@ if (CTI_CONTINUABLE_WITH_INSTALL) + # Headers and license files + install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/continuable" + DESTINATION "include") +- install(FILES "LICENSE.txt" DESTINATION .) +- install(FILES "Readme.md" DESTINATION .) ++ install(FILES "LICENSE.txt" DESTINATION share/${PROJECT_NAME} RENAME copyright) ++ install(FILES "Readme.md" DESTINATION share/${PROJECT_NAME}) + + # Config.cmake + write_basic_package_version_file( diff --git a/ports/continuable/portfile.cmake b/ports/continuable/portfile.cmake new file mode 100644 index 000000000..e4dd72c83 --- /dev/null +++ b/ports/continuable/portfile.cmake @@ -0,0 +1,30 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO Naios/continuable + REF 4.1.0 + SHA512 b80b1c13b068382553b727fd3b346323e2051b1c92237efa151ba8ec92b6d722ca993ae4bbf0e6e308a92834ae92011a179e74fcf713a09beaa48676f7d08340 + HEAD_REF master + PATCHES + fix-cmakelists.patch +) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS + -DCTI_CONTINUABLE_WITH_INSTALL=ON + -DCTI_CONTINUABLE_WITH_TESTS=OFF + -DCTI_CONTINUABLE_WITH_EXAMPLES=OFF + -DCTI_CONTINUABLE_WITH_BENCHMARKS=OFF + -DCTI_CONTINUABLE_WITH_NO_EXCEPTIONS=OFF + -DCTI_CONTINUABLE_WITH_UNHANDLED_EXCEPTIONS=ON + -DCTI_CONTINUABLE_WITH_EXPERIMENTAL_COROUTINE=ON + -DCTI_CONTINUABLE_WITH_CPP_LATEST=ON # requires cxx_std_17 +) +vcpkg_install_cmake() +vcpkg_copy_pdbs() +vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/${PORT}) + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib + ${CURRENT_PACKAGES_DIR}/debug +) diff --git a/ports/continuable/vcpkg.json b/ports/continuable/vcpkg.json new file mode 100644 index 000000000..d62451c96 --- /dev/null +++ b/ports/continuable/vcpkg.json @@ -0,0 +1,9 @@ +{ + "name": "continuable", + "version-string": "4.1.0", + "description": "C++14 asynchronous allocation aware futures (supporting then, exception handling, coroutines and connections)", + "homepage": "https://naios.github.io/continuable/", + "dependencies": [ + "function2" + ] +} diff --git a/versions/baseline.json b/versions/baseline.json index 42beefc0d..91e71465b 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1324,6 +1324,10 @@ "baseline": "2020-08-09", "port-version": 0 }, + "continuable": { + "baseline": "4.1.0", + "port-version": 0 + }, "coolprop": { "baseline": "6.4.1", "port-version": 0 diff --git a/versions/c-/continuable.json b/versions/c-/continuable.json new file mode 100644 index 000000000..5fe257e77 --- /dev/null +++ b/versions/c-/continuable.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "d014250505dde9759c6e46aa6825115bfdd5a15c", + "version-string": "4.1.0", + "port-version": 0 + } + ] +} |
