Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Dec 2012 04:31:59 +0000 (UTC)
From:      Marcelo Araujo <araujo@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r308817 - head/audio/icecast
Message-ID:  <201212130431.qBD4Vx72040602@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: araujo
Date: Thu Dec 13 04:31:58 2012
New Revision: 308817
URL: http://svnweb.freebsd.org/changeset/ports/308817

Log:
  - Add LICENSE.
  - Add MAKE_JOBS_SAFE.
  - Support USE_READLINE.
  - Support PORTDOCS.
  - Trim header.
  
  PR:		ports/171961
  Submitted by:	KATO Tsuguru <tkato432@yahoo.com>

Modified:
  head/audio/icecast/Makefile
  head/audio/icecast/pkg-plist

Modified: head/audio/icecast/Makefile
==============================================================================
--- head/audio/icecast/Makefile	Thu Dec 13 04:30:58 2012	(r308816)
+++ head/audio/icecast/Makefile	Thu Dec 13 04:31:58 2012	(r308817)
@@ -1,9 +1,5 @@
-# New ports collection makefile for: icecast
-# Date created:         28 Jan 1999
-# Whom:                 Chip Marshall <chip@eboai.org>
-#
+# Created by: Chip Marshall <chip@eboai.org>
 # $FreeBSD$
-#
 
 PORTNAME=	icecast
 PORTVERSION=	1.3.12
@@ -14,32 +10,46 @@ MASTER_SITES=	http://downloads.xiph.org/
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	A streaming mp3 audio server
 
-HAS_CONFIGURE=	yes
+LICENSE=	GPLv2 # (or later)
+
+OPTIONS_DEFINE=	DOCS
+
+USE_READLINE=	yes
+GNU_CONFIGURE=	yes
 CONFIGURE_ARGS=	--with-libwrap
+MAKE_JOBS_SAFE=	yes
+
+CPPFLAGS+=	${PTHREAD_CFLAGS}
+LDFLAGS+=	${PTHREAD_LIBS}
+
 SUB_FILES=	pkg-message
 
+.include <bsd.port.options.mk>
+
 pre-patch:
-	@${REINPLACE_CMD} -e 's|<history.h>|<readline/history.h>|' \
-		-e 's|<readline.h>|<readline/readline.h>|' \
-		${WRKSRC}/src/admin.c
-	@${REINPLACE_CMD} -e 's|#undef HAVE_HISTORY_H|#undef HAVE_READLINE_HISTORY_H|g' \
-		${WRKSRC}/config.h.in
+	@${REINPLACE_CMD} -e \
+		's|<readline.h>|<readline/readline.h>| ; \
+		 s|<history.h>|<readline/history.h>|' ${WRKSRC}/src/admin.c
+	@${REINPLACE_CMD} -e \
+		's|HAVE_HISTORY_H|HAVE_READLINE_HISTORY_H|g' ${WRKSRC}/config.h.in
 
 do-install:
 	${INSTALL_PROGRAM} ${WRKSRC}/src/icecast ${PREFIX}/sbin
-	${MKDIR} ${PREFIX}/etc/icecast/conf
-	${MKDIR} ${PREFIX}/etc/icecast/templates
+	@${MKDIR} ${ETCDIR}/conf
 .for CONF in groups.aut.dist icecast.conf.dist mounts.aut.dist users.aut.dist
-	${INSTALL_DATA} ${WRKSRC}/conf/${CONF} ${PREFIX}/etc/icecast/conf
+	${INSTALL_DATA} ${WRKSRC}/conf/${CONF} ${ETCDIR}/conf
 .endfor
