diff options
| author | myd7349 <myd7349@gmail.com> | 2019-07-18 15:15:56 +0800 |
|---|---|---|
| committer | Phil Christensen <philc@microsoft.com> | 2019-07-18 00:15:56 -0700 |
| commit | 584da54a0f56943286efef6b25ccc8582e3fe8d4 (patch) | |
| tree | 571442cdffcf92f58ba42b642c038ec1689d3ffd | |
| parent | 54b39598e1880f0cab60a9fcc448745711d2d2e9 (diff) | |
| download | vcpkg-584da54a0f56943286efef6b25ccc8582e3fe8d4.tar.gz vcpkg-584da54a0f56943286efef6b25ccc8582e3fe8d4.zip | |
[nameof] Add new port (#7250)
| -rw-r--r-- | ports/nameof/CONTROL | 4 | ||||
| -rw-r--r-- | ports/nameof/portfile.cmake | 31 |
2 files changed, 35 insertions, 0 deletions
diff --git a/ports/nameof/CONTROL b/ports/nameof/CONTROL new file mode 100644 index 000000000..35df482a0 --- /dev/null +++ b/ports/nameof/CONTROL @@ -0,0 +1,4 @@ +Source: nameof
+Version: 2019-07-13
+Description: Nameof operator for modern C++
+Homepage: https://github.com/Neargye/nameof
diff --git a/ports/nameof/portfile.cmake b/ports/nameof/portfile.cmake new file mode 100644 index 000000000..21dcf1b97 --- /dev/null +++ b/ports/nameof/portfile.cmake @@ -0,0 +1,31 @@ +# header-only library
+
+include(vcpkg_common_functions)
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO Neargye/nameof
+ REF 9d335128265e443acf4e12ed40327e166cd8e3da
+ SHA512 3d4af0069fc3dbf9a4a79ae1bea282cafb69606936a66bf43b5a13ae2f0cbc88e98dbb02a12e9c211afd73d9807b36a6f09635a1922ce5faaeb2a148672a0b13
+ HEAD_REF master
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+ OPTIONS
+ -DNAMEOF_OPT_BUILD_EXAMPLES=OFF
+ -DNAMEOF_OPT_BUILD_TESTS=OFF
+)
+
+vcpkg_install_cmake()
+
+vcpkg_fixup_cmake_targets(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)
+
+# CMake integration test
+vcpkg_test_cmake(PACKAGE_NAME ${PORT})
|
