diff options
author | 2004-01-11 12:47:12 +0000 | |
---|---|---|
committer | 2004-01-11 12:47:12 +0000 | |
commit | 4df7b0747609a98e2dc5e1aeb9f05c9b54e6c5a4 (patch) | |
tree | 4876c1a3e8d57e73638ddc56b29105383e68f4a2 /net-misc/tiers | |
parent | Added ~sparc keyword. (diff) | |
download | historical-4df7b0747609a98e2dc5e1aeb9f05c9b54e6c5a4.tar.gz historical-4df7b0747609a98e2dc5e1aeb9f05c9b54e6c5a4.tar.bz2 historical-4df7b0747609a98e2dc5e1aeb9f05c9b54e6c5a4.zip |
Initial commit, ebuild by robbat2@gentoo.org
Diffstat (limited to 'net-misc/tiers')
-rw-r--r-- | net-misc/tiers/ChangeLog | 10 | ||||
-rw-r--r-- | net-misc/tiers/Manifest | 4 | ||||
-rw-r--r-- | net-misc/tiers/files/digest-tiers-1.1 | 3 | ||||
-rw-r--r-- | net-misc/tiers/files/tiers1.1-gccfixes.patch | 201 | ||||
-rw-r--r-- | net-misc/tiers/tiers-1.1.ebuild | 40 |
5 files changed, 258 insertions, 0 deletions
diff --git a/net-misc/tiers/ChangeLog b/net-misc/tiers/ChangeLog new file mode 100644 index 000000000000..492b78456582 --- /dev/null +++ b/net-misc/tiers/ChangeLog @@ -0,0 +1,10 @@ +# ChangeLog for net-misc/tiers +# Copyright 2000-2004 Gentoo Technologies, Inc.; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/tiers/ChangeLog,v 1.1 2004/01/11 12:47:12 robbat2 Exp $ + +*tiers-1.1 (11 Jan 2004) + + 11 Jan 2004; Robin H. Johnson <robbat2@gentoo.org> tiers-1.1.ebuild, + files/tiers1.1-gccfixes.patch: + Initial commit, ebuild by robbat2@gentoo.org + diff --git a/net-misc/tiers/Manifest b/net-misc/tiers/Manifest new file mode 100644 index 000000000000..41eba914fafa --- /dev/null +++ b/net-misc/tiers/Manifest @@ -0,0 +1,4 @@ +MD5 8d06ed24e7df8615f3dfcd622110dcae tiers-1.1.ebuild 1357 +MD5 54967dcbbd114fbb49cc9a5bcf9f1e2a ChangeLog 388 +MD5 324eee4fe6016c45a7f30f6f214a46ed files/digest-tiers-1.1 174 +MD5 0b8b2907e0f34c042c6faf3f71df9077 files/tiers1.1-gccfixes.patch 5840 diff --git a/net-misc/tiers/files/digest-tiers-1.1 b/net-misc/tiers/files/digest-tiers-1.1 new file mode 100644 index 000000000000..9d1cdebaf623 --- /dev/null +++ b/net-misc/tiers/files/digest-tiers-1.1 @@ -0,0 +1,3 @@ +MD5 c7d5d0dfa7f7e07b9970664701279991 tiers1.1.tar.gz 392532 +MD5 68dacec891d76477e28a70d22fece73d tiers2ns-lan.awk 3258 +MD5 f5c4f08f4b9074c188b5d1ec5f98d3c8 tiers2ns.awk 2562 diff --git a/net-misc/tiers/files/tiers1.1-gccfixes.patch b/net-misc/tiers/files/tiers1.1-gccfixes.patch new file mode 100644 index 000000000000..db340cad1f04 --- /dev/null +++ b/net-misc/tiers/files/tiers1.1-gccfixes.patch @@ -0,0 +1,201 @@ +diff -urN tiers1.1/src/Makefile tiers1.1.new/src/Makefile +--- tiers1.1/src/Makefile 1997-07-12 23:22:30.000000000 -0700 ++++ tiers1.1.new/src/Makefile 2004-01-11 04:56:33.000000000 -0800 +@@ -31,7 +31,9 @@ + # flags + # + #FLAGS= -fconserve-space -fno-inline -Wall -Winline -Wpointer-arith -g -DDEBUG +-FLAGS= -g -fconserve-space ++FLAGS = $(CFLAGS) -fPIC #-g -fconserve-space ++CONFIGFILE = ./tiers_config ++FLAGS += -DCONFIGFILE="\"$(CONFIGFILE)\"" + + # + # tools +diff -urN tiers1.1/src/tiers.cc tiers1.1.new/src/tiers.cc +--- tiers1.1/src/tiers.cc 1997-03-04 13:54:18.000000000 -0800 ++++ tiers1.1.new/src/tiers.cc 2004-01-11 04:56:33.000000000 -0800 +@@ -24,6 +24,7 @@ + #include "tiers.hh" + #endif + ++#include "tiers_vars.hh" + + + //////////////////////////////////////////////////////////////////////// +@@ -506,4 +507,3 @@ + } + + // end of file +- +diff -urN tiers1.1/src/tiers.hh tiers1.1.new/src/tiers.hh +--- tiers1.1/src/tiers.hh 1998-01-12 02:10:46.000000000 -0800 ++++ tiers1.1.new/src/tiers.hh 2004-01-11 04:56:33.000000000 -0800 +@@ -20,6 +20,8 @@ + #ifndef _TIERS_HH + #define _TIERS_HH + ++using namespace std; ++ + + //////////////////////////////////////////////////////////////////////// + // Model +@@ -264,46 +266,46 @@ + // Defined in tiers_config.cc + + // Type of output produced by the model, e.g. Model::GENERIC, Model::GNUPLOT +-Model::OpType OP_TYPE; ++extern Model::OpType OP_TYPE; + + // If set, TIERS_VERBOSE causes the output to contain the + // parameters used to generate the model and helpful headings + // If undefined, the output is a simple list of nodes and edges +-bool TIERS_VERBOSE; ++extern bool TIERS_VERBOSE; + + // If set, TIERS_LABEL_XXX causes the output to contain a label for + // each of the nodes of type XXX +-bool TIERS_LABEL_WAN; +-bool TIERS_LABEL_MAN; +-bool TIERS_LABEL_LAN; ++extern bool TIERS_LABEL_WAN; ++extern bool TIERS_LABEL_MAN; ++extern bool TIERS_LABEL_LAN; + + + // If defined as true, the operation of the model is more verbose + // If undefined, the model should run with no debugging output +-bool TIERS_DEBUG; ++extern bool TIERS_DEBUG; + + // If defined as true, then an undirected list of edges is produced in the + // output, i.e. the edges (i,j) and (j,i) only appear once in the output + // Note that all LAN edges are assumed bidirectional +-bool REMOVE_DUP_EDGES; ++extern bool REMOVE_DUP_EDGES; + + // Set these true to apply proxmity tests to nodes in each network type +-bool PROXIMITY_TEST_WAN; +-bool PROXIMITY_TEST_MAN; +-bool PROXIMITY_TEST_LAN; ++extern bool PROXIMITY_TEST_WAN; ++extern bool PROXIMITY_TEST_MAN; ++extern bool PROXIMITY_TEST_LAN; + + // The size of a unit in WAN, MAN and LAN grids + // e.g. 1000km, 1km, 1m would be best, but the current values fit with + // typical int sizes +-unsigned long int WAN_SCALE; +-unsigned long int MAN_SCALE; +-unsigned long int LAN_SCALE; ++extern unsigned long int WAN_SCALE; ++extern unsigned long int MAN_SCALE; ++extern unsigned long int LAN_SCALE; + + // GRID is the size of the square grid on which points are placed +-unsigned long int GRID; ++extern unsigned long int GRID; + + // The comment character for output +-char COM; ++extern char COM; + + + // +@@ -311,13 +313,13 @@ + // + + // The output directory for results from gnuplot +-char *title; ++extern char *title; + + // The title for results from gnuplot +-char *outputdir; ++extern char *outputdir; + + // Create a unique identifier for each model +-long int ModelId; ++extern long int ModelId; + + // Forward declaration + unsigned long int max(unsigned long int A, unsigned long int B); +diff -urN tiers1.1/src/tiers_config.cc tiers1.1.new/src/tiers_config.cc +--- tiers1.1/src/tiers_config.cc 1997-07-13 02:55:53.000000000 -0700 ++++ tiers1.1.new/src/tiers_config.cc 2004-01-11 04:58:36.000000000 -0800 +@@ -17,7 +17,8 @@ + + // tiers_config.cc + +-#include <fstream.h> // for ifstream ++#include <fstream> // for ifstream ++#include <iostream> // for ifstream + #include <string.h> // for strcpy + #include <stdlib.h> // for strtoul + +@@ -36,10 +37,13 @@ + { + bool ret = true; + +- ifstream config_file("./tiers_config"); ++#ifndef CONFIGFILE ++#error You need to define CONFIGFILE on the commandline ++#endif ++ ifstream config_file(CONFIGFILE); + if (!config_file) + { +- cerr << "Tiers:: cannot open file './tiers_config'" << endl; ++ cerr << "Tiers:: cannot open file '" << CONFIGFILE << "'" << endl; + } + + // Read the contents of the file in, skipping blank lines or lines which +diff -urN tiers1.1/src/tiers_main.cc tiers1.1.new/src/tiers_main.cc +--- tiers1.1/src/tiers_main.cc 1997-07-06 00:58:31.000000000 -0700 ++++ tiers1.1.new/src/tiers_main.cc 2004-01-11 04:56:33.000000000 -0800 +@@ -25,11 +25,11 @@ + #include "tiers.hh" + #endif + +-extern "C" +-{ +- long int time(int dummy); +- char * initstate(unsigned seed, char *state, int n); +-} ++//extern "C" ++//{ ++// long int time(int dummy); ++// char * initstate(unsigned seed, char *state, int n); ++//} + + unsigned long int NW; // maximum number of WANs, currently 1 + unsigned long int NM; // maximum number of MANs per WAN +@@ -63,7 +63,7 @@ + cout.setf( ios::unitbuf ); + + // TIERS_VERBOSE +-#ifdef 0 ++#ifdef FALSE + cout << "Main:: Processing arguments. Arguments are:" + << endl; + for (int i = 0; i < argc; i++) +diff -urN tiers1.1/src/tiers_vars.hh tiers1.1.new/src/tiers_vars.hh +--- tiers1.1/src/tiers_vars.hh 1969-12-31 16:00:00.000000000 -0800 ++++ tiers1.1.new/src/tiers_vars.hh 2004-01-11 04:56:33.000000000 -0800 +@@ -0,0 +1,18 @@ ++Model::OpType OP_TYPE; ++bool TIERS_VERBOSE; ++bool TIERS_LABEL_WAN; ++bool TIERS_LABEL_MAN; ++bool TIERS_LABEL_LAN; ++bool TIERS_DEBUG; ++bool REMOVE_DUP_EDGES; ++bool PROXIMITY_TEST_WAN; ++bool PROXIMITY_TEST_MAN; ++bool PROXIMITY_TEST_LAN; ++unsigned long int WAN_SCALE; ++unsigned long int MAN_SCALE; ++unsigned long int LAN_SCALE; ++unsigned long int GRID; ++char COM; ++char *title; ++char *outputdir; ++long int ModelId; diff --git a/net-misc/tiers/tiers-1.1.ebuild b/net-misc/tiers/tiers-1.1.ebuild new file mode 100644 index 000000000000..3ca50480486a --- /dev/null +++ b/net-misc/tiers/tiers-1.1.ebuild @@ -0,0 +1,40 @@ +# Copyright 1999-2004 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/tiers/tiers-1.1.ebuild,v 1.1 2004/01/11 12:47:12 robbat2 Exp $ + +MY_P="${PN}${PV}" +DESCRIPTION="Random network topography generator" +HOMEPAGE="http://www.isi.edu/nsnam/ns/ns-topogen.html#tiers" +SRC_URI="http://www.isi.edu/nsnam/dist/topogen/${MY_P}.tar.gz + http://www.isi.edu/nsnam/dist/topogen/tiers2ns-lan.awk" +LICENSE="BSD as-is" +SLOT="0" +KEYWORDS="~x86" +IUSE="" +DEPEND="sys-devel/gcc virtual/glibc" +RDEPEND="sys-apps/gawk media-gfx/gnuplot virtual/glibc" +S=${WORKDIR}/${PN}${PV} + +src_unpack() { + unpack ${MY_P}.tar.gz + epatch ${FILESDIR}/${MY_P}-gccfixes.patch + sed -e '1a\#!/bin/sh' -e '1d' -e "s|-f |-f /usr/share/${PN}/|g" -i ${S}/bin/strip4gnuplot3.5 +} + +src_compile() { + cd ${S}/src + emake CFLAGS="${CFLAGS}" CONFIGFILE="/etc/tiers-gnuplot.conf" EXEC="../bin/tiers-gnuplot" || die + # cleanup for a sec + rm *.o + emake CFLAGS="${CFLAGS}" CONFIGFILE="/etc/tiers.conf" EXEC="../bin/tiers" || die +} + +src_install() { + dobin bin/tiers bin/tiers-gnuplot bin/strip4gnuplot3.5 + insinto /etc + newins src/tiers_config.generic tiers.conf + newins src/tiers_config.gnuplot tiers-gnuplot.conf + insinto /usr/share/${PN} + doins bin/*.awk ${DISTDIR}/tiers2ns-lan.awk + dodoc CHANGES COPYRIGHT README docs/* +} |