1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-29 05:38:00 +00:00

audio/opus: update to 1.5.2

No notable changes.
Our local ARM patches have been intregrated upstream.
This commit is contained in:
Christian Weisgerber 2024-04-16 17:21:04 +02:00
parent 8e5585719b
commit 316c9baba6
5 changed files with 5 additions and 73 deletions

View File

@ -1,5 +1,5 @@
PORTNAME= opus
DISTVERSION= 1.5.1
DISTVERSION= 1.5.2
CATEGORIES= audio
MASTER_SITES= https://downloads.xiph.org/releases/opus/

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1710082536
SHA256 (opus-1.5.1.tar.gz) = b84610959b8d417b611aa12a22565e0a3732097c6389d19098d844543e340f85
SIZE (opus-1.5.1.tar.gz) = 7834540
TIMESTAMP = 1713280233
SHA256 (opus-1.5.2.tar.gz) = 65c1d2f78b9f2fb20082c38cbe47c951ad5839345876e46941612ee87f9a7ce1
SIZE (opus-1.5.2.tar.gz) = 7839412

View File

@ -1,57 +0,0 @@
--- celt/arm/armcpu.c.orig 2024-03-01 07:55:09 UTC
+++ celt/arm/armcpu.c
@@ -191,6 +191,54 @@ opus_uint32 opus_cpu_capabilities(void)
return flags;
}
+#elif defined(__FreeBSD__)
+#include <sys/auxv.h>
+
+opus_uint32 opus_cpu_capabilities(void)
+{
+ long hwcap = 0;
+ opus_uint32 flags = 0;
+
+# if defined(OPUS_ARM_MAY_HAVE_MEDIA) \
+ || defined(OPUS_ARM_MAY_HAVE_NEON) || defined(OPUS_ARM_MAY_HAVE_NEON_INTR)
+ /* FreeBSD required armv6+, always supported media instructions */
+ flags |= OPUS_CPU_ARM_MEDIA_FLAG;
+# endif
+
+ elf_aux_info(AT_HWCAP, &hwcap, sizeof hwcap);
+
+# if defined(OPUS_ARM_MAY_HAVE_EDSP) || defined(OPUS_ARM_MAY_HAVE_MEDIA) \
+ || defined(OPUS_ARM_MAY_HAVE_NEON) || defined(OPUS_ARM_MAY_HAVE_NEON_INTR)
+# ifdef HWCAP_EDSP
+ if (hwcap & HWCAP_EDSP)
+ flags |= OPUS_CPU_ARM_EDSP_FLAG;
+# endif
+
+# if defined(OPUS_ARM_MAY_HAVE_NEON) || defined(OPUS_ARM_MAY_HAVE_NEON_INTR)
+# ifdef HWCAP_NEON
+ if (hwcap & HWCAP_NEON)
+ flags |= OPUS_CPU_ARM_NEON_FLAG;
+# elif defined(HWCAP_ASIMD)
+ if (hwcap & HWCAP_ASIMD)
+ flags |= OPUS_CPU_ARM_NEON_FLAG | OPUS_CPU_ARM_MEDIA_FLAG | OPUS_CPU_ARM_EDSP_FLAG;
+# endif
+# endif
+# if defined(OPUS_ARM_MAY_HAVE_DOTPROD) && defined(HWCAP_ASIMDDP)
+ if (hwcap & HWCAP_ASIMDDP)
+ flags |= OPUS_CPU_ARM_DOTPROD_FLAG;
+# endif
+# endif
+
+#if defined(OPUS_ARM_PRESUME_AARCH64_NEON_INTR)
+ flags |= OPUS_CPU_ARM_EDSP_FLAG | OPUS_CPU_ARM_MEDIA_FLAG | OPUS_CPU_ARM_NEON_FLAG;
+# if defined(OPUS_ARM_PRESUME_DOTPROD)
+ flags |= OPUS_CPU_ARM_DOTPROD_FLAG;
+# endif
+#endif
+
+ return (flags);
+}
+
#else
/* The feature registers which can tell us what the processor supports are
* accessible in priveleged modes only, so we can't have a general user-space

View File

@ -1,11 +0,0 @@
--- dnn/vec_neon.h.orig 2024-03-12 15:41:06 UTC
+++ dnn/vec_neon.h
@@ -34,7 +34,7 @@
#include <arm_neon.h>
#include "os_support.h"
-#if defined(__arm__) && !defined(__aarch64__)
+#if __ARM_ARCH < 8
/* Emulate vcvtnq_s32_f32() for ARMv7 Neon. */
static OPUS_INLINE int32x4_t vcvtnq_s32_f32(float32x4_t x) {
return vrshrq_n_s32(vcvtq_n_s32_f32(x, 8), 8);

View File

@ -7,6 +7,6 @@ include/opus/opus_types.h
lib/libopus.a
lib/libopus.so
lib/libopus.so.0
lib/libopus.so.0.10.0
lib/libopus.so.0.10.1
libdata/pkgconfig/opus.pc
share/aclocal/opus.m4