ports/149795: [PATCH] audio/darkice to 1.0 libaacplus support

Takefu takefu at airport.fm
Thu Aug 19 06:20:05 UTC 2010


>Number:         149795
>Category:       ports
>Synopsis:       [UPDATE] audio/darkice: libaacplus support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 19 06:20:04 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Takefu
>Release:        
>Organization:
FOX Amateur Radio Club
>Environment:
>Description:
libaacplus support PR #149794
Use new USE_RC_SUBR format
Fix config file handling

>How-To-Repeat:
>Fix:
--- darkice.diff begins here ---
diff -ruN /usr/ports/audio/darkice/Makefile audio/darkice/Makefile
--- /usr/ports/audio/darkice/Makefile	2010-07-21 16:52:35.000000000 +0900
+++ audio/darkice/Makefile	2010-08-03 19:45:16.000000000 +0900
@@ -19,16 +19,20 @@
 		TWOLAME "TwoLAME support for MP2" off \
 		FAAC "FAAC support for AAC" off \
 		JACK "Jack support" off \
+		AACPLUS "AAC HEv2 support" off \
 		SAMPLERATE "Libsamplerate support" off

 GNU_CONFIGURE=	yes
 CONFIGURE_ENV=	CPPFLAGS="${PTHREAD_CFLAGS}" LDFLAGS="${PTHREAD_LIBS}" \
 		ac_cv_prog_acx_pthread_config=no
-CONFIGURE_ARGS=	--without-alsa --without-aacplus
+CONFIGURE_ARGS=	--without-alsa
+
+SUB_FILES=	pkg-message
+USE_RC_SUBR=	${PORTNAME}

 MAN1=		darkice.1
 MAN5=		darkice.cfg.5
-PLIST_FILES=	bin/darkice etc/darkice.cfg
+PLIST_FILES=	bin/darkice etc/darkice.cfg.dist

 .include <bsd.port.pre.mk>

@@ -67,6 +71,13 @@
 CONFIGURE_ARGS+=	--without-jack
 .endif

+.if defined(WITH_AACPLUS)
+LIB_DEPENDS+=	aacplus.1:${PORTSDIR}/audio/libaacplus
+CONFIGURE_ARGS+=	--with-aacplus-prefix=${LOCALBASE}
+.else
+CONFIGURE_ARGS+=	--without-aacplus
+.endif
+
 .if defined(WITH_SAMPLERATE)
 LIB_DEPENDS+=	samplerate.1:${PORTSDIR}/audio/libsamplerate
 CONFIGURE_ARGS+=	--with-samplerate-prefix=${LOCALBASE}
@@ -78,4 +89,11 @@
 	@${REINPLACE_CMD} -e '/test/s|==|=|g' ${WRKSRC}/configure
 	@${REINPLACE_CMD} -e 's|-O2 -pedantic||g' ${WRKSRC}/src/Makefile.in

+do-install:
+	@${INSTALL_PROGRAM} ${WRKSRC}/src/${PORTNAME} ${PREFIX}/bin
+	@${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.cfg ${PREFIX}/etc/${PORTNAME}.cfg.dist
+	@${INSTALL_MAN} ${WRKSRC}/man/${PORTNAME}.1 ${MANPREFIX}/man/man1
+	@${INSTALL_MAN} ${WRKSRC}/man/${PORTNAME}.cfg.5 ${MANPREFIX}/man/man5
+	@${CAT} ${PKGMESSAGE}
+
 .include <bsd.port.post.mk>
diff -ruN /usr/ports/audio/darkice/files/darkice.in audio/darkice/files/darkice.in
--- /usr/ports/audio/darkice/files/darkice.in	1970-01-01 09:00:00.000000000 +0900
+++ audio/darkice/files/darkice.in	2010-04-15 15:09:19.000000000 +0900
@@ -0,0 +1,25 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: darkice
+# REQUIRE: DAEMON
+# BEFORE:  LOGIN
+# KEYWORD: SHUTDOWN
+
+. "/etc/rc.subr"
+
+name="darkice"
+rcvar=`set_rcvar`
+
+command="%%PREFIX%%/bin/$name"
+command_args="& 1>/dev/null"
+required_files="%%ETCDIR%%.cfg"
+
+# read configuration and set defaults
+load_rc_config "$name"
+: ${darkice_enable="NO"}
+: ${darkice_flags="-c ${required_files}"}
+
+run_rc_command "$1"
diff -ruN /usr/ports/audio/darkice/files/pkg-message.in audio/darkice/files/pkg-message.in
--- /usr/ports/audio/darkice/files/pkg-message.in	1970-01-01 09:00:00.000000000 +0900
+++ audio/darkice/files/pkg-message.in	2010-04-15 16:44:52.000000000 +0900
@@ -0,0 +1,19 @@
+********************************************************************
+Unless this file already existed, a sample configuration file
+has been placed in %%ETCDIR%%.cfg.
+
+Please edit it according to your needs.
+
+********************************************************************
+
+The darkice will *not* be started automatically. To allow it
+to start, put this line in /etc/rc.conf:
+
+darkice_enable="YES"
+
+Then, it will be started on the next boot. If this line is already
+present, the client will be started now.  Otherwise, edit
+/etc/rc.conf and execute this command:
+
+    %%ETCDIR%%/rc.d/darkice start
+********************************************************************
--- darkice.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list