aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/cargs
diff options
context:
space:
mode:
Diffstat (limited to 'vcpkg/ports/cargs')
-rw-r--r--vcpkg/ports/cargs/portfile.cmake22
-rw-r--r--vcpkg/ports/cargs/vcpkg.json16
2 files changed, 38 insertions, 0 deletions
diff --git a/vcpkg/ports/cargs/portfile.cmake b/vcpkg/ports/cargs/portfile.cmake
new file mode 100644
index 0000000..7b69414
--- /dev/null
+++ b/vcpkg/ports/cargs/portfile.cmake
@@ -0,0 +1,22 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO likle/cargs
+ REF "v${VERSION}"
+ SHA512 56877e330745369585b1b6ed274e8c898381439915048375a22a3fed077c1818b5d21356a33a77f516571d834a3fce7f78e509df63ce0f93b8276ac0a93df02a
+ HEAD_REF master
+)
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ -DENABLE_TESTS=OFF
+)
+
+vcpkg_cmake_install()
+vcpkg_copy_pdbs()
+
+vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/cargs)
+vcpkg_fixup_pkgconfig()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
+file(INSTALL "${SOURCE_PATH}/LICENSE.md" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
diff --git a/vcpkg/ports/cargs/vcpkg.json b/vcpkg/ports/cargs/vcpkg.json
new file mode 100644
index 0000000..54d51f1
--- /dev/null
+++ b/vcpkg/ports/cargs/vcpkg.json
@@ -0,0 +1,16 @@
+{
+ "name": "cargs",
+ "version": "1.2.0",
+ "description": "A lightweight cross-platform getopt alternative that works on Linux, Windows and macOS. Command line argument parser library for C/C++. Can be used to parse argv and argc parameters.",
+ "homepage": "https://likle.github.io/cargs/",
+ "dependencies": [
+ {
+ "name": "vcpkg-cmake",
+ "host": true
+ },
+ {
+ "name": "vcpkg-cmake-config",
+ "host": true
+ }
+ ]
+}