diff options
author | Lisa M. Seelye <lisa@gentoo.org> | 2003-10-30 00:17:12 +0000 |
---|---|---|
committer | Lisa M. Seelye <lisa@gentoo.org> | 2003-10-30 00:17:12 +0000 |
commit | 6a6852a6c88a2c32036b86a4ad7084560053b9e7 (patch) | |
tree | fe560b707898dc98b09672ee1d8977ce49d9c810 /net-analyzer/traffic-vis | |
parent | Added to ~ppc (diff) | |
download | historical-6a6852a6c88a2c32036b86a4ad7084560053b9e7.tar.gz historical-6a6852a6c88a2c32036b86a4ad7084560053b9e7.tar.bz2 historical-6a6852a6c88a2c32036b86a4ad7084560053b9e7.zip |
*** empty log message ***
Diffstat (limited to 'net-analyzer/traffic-vis')
-rw-r--r-- | net-analyzer/traffic-vis/ChangeLog | 12 | ||||
-rw-r--r-- | net-analyzer/traffic-vis/files/digest-traffic-vis-0.35 | 1 | ||||
-rw-r--r-- | net-analyzer/traffic-vis/files/traffic-vis-0.35-gentoo.patch | 102 | ||||
-rw-r--r-- | net-analyzer/traffic-vis/files/traffic-vis.conf.d | 11 | ||||
-rw-r--r-- | net-analyzer/traffic-vis/files/traffic-vis.init.d | 22 | ||||
-rw-r--r-- | net-analyzer/traffic-vis/traffic-vis-0.35.ebuild | 54 |
6 files changed, 202 insertions, 0 deletions
diff --git a/net-analyzer/traffic-vis/ChangeLog b/net-analyzer/traffic-vis/ChangeLog new file mode 100644 index 000000000000..ccc5a0f9bc03 --- /dev/null +++ b/net-analyzer/traffic-vis/ChangeLog @@ -0,0 +1,12 @@ +# ChangeLog for net-analyzer/traffic-vis +# Copyright 2000-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/traffic-vis/ChangeLog,v 1.1 2003/10/30 00:17:12 lisa Exp $ + +*traffic-vis-0.35 (29 Oct 2003) + + 29 Oct 2003; Lisa Seelye <lisa@gentoo.org> traffic-vis-0.35.ebuild, + files/traffic-vis-0.35-gentoo.patch, files/traffic-vis.conf.d, + files/traffic-vis.init.d: + Initial entry, closing bug 31865, submitted by Sven Wegener + <sven.wegener@stealer.net> + diff --git a/net-analyzer/traffic-vis/files/digest-traffic-vis-0.35 b/net-analyzer/traffic-vis/files/digest-traffic-vis-0.35 new file mode 100644 index 000000000000..33aca6006503 --- /dev/null +++ b/net-analyzer/traffic-vis/files/digest-traffic-vis-0.35 @@ -0,0 +1 @@ +MD5 5c00ec49403aa0f38f04f89034f4a689 traffic-vis-0.35.tar.gz 41202 diff --git a/net-analyzer/traffic-vis/files/traffic-vis-0.35-gentoo.patch b/net-analyzer/traffic-vis/files/traffic-vis-0.35-gentoo.patch new file mode 100644 index 000000000000..9b0e076d4ec8 --- /dev/null +++ b/net-analyzer/traffic-vis/files/traffic-vis-0.35-gentoo.patch @@ -0,0 +1,102 @@ +--- frontends/htmlfe.c ++++ frontends/htmlfe.c 2003-06-20 07:07:17.000000000 +0000 +@@ -188,7 +188,7 @@ + <TD ALIGN=\"RIGHT\">\n\ + %llu\n\ + </TD>\n\ +- </TR> ++ </TR>\ + ", host->bytes_sent, host->bytes_received); + + fprintf(out, "\ +--- frontends/traffic-togif ++++ frontends/traffic-togif 2003-10-23 19:29:30.000000000 +0000 +@@ -31,7 +31,7 @@ + my $y_size = 750; + + my $traffic_tops = "/usr/sbin/traffic-tops"; +-my $gs = "/usr/bin/ghostscript"; ++my $gs = "/usr/bin/gs"; + my $pnmcrop = "/usr/bin/pnmcrop"; + my $pnmscale = "/usr/bin/pnmscale"; + my $ppmtogif = "/usr/bin/ppmtogif"; +--- collector/Makefile ++++ collector/Makefile 2003-10-23 19:45:52.000000000 +0000 +@@ -1,4 +1,4 @@ +-CFLAGS= -DVERSION="\"$(VERSION)"\" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) ++CFLAGS+= -DVERSION="\"$(VERSION)"\" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) + OBJS=packet-parse.o packet-summary.o summary-output.o ../util.o + TARGETS=traffic-collector + LFLAGS=-L.. +@@ -7,7 +7,7 @@ + all: $(TARGETS) + + traffic-collector: traffic-collector.o $(OBJS) +- $(CC) -o $@ traffic-collector.o $(OBJS) $(LIBS) ++ $(CC) $(CFLAGS) -o $@ traffic-collector.o $(OBJS) $(LIBS) + + install: + install -m 750 -o root -g root traffic-collector $(SBINDIR) +--- frontends/Makefile ++++ frontends/Makefile 2003-10-23 19:48:02.000000000 +0000 +@@ -1,4 +1,4 @@ +-CFLAGS= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) ++CFLAGS+= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) + OBJS=htmlfe.o psfe.o textfe.o + TARGETS=traffic-tops traffic-totext traffic-tohtml + LFLAGS=-L.. +@@ -7,13 +7,13 @@ + all: $(OBJS) $(TARGETS) + + traffic-tops: traffic-tops.o psfe.o ../libreport.a +- $(CC) -o $@ traffic-tops.o psfe.o $(LFLAGS) $(LIBS) -lm ++ $(CC) $(CFLAGS) -o $@ traffic-tops.o psfe.o $(LFLAGS) $(LIBS) -lm + + traffic-totext: traffic-totext.o textfe.o ../libreport.a +- $(CC) -o $@ traffic-totext.o textfe.o $(LFLAGS) $(LIBS) ++ $(CC) $(CFLAGS) -o $@ traffic-totext.o textfe.o $(LFLAGS) $(LIBS) + + traffic-tohtml: traffic-tohtml.o htmlfe.o ../libreport.a +- $(CC) -o $@ traffic-tohtml.o htmlfe.o $(LFLAGS) $(LIBS) ++ $(CC) $(CFLAGS) -o $@ traffic-tohtml.o htmlfe.o $(LFLAGS) $(LIBS) + + install: + install -m 755 -o root -g root traffic-tops $(SBINDIR) +--- sort/Makefile ++++ sort/Makefile 2003-10-23 19:49:11.000000000 +0000 +@@ -1,4 +1,4 @@ +-CFLAGS= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) ++CFLAGS+= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) + OBJS= + TARGETS=traffic-sort + LFLAGS=-L.. +@@ -7,7 +7,7 @@ + all: $(TARGETS) + + traffic-sort: traffic-sort.o ../libreport.a +- $(CC) $(LFLAGS) -o $@ traffic-sort.o $(LIBS) ++ $(CC) $(CFLAGS) $(LFLAGS) -o $@ traffic-sort.o $(LIBS) + + install: + install -m 755 -o root -g root traffic-sort $(SBINDIR) +--- utils/Makefile ++++ utils/Makefile 2003-10-23 19:50:48.000000000 +0000 +@@ -1,4 +1,4 @@ +-CFLAGS= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) ++CFLAGS+= -DVERSION="\"$(VERSION)\"" $(DEFINES) $(WARNFLAGS) $(DEBUGFLAGS) $(INCLUDES) -I.. $(OPT_FLAGS) + OBJS= + TARGETS=traffic-resolve traffic-exclude + LFLAGS=-L.. +@@ -7,10 +7,10 @@ + all: $(OBJS) $(TARGETS) + + traffic-exclude: traffic-exclude.o ../libreport.a +- $(CC) -o $@ traffic-exclude.o $(LFLAGS) $(LIBS) ++ $(CC) $(CFLAGS) -o $@ traffic-exclude.o $(LFLAGS) $(LIBS) + + traffic-resolve: traffic-resolve.o ../libreport.a +- $(CC) -o $@ traffic-resolve.o $(LFLAGS) $(LIBS) ++ $(CC) $(CFLAGS) -o $@ traffic-resolve.o $(LFLAGS) $(LIBS) + + install: + install -m 755 -o root -g root traffic-resolve $(SBINDIR) diff --git a/net-analyzer/traffic-vis/files/traffic-vis.conf.d b/net-analyzer/traffic-vis/files/traffic-vis.conf.d new file mode 100644 index 000000000000..12307b7215fc --- /dev/null +++ b/net-analyzer/traffic-vis/files/traffic-vis.conf.d @@ -0,0 +1,11 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/traffic-vis/files/traffic-vis.conf.d,v 1.1 2003/10/30 00:17:12 lisa Exp $ + +# Config file for /etc/init.d/traffic-vis + +TRAFFIC_VIS_INTERFACE=eth0 + +TRAFFIC_VIS_OPTIONS= + +TRAFFIC_VIS_FILE=/var/log/traffic-vis diff --git a/net-analyzer/traffic-vis/files/traffic-vis.init.d b/net-analyzer/traffic-vis/files/traffic-vis.init.d new file mode 100644 index 000000000000..b855a33d7173 --- /dev/null +++ b/net-analyzer/traffic-vis/files/traffic-vis.init.d @@ -0,0 +1,22 @@ +#!/sbin/runscript +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License, v2 or later +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/traffic-vis/files/traffic-vis.init.d,v 1.1 2003/10/30 00:17:12 lisa Exp $ + +opts="depend start stop" + +depend() { + need net +} + +start() { + ebegin "Starting traffic-vis" + start-stop-daemon --start --quiet --exec /usr/sbin/traffic-collector -- --pid-file /var/run/traffic-collector.pid --interface $TRAFFIC_VIS_INTERFACE --summary-file $TRAFFIC_VIS_FILE $TRAFFIC_VIS_OPTIONS + eend $? "Failed to start traffic-vis" +} + +stop() { + ebegin "Stopping traffic-vis" + start-stop-daemon --stop --quiet --pidfile /var/run/traffic-collector.pid + eend $? "Failed to stop traffic-vis" +} diff --git a/net-analyzer/traffic-vis/traffic-vis-0.35.ebuild b/net-analyzer/traffic-vis/traffic-vis-0.35.ebuild new file mode 100644 index 000000000000..a9435befdb6e --- /dev/null +++ b/net-analyzer/traffic-vis/traffic-vis-0.35.ebuild @@ -0,0 +1,54 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/traffic-vis/traffic-vis-0.35.ebuild,v 1.1 2003/10/30 00:17:12 lisa Exp $ + +DESCRIPTION="Generate traffic stats in html, ps, text and gif format" +HOMEPAGE="http://www.mindrot.org/traffic-vis.html" +SRC_URI="http://www.mindrot.org/files/${P}.tar.gz" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~x86" + +IUSE="gif" +DEPEND="virtual/glibc + >=net-libs/libpcap-0.4 + gif? ( media-libs/netpbm + app-text/ghostscript + dev-lang/perl ) + >=dev-libs/glib-1.1.15" + +src_unpack() { + unpack ${A} + cd ${S} + + epatch ${FILESDIR}/${P}-gentoo.patch +} + +src_compile() { + make || die "make failed" +} + +src_install() { + dosbin collector/traffic-collector + doman collector/traffic-collector.8 + + for mybin in `use gif >/dev/null && echo "frontends/traffic-togif"` \ + frontends/traffic-tohtml \ + frontends/traffic-tops \ + frontends/traffic-totext \ + sort/traffic-sort \ + utils/traffic-exclude \ + utils/traffic-resolve ; do + + dobin ${mybin} + doman ${mybin}.8 + done + + exeinto /etc/init.d + newexe ${FILESDIR}/traffic-vis.init.d traffic-vis + insinto /etc/conf.d + newins ${FILESDIR}/traffic-vis.conf.d traffic-vis + + dodoc TODO README COPYING BUGS CHANGELOG +} |