pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/audio/cmus cmus: Add alsa support.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/a60d3f2b4f3d
branches:  trunk
changeset: 397692:a60d3f2b4f3d
user:      nia <nia%pkgsrc.org@localhost>
date:      Tue Jul 02 06:23:50 2019 +0000

description:
cmus: Add alsa support.

diffstat:

 audio/cmus/Makefile                |   3 +--
 audio/cmus/PLIST                   |   3 ++-
 audio/cmus/distinfo                |   3 ++-
 audio/cmus/options.mk              |  19 +++++++++++--------
 audio/cmus/patches/patch-op_alsa.c |  17 +++++++++++++++++
 5 files changed, 33 insertions(+), 12 deletions(-)

diffs (107 lines):

diff -r e6766902ed10 -r a60d3f2b4f3d audio/cmus/Makefile
--- a/audio/cmus/Makefile       Tue Jul 02 06:15:29 2019 +0000
+++ b/audio/cmus/Makefile       Tue Jul 02 06:23:50 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.78 2019/07/02 06:15:29 nia Exp $
+# $NetBSD: Makefile,v 1.79 2019/07/02 06:23:50 nia Exp $
 
 DISTNAME=              cmus-2.8.0
 CATEGORIES=            audio
@@ -20,7 +20,6 @@
 GCC_REQD+=             4.9
 
 CONFIGURE_ARGS+=       prefix=${PREFIX}
-CONFIGURE_ARGS+=       CONFIG_ALSA=n
 # not in pkgsrc yet
 CONFIGURE_ARGS+=       CONFIG_ROAR=n
 # requires systemd
diff -r e6766902ed10 -r a60d3f2b4f3d audio/cmus/PLIST
--- a/audio/cmus/PLIST  Tue Jul 02 06:15:29 2019 +0000
+++ b/audio/cmus/PLIST  Tue Jul 02 06:23:50 2019 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.17 2019/05/09 13:22:58 jperkin Exp $
+@comment $NetBSD: PLIST,v 1.18 2019/07/02 06:23:50 nia Exp $
 bin/cmus
 bin/cmus-remote
 ${PLIST.faad}lib/cmus/ip/aac.so
@@ -14,6 +14,7 @@
 ${PLIST.vorbis}lib/cmus/ip/vorbis.so
 lib/cmus/ip/wav.so
 ${PLIST.wavpack}lib/cmus/ip/wavpack.so
+${PLIST.alsa}lib/cmus/op/alsa.so
 ${PLIST.libao}lib/cmus/op/ao.so
 ${PLIST.coreaudio}lib/cmus/op/coreaudio.so
 ${PLIST.jack}lib/cmus/op/jack.so
diff -r e6766902ed10 -r a60d3f2b4f3d audio/cmus/distinfo
--- a/audio/cmus/distinfo       Tue Jul 02 06:15:29 2019 +0000
+++ b/audio/cmus/distinfo       Tue Jul 02 06:23:50 2019 +0000
@@ -1,8 +1,9 @@
-$NetBSD: distinfo,v 1.23 2019/02/11 10:07:37 nia Exp $
+$NetBSD: distinfo,v 1.24 2019/07/02 06:23:50 nia Exp $
 
 SHA1 (cmus-2.8.0.tar.gz) = f2ef867a481190f1f1b34dad450a12ae94201d44
 RMD160 (cmus-2.8.0.tar.gz) = 00cb515afa9848db7610771052409d0d3f9d29d7
 SHA512 (cmus-2.8.0.tar.gz) = cf359dfcefa833a5b10a2d16ac405672bea762b62b7177c115560127035682fba65c15b9a8710179a343d1f99212a0260b5c095542982202e2cd1bef5b0c17fc
 Size (cmus-2.8.0.tar.gz) = 317243 bytes
+SHA1 (patch-op_alsa.c) = 3a50d91fb0ec04dcb67c926fb3ed80abd4baacd3
 SHA1 (patch-op_mixer__sun.c) = 13cb31e8b4aeab487b10af2aceeff9e248eb4b58
 SHA1 (patch-op_sun.c) = d8ab18cf049b05cfa1228483456523e7682d4c55
diff -r e6766902ed10 -r a60d3f2b4f3d audio/cmus/options.mk
--- a/audio/cmus/options.mk     Tue Jul 02 06:15:29 2019 +0000
+++ b/audio/cmus/options.mk     Tue Jul 02 06:23:50 2019 +0000
@@ -1,11 +1,12 @@
-# $NetBSD: options.mk,v 1.20 2019/02/11 10:07:37 nia Exp $
+# $NetBSD: options.mk,v 1.21 2019/07/02 06:23:50 nia Exp $
 
 PKG_OPTIONS_VAR=               PKG_OPTIONS.cmus
-PKG_SUPPORTED_OPTIONS=         flac mad vorbis libao musepack faad wavpack \
-                               ffmpeg opus jack pulseaudio
+PKG_SUPPORTED_OPTIONS+=                alsa flac mad vorbis libao musepack faad
+PKG_SUPPORTED_OPTIONS+=                wavpack ffmpeg opus jack pulseaudio
 PKG_OPTIONS_OPTIONAL_GROUPS=   mod
 PKG_OPTIONS_GROUP.mod=         modplug mikmod
 PKG_SUGGESTED_OPTIONS=         faad flac libao mad modplug opus vorbis
+PKG_SUGGESTED_OPTIONS.Linux+=  alsa
 PKG_OPTIONS_LEGACY_OPTS+=      ao:libao
 PKG_OPTIONS_LEGACY_OPTS+=      mpcdec:musepack
 
@@ -29,11 +30,13 @@
 
 # ALSA support
 #
-# UNTESTED
-#.if !empty(PKG_OPTIONS:Malsa)
-#ONLY_FOR_PLATFORM=  Linux-*-* # Alsa is Linux only
-#CONFIGURE_ARGS+=      CONFIG_ALSA=y
-#.endif
+.if !empty(PKG_OPTIONS:Malsa)
+. include "../../audio/alsa-lib/buildlink3.mk"
+CONFIGURE_ARGS+=       CONFIG_ALSA=y
+PLIST.alsa=            yes
+.else
+CONFIGURE_ARGS+=       CONFIG_ALSA=n
+.endif
 
 # PULSE support
 #
diff -r e6766902ed10 -r a60d3f2b4f3d audio/cmus/patches/patch-op_alsa.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/audio/cmus/patches/patch-op_alsa.c        Tue Jul 02 06:23:50 2019 +0000
@@ -0,0 +1,17 @@
+$NetBSD: patch-op_alsa.c,v 1.1 2019/07/02 06:23:50 nia Exp $
+
+Support NetBSD.
+
+--- op/alsa.c.orig     2019-01-29 09:09:08.000000000 +0000
++++ op/alsa.c
+@@ -59,6 +59,10 @@
+ 
+ #include <alsa/asoundlib.h>
+ 
++#ifndef ESTRPIPE
++#define ESTRPIPE EPIPE
++#endif
++
+ static sample_format_t alsa_sf;
+ static snd_pcm_t *alsa_handle;
+ static snd_pcm_format_t alsa_fmt;



Home | Main Index | Thread Index | Old Index