From e64dd3356f7fe38e1e547cd94cee92bae831d41f Mon Sep 17 00:00:00 2001 From: Park DongHa Date: Thu, 28 Dec 2023 17:30:51 +0900 Subject: [PATCH] [hwinfo] create a new port (#35465) * [hwinfo] create a new port * [hwinfo] update baseline * [hwinfo] can't use WbemIdl in UWP * [hwinfo] suppress NO_OCL unused * it's just not accessed in CMakeLists.txt * [hwinfo] fix NO_OCL expression --- ports/hwinfo/portfile.cmake | 21 +++++++++++++++++++++ ports/hwinfo/vcpkg.json | 14 ++++++++++++++ versions/baseline.json | 4 ++++ versions/h-/hwinfo.json | 9 +++++++++ 4 files changed, 48 insertions(+) create mode 100644 ports/hwinfo/portfile.cmake create mode 100644 ports/hwinfo/vcpkg.json create mode 100644 versions/h-/hwinfo.json diff --git a/ports/hwinfo/portfile.cmake b/ports/hwinfo/portfile.cmake new file mode 100644 index 00000000000000..bd8dad6c9c6e16 --- /dev/null +++ b/ports/hwinfo/portfile.cmake @@ -0,0 +1,21 @@ +vcpkg_check_linkage(ONLY_STATIC_LIBRARY) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO lfreist/hwinfo + REF 5cb31dbdb2c40413a837ce52ffadee23578c9069 + SHA512 7c431528d5bf2f91843a3f6f8de908f6bc5b1427f85961bb885ab95e7765a875cb0358638e0e1e1f9a9336476ba74dc22819c97189251391fd8459c334c1092a +) + +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" + OPTIONS + -DNO_OCL=TRUE # disable OpenCL usage + MAYBE_UNUSED_VARIABLES + NO_OCL +) +vcpkg_cmake_install() + +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") + +vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE") diff --git a/ports/hwinfo/vcpkg.json b/ports/hwinfo/vcpkg.json new file mode 100644 index 00000000000000..cb5ac1373cbcc9 --- /dev/null +++ b/ports/hwinfo/vcpkg.json @@ -0,0 +1,14 @@ +{ + "name": "hwinfo", + "version-date": "2023-12-02", + "description": "cross platform C++ library for hardware information (CPU, RAM, GPU, ...)", + "homepage": "https://github.com/lfreist/hwinfo", + "license": "MIT", + "supports": "(windows | linux) & !uwp", + "dependencies": [ + { + "name": "vcpkg-cmake", + "host": true + } + ] +} diff --git a/versions/baseline.json b/versions/baseline.json index 999305105c4809..8842d2a37c7cb6 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -3364,6 +3364,10 @@ "baseline": "1.7.2", "port-version": 0 }, + "hwinfo": { + "baseline": "2023-12-02", + "port-version": 0 + }, "hwloc": { "baseline": "2.9.3", "port-version": 0 diff --git a/versions/h-/hwinfo.json b/versions/h-/hwinfo.json new file mode 100644 index 00000000000000..9dca1884ff7e73 --- /dev/null +++ b/versions/h-/hwinfo.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "75e06682da06c2b28e10f57d72dc30618b833848", + "version-date": "2023-12-02", + "port-version": 0 + } + ] +}