From 84c3c17860e030994c48ec5249116cfde1b080bf Mon Sep 17 00:00:00 2001 From: lwhsu Date: Tue, 2 Oct 2007 18:51:44 +0000 Subject: - Change maintainer's email - Remove dependence on apache - Mark BROKEN on ${OSVERSION} >= 700000 only when using mysql - Use ${COPYTREE_SHARE}, ${INSTALL_DATA} to replace ${CP} -r - Use explicit pkg-plist - Tweak pgsql cdr template - Bump PORTREVISION Approved by: maintainer Pointed out by: sat Suggested by: dougb, pav, rafan, danfe --- www/asterisk-stat/Makefile | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) (limited to 'www/asterisk-stat/Makefile') diff --git a/www/asterisk-stat/Makefile b/www/asterisk-stat/Makefile index 42b54b828dcb..31e2a83bd3b0 100644 --- a/www/asterisk-stat/Makefile +++ b/www/asterisk-stat/Makefile @@ -7,17 +7,17 @@ PORTNAME= asterisk-stat PORTVERSION= 2.0.1 +PORTREVISION= 1 CATEGORIES= www MASTER_SITES= http://www.areski.net/${SITE_SUBDIR}/ DISTNAME= ${PORTNAME}-v${PORTVERSION:S/./_/g} -MAINTAINER= jfkimura@yahoo.com +MAINTAINER= jfkimura@yahoo.co.jp COMMENT= ASTERISK Call Detail Records Analizer LIB_DEPENDS= gd.4:${PORTSDIR}/graphics/gd NO_BUILD= yes -USE_APACHE= yes USE_PHP= session gd pcre WANT_PHP_WEB= yes ASTERISKDIR?= ${WWWDIR} @@ -30,21 +30,21 @@ OPTIONS= PGSQL "Use PostgreSQL instead of MySQL" off .include -.if ${OSVERSION} >= 700000 -BROKEN= Depends on net/asterisk-addons which does not build on 7-CURRENT -.endif - .if defined(WITH_PGSQL) ASTERISKSTATDB= pgsql .else +. if ${OSVERSION} >= 700000 +BROKEN= Depends on net/asterisk-addons which does not build on 7-CURRENT +. endif ASTERISKSTATDB= mysql -# net/asterisk-addons RUN_DEPENDS+= ${LOCALBASE}/lib/asterisk/modules/cdr_addon_mysql.so:${PORTSDIR}/net/asterisk-addons .endif USE_PHP+= ${ASTERISKSTATDB} EXTRA_PATCHES+= ${FILESDIR}/${ASTERISKSTATDB}__patch-cdr.php \ ${FILESDIR}/${ASTERISKSTATDB}__patch-defines.php +PLIST_SUB+= ASTERISKDIR=${ASTERISKDIR:S,^${PREFIX}/,,} \ + ASTERISKSTATDB=${ASTERISKSTATDB} post-patch: @${MV} ${WRKSRC}/images/print.css ${WRKSRC}/css @@ -58,16 +58,9 @@ post-patch: do-install: @${MKDIR} ${ASTERISKDIR} @${MV} ${WRKSRC}/lib/defines.php ${WRKSRC}/lib/defines.php-dist - ${CP} -r ${WRKSRC}/ ${ASTERISKDIR} - ${CP} ${FILESDIR}/cdr_${ASTERISKSTATDB}.tbl ${PREFIX}/etc/asterisk + (cd ${WRKSRC}/ && ${COPYTREE_SHARE} \* ${ASTERISKDIR}) + ${MKDIR} ${PREFIX}/etc/asterisk + ${INSTALL_DATA} ${FILESDIR}/cdr_${ASTERISKSTATDB}.tbl ${PREFIX}/etc/asterisk ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${ASTERISKDIR} -post-install: - @${FIND} ${WRKSRC}/${file} -not -type d \ - | ${SED} -ne 's,^${WRKSRC},${ASTERISKDIR:S,^${TARGETDIR}/,,},p' >> ${TMPPLIST} - @${FIND} -d ${WRKSRC}/${file} -type d \ - | ${SED} -ne 's,^${WRKSRC},@dirrm ${ASTERISKDIR:S,^${TARGETDIR}/,,},p' >> ${TMPPLIST} - @${ECHO} etc/asterisk/cdr_${ASTERISKSTATDB}.tbl >> ${TMPPLIST} - @${CAT} ${PKGMESSAGE} - .include -- cgit