Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 1 Jun 2024 22:35:59 GMT
From:      Jan Beich <jbeich@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 334143acb01f - main - multimedia/av1an: unbreak on arch(7) with unsigned char
Message-ID:  <202406012235.451MZxpc004424@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by jbeich:

URL: https://cgit.FreeBSD.org/ports/commit/?id=334143acb01f04aed48d296ba57f6c3dbfb5e0c0

commit 334143acb01f04aed48d296ba57f6c3dbfb5e0c0
Author:     Jan Beich <jbeich@FreeBSD.org>
AuthorDate: 2024-06-01 22:33:19 +0000
Commit:     Jan Beich <jbeich@FreeBSD.org>
CommitDate: 2024-06-01 22:35:08 +0000

    multimedia/av1an: unbreak on arch(7) with unsigned char
---
 multimedia/av1an/Makefile                          |  3 --
 multimedia/av1an/files/patch-ffmpeg7-unsigned-char | 55 ++++++++++++++++++++++
 2 files changed, 55 insertions(+), 3 deletions(-)

diff --git a/multimedia/av1an/Makefile b/multimedia/av1an/Makefile
index e8278788ba5b..63cadf3f69f6 100644
--- a/multimedia/av1an/Makefile
+++ b/multimedia/av1an/Makefile
@@ -10,9 +10,6 @@ WWW=		https://github.com/master-of-zen/Av1an
 LICENSE=	GPLv3
 LICENSE_FILE=	${WRKSRC}/LICENSE.md
 
-BROKEN_aarch64=	https://github.com/shssoichiro/ffmpeg-the-third/issues/63
-BROKEN_armv7=	https://github.com/shssoichiro/ffmpeg-the-third/issues/63
-
 BUILD_DEPENDS=	${BUILD_DEPENDS_${ARCH}}
 BUILD_DEPENDS_amd64=	nasm:devel/nasm
 LIB_DEPENDS=	libavformat.so:multimedia/ffmpeg \
diff --git a/multimedia/av1an/files/patch-ffmpeg7-unsigned-char b/multimedia/av1an/files/patch-ffmpeg7-unsigned-char
new file mode 100644
index 000000000000..707b9850b80e
--- /dev/null
+++ b/multimedia/av1an/files/patch-ffmpeg7-unsigned-char
@@ -0,0 +1,55 @@
+https://github.com/shssoichiro/ffmpeg-the-third/pull/64
+
+--- cargo-crates/ffmpeg-sys-the-third-2.0.0+ffmpeg-7.0/src/avutil/channel_layout.rs.orig	2006-07-24 01:21:28 UTC
++++ cargo-crates/ffmpeg-sys-the-third-2.0.0+ffmpeg-7.0/src/avutil/channel_layout.rs
+@@ -311,6 +311,7 @@ mod test {
+ #[cfg(test)]
+ mod test {
+     use super::*;
++    use libc::c_char;
+ 
+     // TODO: Missing: Ambisonic layout
+ 
+@@ -330,15 +331,15 @@ mod test {
+     };
+ 
+     // TODO: Replace with cstr literals when MSRV is 1.77
+-    const fn c_string<const N: usize, const K: usize>(byte_str: &[u8; N]) -> [i8; K] {
++    const fn c_string<const N: usize, const K: usize>(byte_str: &[u8; N]) -> [c_char; K] {
+         // Need at least one NUL byte at the end
+         assert!(N < K, "input string is too long (max 15 char)");
+ 
+-        let mut result = [0i8; K];
++        let mut result = [0; K];
+         let mut i = 0;
+ 
+         while i < N {
+-            result[i] = byte_str[i] as i8;
++            result[i] = byte_str[i] as c_char;
+             i += 1;
+         }
+ 
+--- cargo-crates/ffmpeg-the-third-2.0.1+ffmpeg-7.0/src/util/channel_layout/channel_custom.rs.orig	2006-07-24 01:21:28 UTC
++++ cargo-crates/ffmpeg-the-third-2.0.1+ffmpeg-7.0/src/util/channel_layout/channel_custom.rs
+@@ -1,3 +1,5 @@
++use libc::c_char;
++
+ use crate::ffi::{AVChannel, AVChannelCustom};
+ 
+ use super::Channel;
+@@ -30,12 +32,12 @@ impl ChannelCustom {
+     }
+ }
+ 
+-fn to_char_array(bytes: &[u8]) -> [i8; 16] {
+-    let mut result = [0i8; 16];
++fn to_char_array(bytes: &[u8]) -> [c_char; 16] {
++    let mut result = [0; 16];
+ 
+     // Only take the first 15 bytes, leaving at least one NUL byte
+     for (b, r) in bytes.iter().take(15).zip(&mut result) {
+-        *r = *b as i8;
++        *r = *b as c_char;
+     }
+ 
+     result



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202406012235.451MZxpc004424>