diff --git a/net-mgmt/cacti/Makefile b/net-mgmt/cacti/Makefile index b275790c6664..efb2c7cb4d6e 100644 --- a/net-mgmt/cacti/Makefile +++ b/net-mgmt/cacti/Makefile @@ -7,28 +7,27 @@ PORTNAME= cacti PORTVERSION= 0.8.6j${PATCHLEVEL} -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= net www MASTER_SITES= http://www.cacti.net/downloads/ -DISTNAME= ${PORTNAME}-${SITEDISTVERSION} - -MAINTAINER= sem@FreeBSD.org -COMMENT= Web-driven graphing interface for RRDTool +DISTFILES= ${PORTNAME}-${SITEDISTVERSION}${EXTRACT_SUFX} # Vendor's patches PATCH_SITES= http://www.cacti.net/downloads/patches/${SITEDISTVERSION}/ PATCHFILES= ping_php_version4_snmpgetnext.patch \ tree_console_missing_hosts.patch \ thumbnail_graphs_not_working.patch -PATCHLEVEL= .3 -SITEDISTVERSION= ${PORTVERSION:S/${PATCHLEVEL}$//} +PATCH_DIST_STRIP= -p1 -PATCH_DIST_STRIP=-p1 +MAINTAINER= sem@FreeBSD.org +COMMENT= Web-driven graphing interface for RRDTool RUN_DEPENDS= rrdtool:${PORTSDIR}/net/rrdtool +PATCHLEVEL= .3 +PATCH_STRIP= -p1 USE_MYSQL= yes -USE_PHP= mysql pcre session snmp xml +USE_PHP= mysql pcre session sockets snmp xml WANT_PHP_WEB= yes NO_BUILD= yes PKGMESSAGE= ${WRKDIR}/pkg-message @@ -38,11 +37,32 @@ SUB_FILES= pkg-message pkg-install CACTIDIR?= share/cacti CACTIUSER?= cacti CACTIGROUP?= ${CACTIUSER} +WRKSRC= ${WRKDIR}/${PORTNAME}-${SITEDISTVERSION} + +OPTIONS= PLUGIN_ARCH "With plugin architecture" Off + +.include + +SITEDISTVERSION= ${PORTVERSION:S/${PATCHLEVEL}$//} + +# Extra patches +.if defined(WITH_PLUGIN_ARCH) +MASTER_SITES+= http://cactiusers.net/downloads/plugins/:plugin +DISTFILES+= cacti-plugin-arch.tar.gz:plugin +EXTRA_PATCHES+= ${WRKDIR}/${PORTNAME}-plugin-${SITEDISTVERSION}.diff +PLIST_SUB+= PLUGIN="" +.else +PLIST_SUB+= PLUGIN="@comment " +.endif + PLIST_SUB+= CACTIDIR=${CACTIDIR} SUB_LIST+= CACTIDIR=${CACTIDIR} CACTIUSER=${CACTIUSER} \ CACTIGROUP=${CACTIGROUP} -.include +.if defined(WITH_PLUGIN_ARCH) +post-extract: + @${CP} ${WRKDIR}/cacti-plugin-arch/${PORTNAME}-plugin-${SITEDISTVERSION}.diff ${WRKDIR} +.endif post-patch: @${FIND} ${WRKSRC} -name \*.orig -delete; \ @@ -50,7 +70,7 @@ post-patch: ${MV} ${WRKSRC}/include/config.php ${WRKSRC}/include/config.php.orig pre-install: - @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL; \ + @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL do-install: @${MKDIR} ${PREFIX}/${CACTIDIR}; \ diff --git a/net-mgmt/cacti/distinfo b/net-mgmt/cacti/distinfo index b4ae9e8547fb..3e906444a90a 100644 --- a/net-mgmt/cacti/distinfo +++ b/net-mgmt/cacti/distinfo @@ -1,6 +1,9 @@ MD5 (cacti-0.8.6j.tar.gz) = 29436be46b289d13dfce48e7618129e2 SHA256 (cacti-0.8.6j.tar.gz) = 0ddf8a740a5725de67eeea71c38433447ff75388e6e399ce92ccadc36d25bd46 SIZE (cacti-0.8.6j.tar.gz) = 1126337 +MD5 (cacti-plugin-arch.tar.gz) = baaf01f3a863148d6a76510ffc53986d +SHA256 (cacti-plugin-arch.tar.gz) = 9d9600912f5bb347cd82a51f966438469676e01748b4b598fd193a1599feed4c +SIZE (cacti-plugin-arch.tar.gz) = 263447 MD5 (ping_php_version4_snmpgetnext.patch) = bedf583646e59dd628d4aced7e83fdf3 SHA256 (ping_php_version4_snmpgetnext.patch) = 1e19110c696eb56c6de68247c926c5ec7a2e7554df222f39a663556241644170 SIZE (ping_php_version4_snmpgetnext.patch) = 1262 diff --git a/net-mgmt/cacti/files/patch-include-config.php b/net-mgmt/cacti/files/patch-include-config.php index 39dd30e734c1..5f76ecbdd9f2 100644 --- a/net-mgmt/cacti/files/patch-include-config.php +++ b/net-mgmt/cacti/files/patch-include-config.php @@ -1,5 +1,5 @@ ---- include/config.php.orig Fri Jan 6 00:27:51 2006 -+++ include/config.php Fri Jan 6 00:28:39 2006 +--- cacti-0.8.6j/include/config.php.orig Fri Jan 6 00:27:51 2006 ++++ cacti-0.8.6j/include/config.php Fri Jan 6 00:28:39 2006 @@ -24,7 +24,11 @@ +-------------------------------------------------------------------------+ */ diff --git a/net-mgmt/cacti/files/patch-include-db-settings.php b/net-mgmt/cacti/files/patch-include-db-settings.php index 7552ac99e4fd..2d251cdba5d0 100644 --- a/net-mgmt/cacti/files/patch-include-db-settings.php +++ b/net-mgmt/cacti/files/patch-include-db-settings.php @@ -1,5 +1,5 @@ --- /dev/null Tue Jun 21 16:31:36 2005 -+++ include/db-settings.php Tue Jun 21 16:29:15 2005 ++++ cacti-0.8.6j/include/db-settings.php Tue Jun 21 16:29:15 2005 @@ -0,0 +1,9 @@ + + +SITEDISTVERSION= ${PORTVERSION:S/${PATCHLEVEL}$//} + +# Extra patches +.if defined(WITH_PLUGIN_ARCH) +MASTER_SITES+= http://cactiusers.net/downloads/plugins/:plugin +DISTFILES+= cacti-plugin-arch.tar.gz:plugin +EXTRA_PATCHES+= ${WRKDIR}/${PORTNAME}-plugin-${SITEDISTVERSION}.diff +PLIST_SUB+= PLUGIN="" +.else +PLIST_SUB+= PLUGIN="@comment " +.endif + PLIST_SUB+= CACTIDIR=${CACTIDIR} SUB_LIST+= CACTIDIR=${CACTIDIR} CACTIUSER=${CACTIUSER} \ CACTIGROUP=${CACTIGROUP} -.include +.if defined(WITH_PLUGIN_ARCH) +post-extract: + @${CP} ${WRKDIR}/cacti-plugin-arch/${PORTNAME}-plugin-${SITEDISTVERSION}.diff ${WRKDIR} +.endif post-patch: @${FIND} ${WRKSRC} -name \*.orig -delete; \ @@ -50,7 +70,7 @@ post-patch: ${MV} ${WRKSRC}/include/config.php ${WRKSRC}/include/config.php.orig pre-install: - @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL; \ + @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL do-install: @${MKDIR} ${PREFIX}/${CACTIDIR}; \ diff --git a/net/cacti/distinfo b/net/cacti/distinfo index b4ae9e8547fb..3e906444a90a 100644 --- a/net/cacti/distinfo +++ b/net/cacti/distinfo @@ -1,6 +1,9 @@ MD5 (cacti-0.8.6j.tar.gz) = 29436be46b289d13dfce48e7618129e2 SHA256 (cacti-0.8.6j.tar.gz) = 0ddf8a740a5725de67eeea71c38433447ff75388e6e399ce92ccadc36d25bd46 SIZE (cacti-0.8.6j.tar.gz) = 1126337 +MD5 (cacti-plugin-arch.tar.gz) = baaf01f3a863148d6a76510ffc53986d +SHA256 (cacti-plugin-arch.tar.gz) = 9d9600912f5bb347cd82a51f966438469676e01748b4b598fd193a1599feed4c +SIZE (cacti-plugin-arch.tar.gz) = 263447 MD5 (ping_php_version4_snmpgetnext.patch) = bedf583646e59dd628d4aced7e83fdf3 SHA256 (ping_php_version4_snmpgetnext.patch) = 1e19110c696eb56c6de68247c926c5ec7a2e7554df222f39a663556241644170 SIZE (ping_php_version4_snmpgetnext.patch) = 1262 diff --git a/net/cacti/files/patch-include-config.php b/net/cacti/files/patch-include-config.php index 39dd30e734c1..5f76ecbdd9f2 100644 --- a/net/cacti/files/patch-include-config.php +++ b/net/cacti/files/patch-include-config.php @@ -1,5 +1,5 @@ ---- include/config.php.orig Fri Jan 6 00:27:51 2006 -+++ include/config.php Fri Jan 6 00:28:39 2006 +--- cacti-0.8.6j/include/config.php.orig Fri Jan 6 00:27:51 2006 ++++ cacti-0.8.6j/include/config.php Fri Jan 6 00:28:39 2006 @@ -24,7 +24,11 @@ +-------------------------------------------------------------------------+ */ diff --git a/net/cacti/files/patch-include-db-settings.php b/net/cacti/files/patch-include-db-settings.php index 7552ac99e4fd..2d251cdba5d0 100644 --- a/net/cacti/files/patch-include-db-settings.php +++ b/net/cacti/files/patch-include-db-settings.php @@ -1,5 +1,5 @@ --- /dev/null Tue Jun 21 16:31:36 2005 -+++ include/db-settings.php Tue Jun 21 16:29:15 2005 ++++ cacti-0.8.6j/include/db-settings.php Tue Jun 21 16:29:15 2005 @@ -0,0 +1,9 @@ +