summaryrefslogtreecommitdiff
path: root/audio
diff options
context:
space:
mode:
authornia <nia@pkgsrc.org>2022-04-27 21:15:23 +0000
committernia <nia@pkgsrc.org>2022-04-27 21:15:23 +0000
commit699495a19553facf480ecdac1025e14c99d56d27 (patch)
tree0bcf85e3114428b4e80c450028cc8b1e28d5a45c /audio
parent4c04e4d15006514aa1f1739620da6ca725bf36d5 (diff)
downloadpkgsrc-699495a19553facf480ecdac1025e14c99d56d27.tar.gz
mpg123: Fix device opening on NetBSD on rpi. Normal applications setting
the audio output port in 2022 considered harmful.
Diffstat (limited to 'audio')
-rw-r--r--audio/mpg123/Makefile3
-rw-r--r--audio/mpg123/distinfo3
-rw-r--r--audio/mpg123/patches/patch-src_libout123_modules_sun.c28
3 files changed, 32 insertions, 2 deletions
diff --git a/audio/mpg123/Makefile b/audio/mpg123/Makefile
index 0dd9e317886..ea40d1de3b8 100644
--- a/audio/mpg123/Makefile
+++ b/audio/mpg123/Makefile
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.64 2021/06/05 17:30:01 thor Exp $
+# $NetBSD: Makefile,v 1.65 2022/04/27 21:15:23 nia Exp $
PKGNAME= ${DISTNAME:C/[^[:alnum:]]*//}
+PKGREVISION= 1
COMMENT= MPEG layer 1, 2, and 3 audio player
PKGCONFIG_OVERRIDE+= libmpg123.pc.in libout123.pc.in libsyn123.pc.in
diff --git a/audio/mpg123/distinfo b/audio/mpg123/distinfo
index 93a97257cb4..6d96a31a082 100644
--- a/audio/mpg123/distinfo
+++ b/audio/mpg123/distinfo
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.65 2021/12/17 17:11:31 thor Exp $
+$NetBSD: distinfo,v 1.66 2022/04/27 21:15:23 nia Exp $
BLAKE2s (mpg123-1.29.3.tar.bz2) = 90efccc30568f2e56cd027b52fa12b16e806216ba861a164f0a5664b67f3f8a8
SHA512 (mpg123-1.29.3.tar.bz2) = 0d8db63f9bae1507887bc5241a56abccfeb767b7ba8362eb0fce9de2f63369e57fdd6f25a953f8ef5f9ead4f400237db51914816e278566fdf8e6f205ebca5d6
Size (mpg123-1.29.3.tar.bz2) = 1069979 bytes
SHA1 (patch-ad) = f07b637c3fc1d3ea0426013fc25bca8e3aecba56
+SHA1 (patch-src_libout123_modules_sun.c) = aa11e1420fd07f2e1c4a0d911d1642f0fd50b916
diff --git a/audio/mpg123/patches/patch-src_libout123_modules_sun.c b/audio/mpg123/patches/patch-src_libout123_modules_sun.c
new file mode 100644
index 00000000000..a9fb3235242
--- /dev/null
+++ b/audio/mpg123/patches/patch-src_libout123_modules_sun.c
@@ -0,0 +1,28 @@
+$NetBSD: patch-src_libout123_modules_sun.c,v 1.1 2022/04/27 21:15:23 nia Exp $
+
+Disable legacy code for fiddling with mixer parameters like volume
+and output port. This is not really something we want done on
+modern Solaris on NetBSD where the device is abstracted, and
+setting the port can fail loudly on some hardware like
+Raspberry Pis.
+
+--- src/libout123/modules/sun.c.orig 2021-12-10 07:00:58.000000000 +0000
++++ src/libout123/modules/sun.c
+@@ -174,7 +174,8 @@ static int open_sun(out123_handle *ao)
+ #endif
+
+ if(reset_parameters_sun(ao) < 0) return -1;
+-
++
++#if 0
+ AUDIO_INITINFO(&ainfo);
+
+ if(ao->flags > 0)
+@@ -193,6 +194,7 @@ static int open_sun(out123_handle *ao)
+
+ if(ioctl(ao->fn, AUDIO_SETINFO, &ainfo) == -1)
+ return -1;
++#endif
+
+ return ao->fn;
+ }