diff --git a/ports/cpuid/fix-LNK2019.patch b/ports/cpuid/fix-LNK2019.patch new file mode 100644 index 0000000000..0c8bddebf1 --- /dev/null +++ b/ports/cpuid/fix-LNK2019.patch @@ -0,0 +1,13 @@ +diff --git a/libcpuid/CMakeLists.txt b/libcpuid/CMakeLists.txt +index 09189ef..fa3f6ff 100644 +--- a/libcpuid/CMakeLists.txt ++++ b/libcpuid/CMakeLists.txt +@@ -21,7 +21,7 @@ if(UNIX) + add_compile_definitions(_GNU_SOURCE) + endif(UNIX) + +-if("${MSVC_CXX_ARCHITECTURE_ID}" MATCHES "x64") ++if(MSVC AND CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|AMD64|x64") + list(APPEND cpuid_sources masm-x64.asm) + endif() + diff --git a/ports/cpuid/fix-MSVC-warning.patch b/ports/cpuid/fix-MSVC-warning.patch new file mode 100644 index 0000000000..d3e2fc01ce --- /dev/null +++ b/ports/cpuid/fix-MSVC-warning.patch @@ -0,0 +1,13 @@ +diff --git a/libcpuid/cpuid_main.c b/libcpuid/cpuid_main.c +index ed3db36..b082caa 100644 +--- a/libcpuid/cpuid_main.c ++++ b/libcpuid/cpuid_main.c +@@ -1452,7 +1452,7 @@ int cpuid_get_raw_data_core(struct cpu_raw_data_t* data, logical_cpu_t logical_c + } + # endif /* PLATFORM_AARCH64 */ + #else +-# warning This CPU architecture is not supported by libcpuid ++#pragma message("Warning: This CPU architecture is not supported by libcpuid") + UNUSED(data); + #endif + diff --git a/ports/cpuid/fix-build.patch b/ports/cpuid/fix-build.patch index 02ce135cc6..2edb36c639 100644 --- a/ports/cpuid/fix-build.patch +++ b/ports/cpuid/fix-build.patch @@ -1,11 +1,12 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt +index a8f9f25..21e2c37 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -38,7 +38,6 @@ endif(UNIX) +@@ -66,7 +66,6 @@ endif(UNIX) # Include subdirectories add_subdirectory(libcpuid) -add_subdirectory(cpuid_tool) - if(LIBCPUID_TESTS) - add_subdirectory(tests) - endif() + if(LIBCPUID_BUILD_DRIVERS) + add_subdirectory(drivers) + endif(LIBCPUID_BUILD_DRIVERS) diff --git a/ports/cpuid/portfile.cmake b/ports/cpuid/portfile.cmake index d2d966fd49..9344316e3c 100644 --- a/ports/cpuid/portfile.cmake +++ b/ports/cpuid/portfile.cmake @@ -2,10 +2,12 @@ vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO anrieff/libcpuid REF "v${VERSION}" - SHA512 855dab45ec12b817fb18948442cebc22abaf915a7230e3d1a3f0e2fc7d0e3fe4a39e7c5744be1f4c7e3cb7b082012e6b0b0677a967beba5d404c6c48467eedce + SHA512 26353763461cbbe664ddaa6933cbd9016e3b11d8a056bc8c2b92818dfe3a43fcda76a92270f716eeb00ae61b75288c7079add8d7ac2290a0a0d5c3bd7d898d44 HEAD_REF master PATCHES fix-build.patch + fix-LNK2019.patch + fix-MSVC-warning.patch ) vcpkg_cmake_configure( diff --git a/ports/cpuid/vcpkg.json b/ports/cpuid/vcpkg.json index b70b15acf3..08d8f4745b 100644 --- a/ports/cpuid/vcpkg.json +++ b/ports/cpuid/vcpkg.json @@ -1,10 +1,10 @@ { "name": "cpuid", - "version": "0.6.4", + "version": "0.7.0", "description": "Provides CPU identification for the x86 (and x86_64)", "homepage": "https://github.com/anrieff/libcpuid", "license": "MIT", - "supports": "(x86 | x64) & !uwp", + "supports": "!uwp & !(windows & arm)", "dependencies": [ { "name": "vcpkg-cmake", diff --git a/versions/baseline.json b/versions/baseline.json index d4bd087bf8..28ba21ab6d 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -2037,7 +2037,7 @@ "port-version": 0 }, "cpuid": { - "baseline": "0.6.4", + "baseline": "0.7.0", "port-version": 0 }, "cpuinfo": { diff --git a/versions/c-/cpuid.json b/versions/c-/cpuid.json index 6d9f94e25d..4b3fc0558a 100644 --- a/versions/c-/cpuid.json +++ b/versions/c-/cpuid.json @@ -1,5 +1,10 @@ { "versions": [ + { + "git-tree": "af4cf6558e28039e5074af69e24747dfe46bd43f", + "version": "0.7.0", + "port-version": 0 + }, { "git-tree": "fe355f57cd08fb6530cd893d7d3c130a15f2ce13", "version": "0.6.4",