devel/cpu_features: new port, cpu_features 0.8.0

This commit is contained in:
c0dev0id
2026-07-08 11:07:09 +02:00
parent d059121223
commit bdaeed24db
6 changed files with 67 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
Compatibility with CMake < 3.5 was removed from CMake 4.
Index: CMakeLists.txt
--- CMakeLists.txt.orig
+++ CMakeLists.txt
@@ -1,4 +1,4 @@
-cmake_minimum_required(VERSION 3.0)
+cmake_minimum_required(VERSION 3.5)
# option() honors normal variables.
# see: https://cmake.org/cmake/help/git-stage/policy/CMP0077.html

View File

@@ -0,0 +1,16 @@
We're parsing dmesg, just like FreeBSD
Index: include/cpu_features_macros.h
--- include/cpu_features_macros.h.orig
+++ include/cpu_features_macros.h
@@ -91,6 +91,10 @@
#define CPU_FEATURES_OS_FREEBSD
#endif
+#if (defined(__openbsd__) || defined(__OpenBSD__))
+#define CPU_FEATURES_OS_FREEBSD // currently the same
+#endif
+
#if defined(__ANDROID__)
#define CPU_FEATURES_OS_ANDROID
#endif