diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/nonius | |
Diffstat (limited to 'vcpkg/ports/nonius')
| -rw-r--r-- | vcpkg/ports/nonius/CMakeLists.txt | 30 | ||||
| -rw-r--r-- | vcpkg/ports/nonius/portfile.cmake | 25 | ||||
| -rw-r--r-- | vcpkg/ports/nonius/vcpkg.json | 19 |
3 files changed, 74 insertions, 0 deletions
diff --git a/vcpkg/ports/nonius/CMakeLists.txt b/vcpkg/ports/nonius/CMakeLists.txt new file mode 100644 index 0000000..38f213d --- /dev/null +++ b/vcpkg/ports/nonius/CMakeLists.txt @@ -0,0 +1,30 @@ +cmake_minimum_required(VERSION 3.9)
+cmake_policy(VERSION ${CMAKE_VERSION}) # use default policies of current cmake version
+
+project(nonius)
+
+add_library(nonius INTERFACE)
+target_include_directories(nonius INTERFACE
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
+ $<INSTALL_INTERFACE:include>
+)
+
+if(NOT DISABLE_INSTALL_HEADERS)
+ install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/include/
+ DESTINATION include
+ )
+endif()
+
+install(TARGETS nonius
+ EXPORT noniusExport
+ RUNTIME DESTINATION bin
+ LIBRARY DESTINATION lib
+ ARCHIVE DESTINATION lib
+)
+
+install(
+ EXPORT noniusExport
+ FILE noniusConfig.cmake
+ NAMESPACE Nonius::
+ DESTINATION share/nonius
+)
diff --git a/vcpkg/ports/nonius/portfile.cmake b/vcpkg/ports/nonius/portfile.cmake new file mode 100644 index 0000000..a2a1459 --- /dev/null +++ b/vcpkg/ports/nonius/portfile.cmake @@ -0,0 +1,25 @@ +# header-only library
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO libnonius/nonius
+ REF 6396b7ad6685843eea63754ffa567dd66353c1a8
+ SHA512 3b824a6011f1dbe116271dd76e8214ed98d73dfc215d7c9242bf298eb0e7ee3a3e3198f477b49fdbe098ac6e3e4edd8ca7bd2e03cc2036189bf3630ef3fcdca2
+ HEAD_REF master
+)
+
+file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
+
+vcpkg_cmake_configure(
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=ON
+)
+
+vcpkg_cmake_install()
+
+vcpkg_cmake_config_fixup()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug")
+
+# Handle copyright
+configure_file("${SOURCE_PATH}/COPYING.txt" "${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright" COPYONLY)
diff --git a/vcpkg/ports/nonius/vcpkg.json b/vcpkg/ports/nonius/vcpkg.json new file mode 100644 index 0000000..ae3b517 --- /dev/null +++ b/vcpkg/ports/nonius/vcpkg.json @@ -0,0 +1,19 @@ +{ + "name": "nonius", + "version-date": "2019-04-20", + "port-version": 4, + "description": "A C++ micro-benchmarking framework", + "dependencies": [ + "boost-algorithm", + "boost-lexical-cast", + "boost-math", + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ] +} |