aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjbeich <jbeich@FreeBSD.org>2019-08-11 13:05:45 +0800
committerjbeich <jbeich@FreeBSD.org>2019-08-11 13:05:45 +0800
commit4e6043c368c626f7a7ff6b93d49fbed12b9a3e8f (patch)
treeaebbfa6338ebbb1c6058b1bf144a3c7be8b71dad
parent075ea3f22987d3ef2c574d387fcb55d496ae3b04 (diff)
downloadfreebsd-ports-gnome-4e6043c368c626f7a7ff6b93d49fbed12b9a3e8f.tar.gz
freebsd-ports-gnome-4e6043c368c626f7a7ff6b93d49fbed12b9a3e8f.tar.zst
freebsd-ports-gnome-4e6043c368c626f7a7ff6b93d49fbed12b9a3e8f.zip
net/waypipe: update to 0.5.0
Changes: https://gitlab.freedesktop.org/mstoeckl/waypipe/compare/v0.4.0...v0.5.0 MFH: 2019Q3 (better OpenGL support on Intel)
-rw-r--r--net/waypipe/Makefile16
-rw-r--r--net/waypipe/distinfo6
-rw-r--r--net/waypipe/files/patch-neon-freebsd1155
3 files changed, 71 insertions, 6 deletions
diff --git a/net/waypipe/Makefile b/net/waypipe/Makefile
index ea6d54a2290d..f2af29eecf66 100644
--- a/net/waypipe/Makefile
+++ b/net/waypipe/Makefile
@@ -2,8 +2,7 @@
PORTNAME= waypipe
DISTVERSIONPREFIX= v
-DISTVERSION= 0.4.0
-PORTREVISION= 1
+DISTVERSION= 0.5.0
CATEGORIES= net
MAINTAINER= jbeich@FreeBSD.org
@@ -19,8 +18,19 @@ USES= compiler:c11 localbase:ldflags meson pkgconfig
USE_GITLAB= yes
GL_SITE= https://gitlab.freedesktop.org
GL_ACCOUNT= mstoeckl
-GL_COMMIT= 039bd9acb20fe423f6c3b068bb08c6e6935f0d2b
+GL_COMMIT= e66f42444d81633f5b413cfe158809efd9c437f0
PLIST_FILES= bin/${PORTNAME}
+# XXX armv6 needs https://github.com/mesonbuild/meson/commit/147d3f752c41
+CONFIGURE_ENV= UNAME_m=${ARCH}
+
+# XXX Drop after FreeBSD 12.0 EOL
+.if exists(/usr/lib/clang/6.0.0) || exists(/usr/lib/clang/6.0.1)
+.if ${CC} == cc && (${MACHINE_ARCH} == amd64 || ${MACHINE_ARCH} == i386)
+USES:= ${USES:Ncompiler*} # silence warning
+BUILD_DEPENDS+= clang${LLVM_DEFAULT}:devel/llvm${LLVM_DEFAULT}
+CC= clang${LLVM_DEFAULT}
+.endif
+.endif
OPTIONS_DEFINE= FFMPEG LZ4 MANPAGES OPENGL VAAPI ZSTD
OPTIONS_DEFAULT=FFMPEG LZ4 MANPAGES OPENGL VAAPI ZSTD
diff --git a/net/waypipe/distinfo b/net/waypipe/distinfo
index 6b9634ec8037..f69c8907b141 100644
--- a/net/waypipe/distinfo
+++ b/net/waypipe/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1564420188
-SHA256 (mstoeckl-waypipe-039bd9acb20fe423f6c3b068bb08c6e6935f0d2b_GL0.tar.gz) = 8ab2f3898ad50910576f3f63cc9ea4182a106aab83e191139c0d3f95325a6eb8
-SIZE (mstoeckl-waypipe-039bd9acb20fe423f6c3b068bb08c6e6935f0d2b_GL0.tar.gz) = 124271
+TIMESTAMP = 1565392944
+SHA256 (mstoeckl-waypipe-e66f42444d81633f5b413cfe158809efd9c437f0_GL0.tar.gz) = 4a78dd943b617e2d39a34f4908f7acd0d0d59e838a83f739effcbf4d452bcec0
+SIZE (mstoeckl-waypipe-e66f42444d81633f5b413cfe158809efd9c437f0_GL0.tar.gz) = 135515
diff --git a/net/waypipe/files/patch-neon-freebsd11 b/net/waypipe/files/patch-neon-freebsd11
new file mode 100644
index 000000000000..bcdbcb8bb45a
--- /dev/null
+++ b/net/waypipe/files/patch-neon-freebsd11
@@ -0,0 +1,55 @@
+- Implement NEON runtime detection on FreeBSD 11.* armv6
+
+--- src/kernel.c.orig 2019-08-09 23:22:24 UTC
++++ src/kernel.c
+@@ -36,8 +36,36 @@
+ #include <asm/hwcap.h>
+ #include <sys/auxv.h>
+ #elif defined(__FreeBSD__) && defined(__arm__)
++#if __FreeBSD__ >= 12
+ #include <sys/auxv.h>
++#else
++#include <sys/param.h>
++#include <sys/sysctl.h>
++#include <elf.h>
++#include <errno.h>
++#include <unistd.h>
++
++static unsigned long getauxval(unsigned long type) {
++ Elf_Auxinfo auxv[AT_COUNT];
++ size_t len = sizeof(auxv);
++ int mib[] = {
++ CTL_KERN,
++ KERN_PROC,
++ KERN_PROC_AUXV,
++ getpid(),
++ };
++
++ if (sysctl(mib, nitems(mib), auxv, &len, NULL, 0) != -1) {
++ for (size_t i = 0; i < nitems(auxv); i++)
++ if ((unsigned long)auxv[i].a_type == type)
++ return auxv[i].a_un.a_val;
++
++ errno = ENOENT;
++ }
++ return 0;
++}
+ #endif
++#endif
+
+ size_t run_interval_diff_C(const int diff_window_size,
+ const void *__restrict__ imod, void *__restrict__ ibase,
+@@ -127,9 +155,13 @@ static bool neon_available(void)
+ #if defined(__linux__) && defined(__arm__)
+ return (getauxval(AT_HWCAP) & HWCAP_NEON) != 0;
+ #elif defined(__FreeBSD__) && defined(__arm__)
++#if __FreeBSD__ < 12
++ return (getauxval(AT_HWCAP) & HWCAP_NEON) != 0;
++#else
+ unsigned long hwcap = 0;
+ elf_aux_info(AT_HWCAP, &hwcap, sizeof(hwcap));
+ return (hwcap & HWCAP_NEON) != 0;
++#endif
+ #endif
+ return true;
+ }