aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/air-ctl
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/air-ctl
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/air-ctl')
-rw-r--r--vcpkg/ports/air-ctl/fix-resize-error.patch12
-rw-r--r--vcpkg/ports/air-ctl/portfile.cmake20
-rw-r--r--vcpkg/ports/air-ctl/vcpkg.json18
3 files changed, 50 insertions, 0 deletions
diff --git a/vcpkg/ports/air-ctl/fix-resize-error.patch b/vcpkg/ports/air-ctl/fix-resize-error.patch
new file mode 100644
index 0000000..34eabed
--- /dev/null
+++ b/vcpkg/ports/air-ctl/fix-resize-error.patch
@@ -0,0 +1,12 @@
+diff --git a/src/container/hash_map.c b/src/container/hash_map.c
+index 3f9de33..b1dd419 100644
+--- a/src/container/hash_map.c
++++ b/src/container/hash_map.c
+@@ -104,6 +104,7 @@ int CTL_hash_map_insert(CTL_hash_map *handle, const void *key, const void *eleme
+ if (handle->size > (handle->B_size - 1) * LOAD_FACTOR)
+ {
+ resize(handle);
++ index = __index(hash, handle->B_size);
+ }
+
+ __CTL_hash_map_node *new_node = (__CTL_hash_map_node *)CTL_malloc(sizeof(__CTL_hash_map_node));
diff --git a/vcpkg/ports/air-ctl/portfile.cmake b/vcpkg/ports/air-ctl/portfile.cmake
new file mode 100644
index 0000000..9652178
--- /dev/null
+++ b/vcpkg/ports/air-ctl/portfile.cmake
@@ -0,0 +1,20 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO inie0722/air-ctl
+ REF "v${VERSION}"
+ SHA512 88a20b0d833770820a8ef56725441cd4258b222ed12bb731a695c17a29c76709ed185f3a8e038d7f7437295847ff9ba77a65c5165ad7d70645c044a24365bfe9
+ HEAD_REF master
+ PATCHES
+ fix-resize-error.patch
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS "-DCTL_CACHE_LINE_SIZE=0"
+)
+
+vcpkg_cmake_install()
+vcpkg_cmake_config_fixup()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
diff --git a/vcpkg/ports/air-ctl/vcpkg.json b/vcpkg/ports/air-ctl/vcpkg.json
new file mode 100644
index 0000000..c52c2ad
--- /dev/null
+++ b/vcpkg/ports/air-ctl/vcpkg.json
@@ -0,0 +1,18 @@
+{
+ "name": "air-ctl",
+ "version": "1.1.2",
+ "port-version": 3,
+ "description": "C template container library",
+ "homepage": "https://github.com/inie0722/air-ctl",
+ "license": "BSL-1.0",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}