git: 7e9fc36ba374 - main - graphics/libskiasharp: fix build on armv7 and aarch64
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 21 Jan 2025 23:47:17 UTC
The branch main has been updated by fuz:
URL: https://cgit.FreeBSD.org/ports/commit/?id=7e9fc36ba37453a1ab8bbfa6f43bdd0507555696
commit 7e9fc36ba37453a1ab8bbfa6f43bdd0507555696
Author: Robert Clausecker <fuz@FreeBSD.org>
AuthorDate: 2025-01-20 04:51:50 +0000
Commit: Robert Clausecker <fuz@FreeBSD.org>
CommitDate: 2025-01-21 23:46:22 +0000
graphics/libskiasharp: fix build on armv7 and aarch64
Add getauxval() shim using elf_aux_info() for CPU feature detection.
Approved by: portmgr (build fix blanket)
MFH: 2025Q1
---
graphics/libskiasharp/Makefile | 2 +-
graphics/libskiasharp/files/patch-src_core_SkCpu.cpp | 20 ++++++++++++++++++++
2 files changed, 21 insertions(+), 1 deletion(-)
diff --git a/graphics/libskiasharp/Makefile b/graphics/libskiasharp/Makefile
index 669af43325f8..d8a43fb8c120 100644
--- a/graphics/libskiasharp/Makefile
+++ b/graphics/libskiasharp/Makefile
@@ -1,7 +1,7 @@
PORTNAME= libskiasharp
DISTVERSIONPREFIX= v
DISTVERSION= 2.88.3
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= graphics
MASTER_SITES= LOCAL/bapt:libjpeg_turbo
DISTFILES= libjpeg_turbo-${LIBJPEG_TURBO_REV}.tar.gz:libjpeg_turbo
diff --git a/graphics/libskiasharp/files/patch-src_core_SkCpu.cpp b/graphics/libskiasharp/files/patch-src_core_SkCpu.cpp
new file mode 100644
index 000000000000..44348f506302
--- /dev/null
+++ b/graphics/libskiasharp/files/patch-src_core_SkCpu.cpp
@@ -0,0 +1,20 @@
+--- src/core/SkCpu.cpp.orig 2025-01-20 04:43:13 UTC
++++ src/core/SkCpu.cpp
+@@ -10,6 +10,17 @@
+ #include "include/private/SkOnce.h"
+ #include "src/core/SkCpu.h"
+
++#ifdef __FreeBSD__
++#include <sys/auxv.h>
++static unsigned long getauxval(unsigned long aux) {
++ unsigned long val = 0;
++
++ elf_aux_info((int)aux, &val, sizeof aux);
++
++ return val;
++}
++#endif
++
+ #if defined(SK_CPU_X86)
+ #if defined(_MSC_VER)
+ #include <intrin.h>