aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/stc
diff options
context:
space:
mode:
authorEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
committerEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
commit54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch)
treed915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/stc
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/stc')
-rw-r--r--vcpkg/ports/stc/add-pkg-conf.patch18
-rw-r--r--vcpkg/ports/stc/portfile.cmake26
-rw-r--r--vcpkg/ports/stc/vcpkg.json13
3 files changed, 57 insertions, 0 deletions
diff --git a/vcpkg/ports/stc/add-pkg-conf.patch b/vcpkg/ports/stc/add-pkg-conf.patch
new file mode 100644
index 0000000..7a4caed
--- /dev/null
+++ b/vcpkg/ports/stc/add-pkg-conf.patch
@@ -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',
diff --git a/vcpkg/ports/stc/portfile.cmake b/vcpkg/ports/stc/portfile.cmake
new file mode 100644
index 0000000..0f77a18
--- /dev/null
+++ b/vcpkg/ports/stc/portfile.cmake
@@ -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")
diff --git a/vcpkg/ports/stc/vcpkg.json b/vcpkg/ports/stc/vcpkg.json
new file mode 100644
index 0000000..cf53547
--- /dev/null
+++ b/vcpkg/ports/stc/vcpkg.json
@@ -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
+ }
+ ]
+}