summaryrefslogtreecommitdiff
path: root/net-analyzer/ethloop
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-01-15 15:51:32 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-01-15 15:51:32 +0000
commit21435953e16cda318a82334ddbadb3b5c36d9ea7 (patch)
treee1810a4b135afce04b34862ef0fab2bfaeb8aeca /net-analyzer/ethloop
parent7bc9c63c9da678a7e6fceb095d56c634afd22c56 (diff)
gentoo resync : 15.01.2020
Diffstat (limited to 'net-analyzer/ethloop')
-rw-r--r--net-analyzer/ethloop/Manifest4
-rw-r--r--net-analyzer/ethloop/ethloop-10-r4.ebuild27
-rw-r--r--net-analyzer/ethloop/files/ethloop-10-gcc45.patch4
-rw-r--r--net-analyzer/ethloop/files/ethloop-10-misc.patch65
4 files changed, 97 insertions, 3 deletions
diff --git a/net-analyzer/ethloop/Manifest b/net-analyzer/ethloop/Manifest
index 8ec0e122562c..f206449cf7ae 100644
--- a/net-analyzer/ethloop/Manifest
+++ b/net-analyzer/ethloop/Manifest
@@ -1,4 +1,6 @@
-AUX ethloop-10-gcc45.patch 784 BLAKE2B 279f17c9cdf0e8025ad4f5868431e4ec008bd103da968878d836b23b1e3b5f96a46ffd78156b1ba4b09a84fcd2b9365faae13dc6b16b966ff9df9434ee8443a6 SHA512 213978c89fca49f82c47322e91a4ba6a72b92b711b9386de9833b7330e6fa9fb5668d658968669c1eeeddae96a74c32a086ad630410b9c3b8e153a19e720c036
+AUX ethloop-10-gcc45.patch 712 BLAKE2B b7a58c136663860120467fef7e752b957383d8e5e84325bfda20873581673937e669044a67a61b02080570397e5599e207162e430c910e319d4f32db30a9b412 SHA512 c10c7b723698dc6426478b7e9d861a7a88c887a6df3033c8080f51149882925952ff6cf0d0c7ca1d35dcda2c43cb278d8c4475a37d8be3a5a653c974b48bb7b2
+AUX ethloop-10-misc.patch 1760 BLAKE2B f3e22dc20e87bae4d9deab283581f12330ab4535394c1fb1fb787dc7d550a63da64ab936c3b89f06aa3dc218357eaa7ce8a41de9006b62a31c7026f2c75cf51f SHA512 0bb1bacf5103e9b3715c0242844e90007ea68715dbf51abc12c14c845277f6520023c59f4e014cb955552d7dc7854ebe46524e6f5dc2faf47cb145a844fe5ba1
DIST ethloop10.tgz 3912 BLAKE2B 4cd0ad93693afb2302627b9fcbefa94eefec3d29c55e583c5126aed9cfb20aa7a2d68834fa138debaf767972e7e898245d7297567b322953e1df03b3817a5609 SHA512 82ac0114d0d539f5c057101e1e1f0e2eac32e0bd482bd62e6305f7c4863d0776dcff7bc85167dbcfb136d0b430c9008241c2c0250713beb2703cb052b9b71e63
EBUILD ethloop-10-r3.ebuild 592 BLAKE2B 7ed809c6d8b0ad043e25edd6d4299a756c5f2b3194f5b3cc806867dcf697656537bb8b0fbcb24dcad0384d0e115c5a17e9b8e9f74fb281718055b7db4818c7c9 SHA512 5e5761dc8ccb7bbe860372ec80ce9c5eb94775a9f4ea62ad7395276e5878d21ccb85b1c990d9a7d1baf4d2e4389532a81e9e0f5ec7204d0264ab73229fef8e34
+EBUILD ethloop-10-r4.ebuild 566 BLAKE2B 910631366a94edb0c6ced18743538cbc6b0db4d87421df030097d85fd535d6295adc92201b3a4f92758425046c195fecf676d6ccfe48edfaf9c2bd915e2453e6 SHA512 ff4c6306d6f61a5c457e343a41035f53e785c75dfba7d9d2378f664d84e72ff8543f6ad4b543a73841192f7e5e86300cbab529b1ff541491a6c119c72491e004
MISC metadata.xml 361 BLAKE2B ba68d26d43079aade6030f489fbe6d88a68c289f4bebead36dc0ffc934d675d7b08c4caff6474a37f27f3eb20f71b1c45abe029b72b310b7037bbd95454b1365 SHA512 a4572b46f20688c9d75c5aa555bf051f3416b8992e0c2358f4594be215571f356575441d4e45b2785af0c6c5c5c2d8862f2fd48202cc528ccda3a9e8ba69c214
diff --git a/net-analyzer/ethloop/ethloop-10-r4.ebuild b/net-analyzer/ethloop/ethloop-10-r4.ebuild
new file mode 100644
index 000000000000..4067bea8c944
--- /dev/null
+++ b/net-analyzer/ethloop/ethloop-10-r4.ebuild
@@ -0,0 +1,27 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit toolchain-funcs
+
+DESCRIPTION="Local simulator for testing Linux QoS disciplines"
+HOMEPAGE="http://luxik.cdi.cz/~devik/qos/ethloop/"
+SRC_URI="http://luxik.cdi.cz/~devik/qos/${PN}/${PN}${PV}.tgz"
+
+LICENSE="all-rights-reserved"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86"
+RESTRICT="mirror bindist"
+
+S=${WORKDIR}/${PN}
+PATCHES=(
+ "${FILESDIR}"/${P}-misc.patch
+)
+
+src_compile() {
+ emake CC=$(tc-getCC) CFLAGS="${CFLAGS}"
+}
+
+src_install() {
+ dosbin ethloop
+}
diff --git a/net-analyzer/ethloop/files/ethloop-10-gcc45.patch b/net-analyzer/ethloop/files/ethloop-10-gcc45.patch
index 75b951102245..bf905cd44b2c 100644
--- a/net-analyzer/ethloop/files/ethloop-10-gcc45.patch
+++ b/net-analyzer/ethloop/files/ethloop-10-gcc45.patch
@@ -1,7 +1,7 @@
Fix recv call (bug #336755), add some more includes.
---- a/ethloop.c 2002-05-03 15:13:20.000000000 +0200
-+++ b/ethloop.c 2010-12-27 18:21:24.000000000 +0100
+--- a/ethloop.c
++++ b/ethloop.c
@@ -1,5 +1,7 @@
/* vim: cin sw=4 ts=4
*/
diff --git a/net-analyzer/ethloop/files/ethloop-10-misc.patch b/net-analyzer/ethloop/files/ethloop-10-misc.patch
new file mode 100644
index 000000000000..a866386a7006
--- /dev/null
+++ b/net-analyzer/ethloop/files/ethloop-10-misc.patch
@@ -0,0 +1,65 @@
+--- a/ethloop.c
++++ b/ethloop.c
+@@ -1,5 +1,7 @@
+ /* vim: cin sw=4 ts=4
+ */
++#include <arpa/inet.h> /* htons() */
++#include <sys/types.h> /* recv() */
+ #include <sys/socket.h>
+ #include <sys/ioctl.h>
+ #include <sys/poll.h>
+@@ -13,6 +15,7 @@
+ #include <stdlib.h>
+ #include <sys/time.h>
+ #include <signal.h>
++#include <string.h>
+
+ int sock;
+
+@@ -133,11 +136,11 @@
+ int recv_raw(int tmo)
+ {
+ struct pollfd pf = {sock,POLLIN,0};
+- int r; unsigned short proto;
++ ssize_t r;
+ if(poll(&pf,1,tmo) <= 0) return 0;
+- r = recv(sock,&buf,1550,0);
++ r = recv(sock,&buf,sizeof(buf),0);
+ if (r <= 0) {
+- printf("error recv (%d)\n",r);
++ printf("error recv (%ld)\n",r);
+ return 0;
+ }
+ if (ntohs(buf.proto) != ETH_P_CUST) {
+@@ -239,10 +242,10 @@
+ }
+ }
+
+-main(int c,char *av[])
++int main(int c,char *av[])
+ {
+- unsigned long av_k1=0,av_k2=0,t_k1=0,t_k2=0;
+- unsigned long av_k3=0,av_k4=0,t_k3=0,t_k4=0;
++ unsigned long av_k1=0,av_k2=0;
++ unsigned long av_k3=0,av_k4=0;
+ int x,tmo,flow,diff,lcheck = 0,lwrite = 0,i,n;
+ struct flowtab *fp;
+ sock = socket(PF_PACKET,SOCK_RAW,htons(ETH_P_ALL));
+@@ -309,7 +312,7 @@
+ /* write stats every .5 second */
+ if (us - ALIGN(lwrite,LOGTIME) < LOGTIME) continue;
+ lwrite = us;
+- fprintf(stderr,"store %d at %d ms\n",slog_cnt,us/1000);
++ fprintf(stderr,"store %d at %ld ms\n",slog_cnt,us/1000);
+ for (fp = ftab,i=0;i<FLOWS;fp++,i++) {
+ stp = slog + slog_cnt;
+ stp->av_delay[i] = fp->av_delay/EWMAC;
+@@ -338,7 +341,7 @@
+ printf("%d.%d",(i+1)/2,(i&1)?0:5);
+ for (flow = 0; flow <= maxflow; flow++) {
+ fp = ftab + flow;
+- printf(" %d %d %d %d",stp->av_wrate[flow],
++ printf(" %ld %ld %ld %ld",stp->av_wrate[flow],
+ stp->av_rate[flow], stp->av_delay[flow]/1000,
+ stp->av_jitter[flow]);
+ }