devel/cpu_features: new port, cpu_features 0.8.0
This commit is contained in:
24
devel/cpu_features/Makefile
Normal file
24
devel/cpu_features/Makefile
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
COMMENT = cross platform C99 library to get cpu features at runtime.
|
||||||
|
|
||||||
|
GH_ACCOUNT = google
|
||||||
|
GH_PROJECT = cpu_features
|
||||||
|
GH_TAGNAME = v0.8.0
|
||||||
|
|
||||||
|
CATEGORIES = devel
|
||||||
|
|
||||||
|
SHARED_LIBS = cpu_features 0.0
|
||||||
|
|
||||||
|
MAINTAINER = Stefan Hagen <sh+ports@codevoid.de>
|
||||||
|
|
||||||
|
# LICENSE
|
||||||
|
PERMIT_PACKAGE = Yes
|
||||||
|
|
||||||
|
MODULES = devel/cmake
|
||||||
|
|
||||||
|
WANTLIB = c
|
||||||
|
|
||||||
|
CONFIGURE_ARGS = -DBUILD_TESTING=OFF \
|
||||||
|
-DCMAKE_BUILD_TYPE=Release \
|
||||||
|
-DBUILD_SHARED_LIBS=ON
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
||||||
2
devel/cpu_features/distinfo
Normal file
2
devel/cpu_features/distinfo
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
SHA256 (cpu_features-0.8.0.tar.gz) = cCFyny25eqNPIY0ScnMU8j6LEeqi1akH6EJry0HX6qw=
|
||||||
|
SIZE (cpu_features-0.8.0.tar.gz) = 102371
|
||||||
11
devel/cpu_features/patches/patch-CMakeLists_txt
Normal file
11
devel/cpu_features/patches/patch-CMakeLists_txt
Normal 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
|
||||||
@@ -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
|
||||||
2
devel/cpu_features/pkg/DESCR
Normal file
2
devel/cpu_features/pkg/DESCR
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
A cross-platform C library to retrieve CPU features (such as available
|
||||||
|
instructions) at runtime.
|
||||||
12
devel/cpu_features/pkg/PLIST
Normal file
12
devel/cpu_features/pkg/PLIST
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
@bin bin/list_cpu_features
|
||||||
|
include/cpu_features/
|
||||||
|
include/cpu_features/cpu_features_cache_info.h
|
||||||
|
include/cpu_features/cpu_features_macros.h
|
||||||
|
include/cpu_features/cpuinfo_x86.h
|
||||||
|
lib/cmake/
|
||||||
|
lib/cmake/CpuFeatures/
|
||||||
|
lib/cmake/CpuFeatures/CpuFeaturesConfig.cmake
|
||||||
|
lib/cmake/CpuFeatures/CpuFeaturesConfigVersion.cmake
|
||||||
|
lib/cmake/CpuFeatures/CpuFeaturesTargets-release.cmake
|
||||||
|
lib/cmake/CpuFeatures/CpuFeaturesTargets.cmake
|
||||||
|
@lib lib/libcpu_features.so.${LIBcpu_features_VERSION}
|
||||||
Reference in New Issue
Block a user