mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-08 16:13:50 +02:00
25 lines
807 B
Diff
25 lines
807 B
Diff
--- media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c.orig 2018-12-07 03:57:04.000000000 +0100
|
|
+++ media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2019-01-06 19:39:01.798166351 +0100
|
|
@@ -11,7 +11,9 @@
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
#include <features.h>
|
|
-#if __GLIBC_PREREQ(2, 16)
|
|
+#if !__GLIBC__
|
|
+#include <sys/auxv.h>
|
|
+#elif __GLIBC_PREREQ(2, 16)
|
|
#include <sys/auxv.h>
|
|
#else
|
|
#include <fcntl.h>
|
|
@@ -29,7 +31,10 @@
|
|
int architecture = 0;
|
|
unsigned long hwcap = 0;
|
|
const char* platform = NULL;
|
|
-#if __GLIBC_PREREQ(2, 16)
|
|
+#if !__GLIBC__
|
|
+ hwcap = getauxval(AT_HWCAP);
|
|
+ platform = (const char*)getauxval(AT_PLATFORM);
|
|
+#elif __GLIBC_PREREQ(2, 16)
|
|
hwcap = getauxval(AT_HWCAP);
|
|
platform = (const char*)getauxval(AT_PLATFORM);
|
|
#else
|