aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/libvault
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/libvault
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/libvault')
-rw-r--r--vcpkg/ports/libvault/0001-fix-dependencies.patch13
-rw-r--r--vcpkg/ports/libvault/portfile.cmake32
-rw-r--r--vcpkg/ports/libvault/usage4
-rw-r--r--vcpkg/ports/libvault/vcpkg.json19
4 files changed, 68 insertions, 0 deletions
diff --git a/vcpkg/ports/libvault/0001-fix-dependencies.patch b/vcpkg/ports/libvault/0001-fix-dependencies.patch
new file mode 100644
index 0000000..50ec48c
--- /dev/null
+++ b/vcpkg/ports/libvault/0001-fix-dependencies.patch
@@ -0,0 +1,13 @@
+diff --git a/VaultConfig.cmake.in b/VaultConfig.cmake.in
+index 67a40ab..82db52d 100644
+--- a/VaultConfig.cmake.in
++++ b/VaultConfig.cmake.in
+@@ -1,5 +1,8 @@
+ @PACKAGE_INIT@
+
++include(CMakeFindDependencyMacro)
++find_dependency(CURL CONFIG)
++
+ include("${CMAKE_CURRENT_LIST_DIR}/libvaultTargets.cmake")
+
+ check_required_components(vault)
diff --git a/vcpkg/ports/libvault/portfile.cmake b/vcpkg/ports/libvault/portfile.cmake
new file mode 100644
index 0000000..11c3db4
--- /dev/null
+++ b/vcpkg/ports/libvault/portfile.cmake
@@ -0,0 +1,32 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO abedra/libvault
+ REF "${VERSION}"
+ SHA512 dc3295acafd1f9038430d8df00e96feb2252db0350716bd8a32c33d06a462a7ceb2c920458ca23bd42f5c14384fa1078ab4f69ff0817aa96b4e16ce03ddeddc2
+ PATCHES
+ 0001-fix-dependencies.patch
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DENABLE_TEST=OFF
+ -DLINK_CURL=ON
+)
+
+vcpkg_cmake_install()
+
+vcpkg_cmake_config_fixup(PACKAGE_NAME libvault CONFIG_PATH lib/cmake/libvault)
+vcpkg_fixup_pkgconfig()
+
+vcpkg_copy_pdbs()
+
+
+file(INSTALL "${SOURCE_PATH}/LICENSE"
+ DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}"
+ RENAME copyright)
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include"
+ "${CURRENT_PACKAGES_DIR}/debug/share")
+
+# Install usage
+configure_file("${CMAKE_CURRENT_LIST_DIR}/usage" "${CURRENT_PACKAGES_DIR}/share/${PORT}/usage" @ONLY)
diff --git a/vcpkg/ports/libvault/usage b/vcpkg/ports/libvault/usage
new file mode 100644
index 0000000..766be39
--- /dev/null
+++ b/vcpkg/ports/libvault/usage
@@ -0,0 +1,4 @@
+libvault provides CMake targets:
+
+ find_package(libvault CONFIG REQUIRED)
+ target_link_libraries(main PRIVATE libvault::vault)
diff --git a/vcpkg/ports/libvault/vcpkg.json b/vcpkg/ports/libvault/vcpkg.json
new file mode 100644
index 0000000..e19234e
--- /dev/null
+++ b/vcpkg/ports/libvault/vcpkg.json
@@ -0,0 +1,19 @@
+{
+ "name": "libvault",
+ "version": "0.63.0",
+ "description": "A C++ library for Hashicorp Vault",
+ "homepage": "https://github.com/abedra/libvault",
+ "license": "MIT",
+ "supports": "!uwp",
+ "dependencies": [
+ "curl",
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}