aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/argparse
diff options
context:
space:
mode:
Diffstat (limited to 'vcpkg/ports/argparse')
-rw-r--r--vcpkg/ports/argparse/portfile.cmake24
-rw-r--r--vcpkg/ports/argparse/vcpkg.json17
2 files changed, 41 insertions, 0 deletions
diff --git a/vcpkg/ports/argparse/portfile.cmake b/vcpkg/ports/argparse/portfile.cmake
new file mode 100644
index 0000000..693567c
--- /dev/null
+++ b/vcpkg/ports/argparse/portfile.cmake
@@ -0,0 +1,24 @@
+# header-only library
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO p-ranav/argparse
+ REF "v${VERSION}"
+ SHA512 83bebae6fd022c729bc589942a2aba7d601948a93eff3c170352885ab95a30fc7d0ff15a2f42fc935ee6c2db18f4a70ecd855a45af5f37383f77745271f01d78
+ HEAD_REF master
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DARGPARSE_BUILD_TESTS=OFF
+)
+
+vcpkg_cmake_install()
+
+vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/${PORT})
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug" "${CURRENT_PACKAGES_DIR}/lib")
+
+# Handle copyright
+configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright COPYONLY)
diff --git a/vcpkg/ports/argparse/vcpkg.json b/vcpkg/ports/argparse/vcpkg.json
new file mode 100644
index 0000000..120857e
--- /dev/null
+++ b/vcpkg/ports/argparse/vcpkg.json
@@ -0,0 +1,17 @@
+{
+ "name": "argparse",
+ "version": "3.2",
+ "description": "Argument parser for modern C++",
+ "homepage": "https://github.com/p-ranav/argparse",
+ "license": "MIT",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}