aboutsummaryrefslogtreecommitdiff
path: root/ports
diff options
context:
space:
mode:
authormyd7349 <myd7349@gmail.com>2019-02-02 02:04:22 +0800
committerVictor Romero <romerosanchezv@gmail.com>2019-02-01 10:04:22 -0800
commit9fb3b9c8fa3f4a571e00331ab7efe4f2098d472c (patch)
tree65d3fc7a36fec88f786748a2b885d890668e0a75 /ports
parent92bd67970d33ecdc1767c1dd042d73b7d1d998b0 (diff)
downloadvcpkg-9fb3b9c8fa3f4a571e00331ab7efe4f2098d472c.tar.gz
vcpkg-9fb3b9c8fa3f4a571e00331ab7efe4f2098d472c.zip
[argh] Add new port (#5266)
Diffstat (limited to 'ports')
-rw-r--r--ports/argh/CONTROL3
-rw-r--r--ports/argh/portfile.cmake36
2 files changed, 39 insertions, 0 deletions
diff --git a/ports/argh/CONTROL b/ports/argh/CONTROL
new file mode 100644
index 000000000..36c062da4
--- /dev/null
+++ b/ports/argh/CONTROL
@@ -0,0 +1,3 @@
+Source: argh
+Version: 2018-12-18
+Description: Argh! A minimalist argument handler.
diff --git a/ports/argh/portfile.cmake b/ports/argh/portfile.cmake
new file mode 100644
index 000000000..5e8b8bccd
--- /dev/null
+++ b/ports/argh/portfile.cmake
@@ -0,0 +1,36 @@
+# header-only library
+
+include(vcpkg_common_functions)
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO adishavit/argh
+ REF a1edee559757e076e570b8f6c2f555d8d00b373c
+ SHA512 a100c7ff20ef9ed39d53efeac5507a6ed59fb99ccba36ac4b5f8f5aaac6782f8e951b2f26b9b50f6c6fdbc53b5bceaabbb9dd9b9539f968fc1037733342e17a6
+ HEAD_REF master
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+ OPTIONS
+ -DBUILD_TESTS=OFF
+ -DBUILD_EXAMPLES=OFF
+)
+
+vcpkg_install_cmake()
+
+if(EXISTS ${CURRENT_PACKAGES_DIR}/CMake)
+ vcpkg_fixup_cmake_targets(CONFIG_PATH CMake)
+elseif(EXISTS ${CURRENT_PACKAGES_DIR}/lib/cmake/${PORT})
+ vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake/${PORT})
+endif()
+
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug ${CURRENT_PACKAGES_DIR}/lib)
+file(REMOVE ${CURRENT_PACKAGES_DIR}/README.md)
+
+# Handle copyright
+configure_file(${SOURCE_PATH}/LICENSE ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright COPYONLY)
+
+# CMake integration test
+vcpkg_test_cmake(PACKAGE_NAME ${PORT})