[21177] trunk/dports/net/nedi/Portfile

source_changes at macosforge.org source_changes at macosforge.org
Wed Jan 10 23:56:19 PST 2007


Revision: 21177
          http://trac.macosforge.org/projects/macports/changeset/21177
Author:   markd at macports.org
Date:     2007-01-10 23:56:19 -0800 (Wed, 10 Jan 2007)

Log Message:
-----------
Add rrdtool dependency and set port for rrdtool support.

Modified Paths:
--------------
    trunk/dports/net/nedi/Portfile

Modified: trunk/dports/net/nedi/Portfile
===================================================================
--- trunk/dports/net/nedi/Portfile	2007-01-11 01:49:21 UTC (rev 21176)
+++ trunk/dports/net/nedi/Portfile	2007-01-11 07:56:19 UTC (rev 21177)
@@ -4,8 +4,9 @@
 
 name				nedi
 version				1.0.w-rc4
+revision			1
 categories			net
-maintainers			markd at opendarwin.org
+maintainers			markd at macports.org
 platforms			darwin
 
 description			Network Discovery Suite
@@ -28,7 +29,8 @@
 				port:p5-net-telnet-cisco \
 				port:p5-algorithm-diff \
 				port:p5-dbi \
-				port:p5-dbd-mysql
+				port:p5-dbd-mysql \
+				port:rrdtool
 
 worksrcdir		${name}-${version}
 
@@ -47,13 +49,16 @@
 destroot {
 	set nedidir ${prefix}/share/
 
-	xinstall -d ${worksrcpath}
-	xinstall -d ${destroot}${prefix}/share
+	xinstall -m 755 -d ${worksrcpath}
+	xinstall -m 755 -d ${destroot}${prefix}/share
 	system "cd ${destroot}${prefix}/share  && gzip -dc ${distpath}/${distname}.tgz | \
 		/usr/bin/gnutar --no-same-owner -xf -"
 
 # Keep nedi.conf from prying eyes because it has passwords!
 	system "chmod 600 ${destroot}${prefix}/share/${name}/nedi.conf"
+
+# Create directory for rrd files
+	xinstall -m 755 -d ${destroot}${prefix}/share/${name}/rrd
 }
 
 post-destroot {
@@ -69,10 +74,14 @@
         reinplace "s|/etc/nedi.conf|${prefix}/share/nedi/nedi.conf|g" \
                 ${destroot}${prefix}/share/${name}/html/inc/libmisc.php
 
+	reinplace "s|/var/nedi/rrd|${prefix}/share/${name}/rrd|g" \
+		${destroot}${prefix}/share/${name}/html/inc/drawrrd.php
+
 # Keep these empty directories
         destroot.keepdirs \
                 ${destroot}${prefix}/share/${name}/db/cfg \
-		${destroot}${prefix}/share/${name}/html/log
+		${destroot}${prefix}/share/${name}/html/log \
+		${destroot}${prefix}/share/${name}/rrd
 }
 
 
@@ -161,7 +170,11 @@
 	cd ${prefix}/share/${name}/nedi.pl
 	sudo -u <nedi-user> nedi.pl -c -d (debug)
 -Put a command in the crontab to discover your network at regular intervals.
- 	For example, to run NeDi every day at 11:00 and 3:00:
-0 11,15 * * * cd ${prefix}/share/${name} ; ./nedi.pl -c >> /dev/null 2>&1
+	A typical interval is 1 hour; to get accurate NeDi rrdtool graphs at
+	NeDi's default settings you must run NeDi at 1 hour intervals.
+	Otherwise, you must adjust NeDi's default rrdtool settings.  To run
+	NeDi every hour, the cron entry is:
+
+0 * * * * cd ${prefix}/share/${name} ; ./nedi.pl -c >> /dev/null 2>&1
 \n"
 }

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20070110/a8f0c1ed/attachment.html


More information about the macports-changes mailing list