[stc] add new port (#46246)

This commit is contained in:
toge 2025-07-02 05:52:30 +09:00 committed by GitHub
parent d712dcd4e6
commit f0fb3ddba5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 70 additions and 0 deletions

View File

@ -0,0 +1,18 @@
diff --git a/meson.build b/meson.build
index 9633c63..12a803f 100644
--- a/meson.build
+++ b/meson.build
@@ -66,6 +66,13 @@ else
)
endif
+import('pkgconfig').generate(
+ stc_lib,
+ name: 'stc',
+ description: 'A modern, user friendly, generic, type-safe and fast C99 container library.',
+ url: 'https://github.com/stclib/STC',
+)
+
install_headers(
'include/stc/algorithm.h',
'include/stc/arc.h',

26
ports/stc/portfile.cmake Normal file
View File

@ -0,0 +1,26 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO stclib/STC
REF "v${VERSION}"
SHA512 99ac97d4849e548c54d564e822cec36be6436b976546af1e8f12757764831c14229f958e7064ab8802e74131831a0016cc28649df24088c415ab4cdc65dad076
HEAD_REF master
PATCHES
# TODO: remove this patch when new version is released
add-pkg-conf.patch
)
vcpkg_configure_meson(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
${BUILD_OPTIONS}
-Dcheckscoped=disabled
-Dtests=disabled
-Dexamples=disabled
)
vcpkg_install_meson()
vcpkg_fixup_pkgconfig()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/share/doc")
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")

13
ports/stc/vcpkg.json Normal file
View File

@ -0,0 +1,13 @@
{
"name": "stc",
"version": "5.0",
"description": "A modern, user friendly, generic, type-safe and fast C99 container library.",
"homepage": "https://github.com/stclib/STC",
"license": "MIT",
"dependencies": [
{
"name": "vcpkg-tool-meson",
"host": true
}
]
}

View File

@ -9108,6 +9108,10 @@
"baseline": "2024-07-29",
"port-version": 1
},
"stc": {
"baseline": "5.0",
"port-version": 0
},
"stdexec": {
"baseline": "2024-06-16",
"port-version": 2

9
versions/s-/stc.json Normal file
View File

@ -0,0 +1,9 @@
{
"versions": [
{
"git-tree": "0cb2c396876c756ee480e7d8ec09d007b309a08a",
"version": "5.0",
"port-version": 0
}
]
}