-.for TEMPL in 306.html 400.html 403.html 404.html 504.html bodytag.html info.html \
-	      list_directory.html mountlist.html statistics.html admin_describe.html \
-	      admin.html alias_add.html manual.html alias_del.html header.html \
-	      footer.html admin_change.html
-	${INSTALL_DATA} ${WRKSRC}/templates/${TEMPL} ${PREFIX}/etc/icecast/templates
+	@${MKDIR} ${ETCDIR}/templates
+.for TEMPL in 306.html 400.html 403.html 404.html 504.html bodytag.html \
+	info.html list_directory.html mountlist.html statistics.html \
+	admin_describe.html admin.html alias_add.html manual.html \
+	alias_del.html header.html footer.html admin_change.html
+	${INSTALL_DATA} ${WRKSRC}/templates/${TEMPL} ${ETCDIR}/templates
 .endfor
-	${MKDIR} ${PREFIX}/share/doc/icecast/
-	${INSTALL_DATA} ${WRKSRC}/doc/manual.html ${PREFIX}/share/doc/icecast/
-	@${CAT} ${PKGMESSAGE} | ${SED} -e 's,%%PREFIX%%,${PREFIX},g'
+.if ${PORT_OPTIONS:MDOCS}
+	@${MKDIR} ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/doc/manual.html ${DOCSDIR}
+.endif
+	@${CAT} ${PKGMESSAGE}
 
 .include <bsd.port.mk>

Modified: head/audio/icecast/pkg-plist
==============================================================================
--- head/audio/icecast/pkg-plist	Thu Dec 13 04:30:58 2012	(r308816)
+++ head/audio/icecast/pkg-plist	Thu Dec 13 04:31:58 2012	(r308817)
@@ -1,28 +1,28 @@
-etc/icecast/conf/groups.aut.dist
-etc/icecast/conf/icecast.conf.dist
-etc/icecast/conf/mounts.aut.dist
-etc/icecast/conf/users.aut.dist
-etc/icecast/templates/306.html
-etc/icecast/templates/400.html
-etc/icecast/templates/403.html
-etc/icecast/templates/404.html
-etc/icecast/templates/504.html
-etc/icecast/templates/admin.html
-etc/icecast/templates/admin_change.html
-etc/icecast/templates/admin_describe.html
-etc/icecast/templates/alias_add.html
-etc/icecast/templates/alias_del.html
-etc/icecast/templates/bodytag.html
-etc/icecast/templates/footer.html
-etc/icecast/templates/header.html
-etc/icecast/templates/info.html
-etc/icecast/templates/list_directory.html
-etc/icecast/templates/manual.html
-etc/icecast/templates/mountlist.html
-etc/icecast/templates/statistics.html
+%%ETCDIR%%/conf/groups.aut.dist
+%%ETCDIR%%/conf/icecast.conf.dist
+%%ETCDIR%%/conf/mounts.aut.dist
+%%ETCDIR%%/conf/users.aut.dist
+%%ETCDIR%%/templates/306.html
+%%ETCDIR%%/templates/400.html
+%%ETCDIR%%/templates/403.html
+%%ETCDIR%%/templates/404.html
+%%ETCDIR%%/templates/504.html
+%%ETCDIR%%/templates/admin.html
+%%ETCDIR%%/templates/admin_change.html
+%%ETCDIR%%/templates/admin_describe.html
+%%ETCDIR%%/templates/alias_add.html
+%%ETCDIR%%/templates/alias_del.html
+%%ETCDIR%%/templates/bodytag.html
+%%ETCDIR%%/templates/footer.html
+%%ETCDIR%%/templates/header.html
+%%ETCDIR%%/templates/info.html
+%%ETCDIR%%/templates/list_directory.html
+%%ETCDIR%%/templates/manual.html
+%%ETCDIR%%/templates/mountlist.html
+%%ETCDIR%%/templates/statistics.html
 sbin/icecast
-%%DOCSDIR%%/manual.html
-@dirrm etc/icecast/conf
-@dirrm etc/icecast/templates
-@dirrm etc/icecast
-@dirrm %%DOCSDIR%%
+%%PORTDOCS%%%%DOCSDIR%%/manual.html
+%%PORTDOCS%%@dirrm %%DOCSDIR%%
+@dirrm %%ETCDIR%%/templates
+@dirrm %%ETCDIR%%/conf
+@dirrm %%ETCDIR%%



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