Subject: pkg/36173: audio/musicpd doesn't use libao
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: None <Peter.Bex@xs4all.nl>
List: pkgsrc-bugs
Date: 04/19/2007 18:25:00
>Number:         36173
>Category:       pkg
>Synopsis:       audio/musicpd should use libao so you can use it to enable software mixing through libao-esound or libao-arts under NetBSD
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Apr 19 18:25:00 +0000 2007
>Originator:     Peter Bex
>Release:        NetBSD 4.0_BETA2
>Organization:
	
>Environment:
	
	
System: NetBSD byers.homeunix.org 4.0_BETA2 NetBSD 4.0_BETA2 (BYERS) #2: Mon Jan 15 21:41:06 CET 2007 sjamaan@byers.homeunix.org:/usr/src/sys/arch/macppc/compile/BYERS macppc
Architecture: powerpc
Machine: macppc
>Description:
	Previous versions of audio/musicpd in pkgsrc enabled libao on musicpd
	(or it was enabled by default in musicpd?) so it was possible to use
	something like audio/libao-esound or audio/libao-arts to get software
	mixing under NetBSD.  There's still no kernel mixing support, so it's
	very desirable.  This patch adds an option to options.mk
>How-To-Repeat:
	
>Fix:

Here's a patch that will do the trick:

Index: Makefile
===================================================================
RCS file: /cvsroot/pkgsrc/audio/musicpd/Makefile,v
retrieving revision 1.27
diff -u -r1.27 Makefile
--- Makefile	9 Jan 2007 23:19:26 -0000	1.27
+++ Makefile	19 Apr 2007 18:15:54 -0000
@@ -38,7 +38,6 @@
 	${INSTALL_DATA_DIR} ${EGDIR}
 	${INSTALL_DATA} ${WRKSRC}/mpd.conf ${EGDIR}
 
-.include "../../audio/libao/buildlink3.mk"
 .include "../../audio/libmad/buildlink3.mk"
 
 .include "../../mk/oss.buildlink3.mk"
Index: options.mk
===================================================================
RCS file: /cvsroot/pkgsrc/audio/musicpd/options.mk,v
retrieving revision 1.7
diff -u -r1.7 options.mk
--- options.mk	1 Feb 2007 14:52:43 -0000	1.7
+++ options.mk	19 Apr 2007 18:15:54 -0000
@@ -1,8 +1,8 @@
 # $NetBSD: options.mk,v 1.7 2007/02/01 14:52:43 cbiere Exp $
 
 PKG_OPTIONS_VAR=	PKG_OPTIONS.musicpd
-PKG_SUPPORTED_OPTIONS=	aac audiofile flac iconv id3 libmikmod musepack ogg
-PKG_SUGGESTED_OPTIONS=	aac audiofile flac iconv id3 libmikmod musepack ogg
+PKG_SUPPORTED_OPTIONS=	aac audiofile flac iconv id3 libmikmod musepack ogg libao
+PKG_SUGGESTED_OPTIONS=	aac audiofile flac iconv id3 libmikmod musepack ogg libao
 
 .include "../../mk/bsd.options.mk"
 
@@ -64,6 +64,13 @@
 CONFIGURE_ARGS+=	--disable-ogg
 .endif
 
+.if !empty(PKG_OPTIONS:Mlibao)
+.include "../../audio/libao/buildlink3.mk"
+CONFIGURE_ARGS+=	--enable-ao
+.else
+CONFIGURE_ARGS+=	--disable-ao
+.endif
+
 # when IPv6 support is enabled, mpd doesn't listen on an IPv4 address.
 #.if !empty(PKG_OPTIONS:Minet6)
 #CONFIGURE_ARGS+=	--enable-ipv6

>Unformatted: