summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2016-11-24 23:42:01 +0100
committerJeroen Roovers <jer@gentoo.org>2016-11-24 23:42:01 +0100
commit1aea737bf0bcaed2d63f3f9268e5c2934f35920c (patch)
treed8f094be633a68ec9410df897522814f506d4424 /net-analyzer
parentx11-misc/slock: Version bump. (diff)
downloadgentoo-1aea737bf0bcaed2d63f3f9268e5c2934f35920c.tar.gz
gentoo-1aea737bf0bcaed2d63f3f9268e5c2934f35920c.tar.bz2
gentoo-1aea737bf0bcaed2d63f3f9268e5c2934f35920c.zip
net-analyzer/tcpreplay: Version bump.
Package-Manager: portage-2.3.2
Diffstat (limited to 'net-analyzer')
-rw-r--r--net-analyzer/tcpreplay/Manifest1
-rw-r--r--net-analyzer/tcpreplay/tcpreplay-4.1.2.ebuild77
2 files changed, 78 insertions, 0 deletions
diff --git a/net-analyzer/tcpreplay/Manifest b/net-analyzer/tcpreplay/Manifest
index 4c6627293da1..bab25a62d861 100644
--- a/net-analyzer/tcpreplay/Manifest
+++ b/net-analyzer/tcpreplay/Manifest
@@ -1 +1,2 @@
DIST tcpreplay-4.1.1.tar.gz 2173781 SHA256 61b916ef91049cad2a9ddc8de6f5e3e3cc5d9998dbb644dc91cf3a798497ffe4 SHA512 6be88d3742b93fa557c9142eebe7ae2cf61a5436087f8400260472f87c1dd0d61515b338706afa1c850ae2380c0d5fa664691052d3dc01f3099ad068b67eee87 WHIRLPOOL ce1e4fe845ffbc019316f7a11249828d7b8c65afd9bfbff04950d0666aa79ee61e3bfd98d0870f820423cfb5b21e5274bf328cb4a020f290b0e7faa81297c544
+DIST tcpreplay-4.1.2.tar.gz 2162175 SHA256 da483347e83a9b5df0e0dbb0f822a2d37236e79dda35f4bc4e6684fa827f25ea SHA512 3a7d125f38fe15070d666eacb4a5ef026a73ff850adec7ef3592966f38d1d155002792c5d5ac2476aa034d71be5f31b9dacd5be34af01a336149af3a42cad360 WHIRLPOOL e5ca80234655b3614eebd400954b53d958d08dbe91cf123db07935e5bebfb34ad40cd41a7a25a8d8ee684dbcaeda41c75a18503172830141dca022713b7814d6
diff --git a/net-analyzer/tcpreplay/tcpreplay-4.1.2.ebuild b/net-analyzer/tcpreplay/tcpreplay-4.1.2.ebuild
new file mode 100644
index 000000000000..964c4868b476
--- /dev/null
+++ b/net-analyzer/tcpreplay/tcpreplay-4.1.2.ebuild
@@ -0,0 +1,77 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+inherit autotools flag-o-matic
+
+DESCRIPTION="utilities for editing and replaying previously captured network traffic"
+HOMEPAGE="http://tcpreplay.appneta.com/ https://github.com/appneta/tcpreplay"
+LICENSE="BSD GPL-3"
+SRC_URI="https://github.com/appneta/${PN}/releases/download/v${PV}/${P}.tar.gz"
+
+SLOT="0"
+KEYWORDS="~amd64 ~sparc ~x86"
+IUSE="debug pcapnav +tcpdump"
+
+DEPEND="
+ >=sys-devel/autogen-5.18.4[libopts]
+ dev-libs/libdnet
+ >=net-libs/libpcap-0.9
+ tcpdump? ( net-analyzer/tcpdump )
+ pcapnav? ( net-libs/libpcapnav )
+"
+RDEPEND="${DEPEND}"
+
+DOCS=(
+ docs/{CHANGELOG,CREDIT,HACKING,TODO}
+)
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.1.0-enable-pcap_findalldevs.patch
+)
+
+src_prepare() {
+ default
+
+ sed -i \
+ -e 's|-O3||g' \
+ -e 's|AM_CONFIG_HEADER|AC_CONFIG_HEADERS|g' \
+ configure.ac || die
+ sed -i \
+ -e 's|#include <dnet.h>|#include <dnet/eth.h>|g' \
+ src/common/sendpacket.c || die
+ sed -i \
+ -e 's|@\([A-Z_]*\)@|$(\1)|g' \
+ -e '/tcpliveplay_CFLAGS/s|$| $(LDNETINC)|g' \
+ -e '/tcpliveplay_LDADD/s|$| $(LDNETLIB)|g' \
+ src/Makefile.am || die
+
+ eautoreconf
+}
+
+src_configure() {
+ # By default it uses static linking. Avoid that, bug 252940
+ econf \
+ $(use_enable debug) \
+ $(use_with pcapnav pcapnav-config /usr/bin/pcapnav-config) \
+ $(use_with tcpdump tcpdump /usr/sbin/tcpdump) \
+ --disable-local-libopts \
+ --enable-dynamic-link \
+ --enable-shared \
+ --with-libdnet \
+ --with-testnic2=lo \
+ --with-testnic=lo
+}
+
+src_test() {
+ if [[ ! ${EUID} -eq 0 ]]; then
+ ewarn "Some tests were disabled due to FEATURES=userpriv"
+ ewarn "To run all tests issue the following command as root:"
+ ewarn " # make -C ${S}/test"
+ emake -j1 -C test tcpprep || die "self test failed - see ${S}/test/test.log"
+ else
+ emake -j1 test || {
+ ewarn "Note, that some tests require eth0 iface to be UP." ;
+ die "self test failed - see ${S}/test/test.log" ; }
+ fi
+}