diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/stlab | |
Diffstat (limited to 'vcpkg/ports/stlab')
| -rw-r--r-- | vcpkg/ports/stlab/cross-build.patch | 21 | ||||
| -rw-r--r-- | vcpkg/ports/stlab/devendoring.patch | 15 | ||||
| -rw-r--r-- | vcpkg/ports/stlab/portfile.cmake | 25 | ||||
| -rw-r--r-- | vcpkg/ports/stlab/vcpkg.json | 21 |
4 files changed, 82 insertions, 0 deletions
diff --git a/vcpkg/ports/stlab/cross-build.patch b/vcpkg/ports/stlab/cross-build.patch new file mode 100644 index 0000000..79a2fa4 --- /dev/null +++ b/vcpkg/ports/stlab/cross-build.patch @@ -0,0 +1,21 @@ +diff --git a/cmake/StlabUtil.cmake b/cmake/StlabUtil.cmake +index 3e36278..aeb284f 100644 +--- a/cmake/StlabUtil.cmake ++++ b/cmake/StlabUtil.cmake +@@ -2,14 +2,14 @@ + # functionality useful for stlab builds. + + include( CheckCXXSymbolExists ) +-include( CheckCXXSourceRuns ) ++include( CheckCXXSourceCompiles ) + + # Determine if the selected C++ compiler has functional coroutines. Set the + # specified 'result_var' to 'TRUE' if they are determined to be disfunctional + # and 'FALSE' otherwise. Note that this check consists of a smoke test and does + # not check all the ways this feature may be deficient. + function( stlab_check_disfunctional_coroutines result_var ) +- check_cxx_source_runs( " ++ check_cxx_source_compiles( " + #include <concepts> + #include <coroutine> + #include <exception> diff --git a/vcpkg/ports/stlab/devendoring.patch b/vcpkg/ports/stlab/devendoring.patch new file mode 100644 index 0000000..5ce75f4 --- /dev/null +++ b/vcpkg/ports/stlab/devendoring.patch @@ -0,0 +1,15 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 671f79d..8eabae4 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -15,8 +15,8 @@ include(cmake/CPM.cmake) + + + # Add stlab-copy-on-write as a dependency +-CPMAddPackage("gh:stlab/copy-on-write@1.0.3") +-target_link_libraries(stlab INTERFACE stlab::copy-on-write) ++find_package(stlab-copy-on-write CONFIG REQUIRED) ++target_link_libraries(stlab PUBLIC stlab::stlab-copy-on-write) + + ######################################################## + # clangd diff --git a/vcpkg/ports/stlab/portfile.cmake b/vcpkg/ports/stlab/portfile.cmake new file mode 100644 index 0000000..7eff3d9 --- /dev/null +++ b/vcpkg/ports/stlab/portfile.cmake @@ -0,0 +1,25 @@ +vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO stlab/libraries
+ REF "v${VERSION}"
+ SHA512 446ea1337f6700a11f83cc718e9d702a684437b369efa502f8f3bf9097d56a435af4c8bcc95e8684a5e39ef06bb8c624fb3cc9fa45799770b351075c8cc86077
+ HEAD_REF main
+ PATCHES
+ cross-build.patch
+ devendoring.patch
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DBUILD_TESTING=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_Qt6=ON
+)
+
+vcpkg_cmake_install()
+vcpkg_cmake_config_fixup(CONFIG_PATH share/cmake/stlab)
+vcpkg_copy_pdbs()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+
+file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
diff --git a/vcpkg/ports/stlab/vcpkg.json b/vcpkg/ports/stlab/vcpkg.json new file mode 100644 index 0000000..5563959 --- /dev/null +++ b/vcpkg/ports/stlab/vcpkg.json @@ -0,0 +1,21 @@ +{ + "name": "stlab", + "version": "2.0.2", + "description": [ + "stlab is the ongoing work of what was Adobe Software Technology Lab.", + "The Concurrency library provides futures and channels, high level constructs for implementing algorithms that eases the use of multiple CPU cores while minimizing contention. This library solves several problems of the C++11 and C++17 TS futures." + ], + "homepage": "https://github.com/stlab/libraries", + "license": "BSL-1.0", + "dependencies": [ + "stlab-copy-on-write", + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ] +} |