update to netperf 2.6.0
This commit is contained in:
parent
7f225e0319
commit
81e0e291a7
@ -1,42 +1,33 @@
|
|||||||
# $OpenBSD: Makefile,v 1.30 2013/03/10 23:04:44 espie Exp $
|
# $OpenBSD: Makefile,v 1.31 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
|
||||||
COMMENT= Network performance benchmark
|
COMMENT= network performance benchmark
|
||||||
|
|
||||||
|
DISTNAME= netperf-2.6.0
|
||||||
|
|
||||||
DISTNAME= netperf-2.3
|
|
||||||
REVISION= 3
|
|
||||||
CATEGORIES= benchmarks net
|
CATEGORIES= benchmarks net
|
||||||
|
|
||||||
#MASTER_SITES= ftp://ftp.cup.hp.com/dist/networking/benchmarks/netperf/ \
|
HOMEPAGE= http://www.netperf.org/netperf/
|
||||||
# ftp://ftp.cup.hp.com/dist/networking/benchmarks/netperf/archive/ \
|
|
||||||
MASTER_SITES= ftp://ftp.netperf.org/netperf/archive/ \
|
|
||||||
http://ftp.sunet.se/pub/network/monitoring/netperf/ \
|
|
||||||
http://ftp.sunet.se/pub/network/monitoring/netperf/archive/
|
|
||||||
|
|
||||||
HOMEPAGE= http://www.netperf.org/netperf/NetperfPage.html
|
|
||||||
|
|
||||||
|
# "for non-commercial purposes only"; see COPYING
|
||||||
PERMIT_PACKAGE_CDROM= No
|
PERMIT_PACKAGE_CDROM= No
|
||||||
PERMIT_PACKAGE_FTP= Yes
|
PERMIT_PACKAGE_FTP= Yes
|
||||||
WANTLIB= c m
|
|
||||||
|
|
||||||
MAKE_FILE= makefile
|
WANTLIB += c m
|
||||||
MAKE_FLAGS+= CC="${CC}" CFLAGS='${CFLAGS} -DDEBUG_LOG_FILE="\"/tmp/netperf.debug\"" -DUSE_LOOPER -DDO_DNS'
|
|
||||||
|
|
||||||
USE_GROFF = Yes
|
MASTER_SITES= ftp://ftp.netperf.org/netperf/ \
|
||||||
NO_TEST= Yes
|
ftp://ftp.netperf.org/netperf/archive/
|
||||||
|
|
||||||
SHAREDIR= ${PREFIX}/share/netperf
|
AUTOCONF_VERSION= 2.67
|
||||||
SCRIPTS= arr_script snapshot_script \
|
CONFIGURE_STYLE= autoconf
|
||||||
tcp_range_script tcp_rr_script tcp_stream_script \
|
CONFIGURE_ARGS= --enable-demo
|
||||||
udp_rr_script udp_stream_script
|
SEPARATE_BUILD= Yes
|
||||||
|
|
||||||
do-install:
|
E= ${PREFIX}/share/examples/netperf
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/netperf ${PREFIX}/bin
|
|
||||||
${INSTALL_PROGRAM} ${WRKSRC}/netserver ${PREFIX}/bin
|
post-install:
|
||||||
${INSTALL_MAN} ${WRKSRC}/netperf.man ${PREFIX}/man/man1/netperf.1
|
${INSTALL_DATA_DIR} $E
|
||||||
${INSTALL_MAN} ${WRKSRC}/netserver.man ${PREFIX}/man/man1/netserver.1
|
${INSTALL_SCRIPT} ${WRKSRC}/doc/examples/*script $E
|
||||||
${INSTALL_SCRIPT_DIR} ${SHAREDIR}
|
perl -pi -e 's,(/opt/netperf2/bin|/usr/local/bin|/opt/netperf/netperf),${TRUEPREFIX}/bin,;' \
|
||||||
@for i in ${SCRIPTS}; do \
|
-e 's,^NETHOME=.*,NETHOME=${TRUEPREFIX}/bin,;' $E/*
|
||||||
${INSTALL_SCRIPT} ${WRKSRC}/$$i ${SHAREDIR}; \
|
|
||||||
done
|
|
||||||
|
|
||||||
.include <bsd.port.mk>
|
.include <bsd.port.mk>
|
||||||
|
@ -1,5 +1,2 @@
|
|||||||
MD5 (netperf-2.3.tar.gz) = 32G421441YzfgXSGNWFNMw==
|
SHA256 (netperf-2.6.0.tar.gz) = jtpao0jtnqP/2ZtFqy2GD/3eCfL2+uq2T6UvEuvhejM=
|
||||||
RMD160 (netperf-2.3.tar.gz) = neP+FKH/HRqBohQOkSbWHWN22b4=
|
SIZE (netperf-2.6.0.tar.gz) = 1308763
|
||||||
SHA1 (netperf-2.3.tar.gz) = tK6ckKk1HgJDGfi7wGSuz2oY5js=
|
|
||||||
SHA256 (netperf-2.3.tar.gz) = egrr02W46+U9eW09cB8VPSpzw3+Br9U1pNhY5DgOdwA=
|
|
||||||
SIZE (netperf-2.3.tar.gz) = 835407
|
|
||||||
|
21
benchmarks/netperf/patches/patch-configure_ac
Normal file
21
benchmarks/netperf/patches/patch-configure_ac
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
$OpenBSD: patch-configure_ac,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- configure.ac.orig Tue Jun 19 21:29:49 2012
|
||||||
|
+++ configure.ac Thu Apr 18 17:50:09 2013
|
||||||
|
@@ -699,7 +699,7 @@ case "$enable_cpuutil" in
|
||||||
|
enable_cpuutil="kstat - auto"
|
||||||
|
NETCPU_SOURCE="kstat"
|
||||||
|
;;
|
||||||
|
- *-*-freebsd[[4-8]].* | *-*-netbsd[[1-9]].* )
|
||||||
|
+ *-*-freebsd[[4-8]].* | *-*-netbsd[[1-9]].* | *-*-openbsd* )
|
||||||
|
use_cpuutil=true
|
||||||
|
AC_DEFINE([USE_SYSCTL],,[Use MumbleBSD's sysctl interface to measure CPU util.])
|
||||||
|
enable_cpuutil="sysctl - auto"
|
||||||
|
@@ -759,7 +759,7 @@ case "$enable_rtlookup" in
|
||||||
|
enable_rtlookup="rtmget - auto"
|
||||||
|
NETRTLKUP_SOURCE="rtmget"
|
||||||
|
;;
|
||||||
|
- *-*-freebsd[[4-8]].* | *-*-darwin*)
|
||||||
|
+ *-*-freebsd[[4-8]].* | *-*-darwin* | *-*-openbsd*)
|
||||||
|
use_rtlookup=true
|
||||||
|
enable_rtlookup="rtmget - auto"
|
||||||
|
NETRTLKUP_SOURCE="rtmget"
|
13
benchmarks/netperf/patches/patch-doc_examples_arr_script
Normal file
13
benchmarks/netperf/patches/patch-doc_examples_arr_script
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
$OpenBSD: patch-doc_examples_arr_script,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- doc/examples/arr_script.orig Thu Apr 18 19:10:05 2013
|
||||||
|
+++ doc/examples/arr_script Thu Apr 18 19:11:31 2013
|
||||||
|
@@ -12,8 +12,7 @@ init_parms() {
|
||||||
|
TOLERANCE=15
|
||||||
|
MAX_RETRIES=3
|
||||||
|
|
||||||
|
- NETPERF="/usr/local/netperf/netperf"
|
||||||
|
- NETPERF="./netperf"
|
||||||
|
+ NETPERF="/usr/local/bin/netperf"
|
||||||
|
|
||||||
|
NPROC_LIST=""
|
||||||
|
RR_SIZES=""
|
15
benchmarks/netperf/patches/patch-doc_netperf_texi
Normal file
15
benchmarks/netperf/patches/patch-doc_netperf_texi
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
$OpenBSD: patch-doc_netperf_texi,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- doc/netperf.texi.orig Thu Apr 18 19:26:14 2013
|
||||||
|
+++ doc/netperf.texi Thu Apr 18 19:27:51 2013
|
||||||
|
@@ -16,6 +16,11 @@ found in the file @file{COPYING} of the basic netperf
|
||||||
|
@end quotation
|
||||||
|
@end copying
|
||||||
|
|
||||||
|
+@dircategory Networking tools
|
||||||
|
+@direntry
|
||||||
|
+* netperf: (netperf). Network benchmark tool
|
||||||
|
+@end direntry
|
||||||
|
+
|
||||||
|
@titlepage
|
||||||
|
@title Care and Feeding of Netperf
|
||||||
|
@subtitle Versions 2.6.0 and Later
|
@ -1,16 +0,0 @@
|
|||||||
$OpenBSD: patch-netserver_c,v 1.1 2004/07/23 18:30:28 jakob Exp $
|
|
||||||
--- netserver.c.orig Fri Jul 23 20:23:01 2004
|
|
||||||
+++ netserver.c Fri Jul 23 20:24:52 2004
|
|
||||||
@@ -730,10 +730,12 @@ struct sockaddr name;
|
|
||||||
|
|
||||||
/* unlink(DEBUG_LOG_FILE); */
|
|
||||||
#ifndef WIN32
|
|
||||||
+if (debug) {
|
|
||||||
if ((where = fopen(DEBUG_LOG_FILE, "w")) == NULL) {
|
|
||||||
perror("netserver: debug file");
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
+}
|
|
||||||
#else
|
|
||||||
{
|
|
||||||
char FileName[MAX_PATH];
|
|
@ -1,28 +0,0 @@
|
|||||||
$OpenBSD: patch-nettest_bsd_c,v 1.1 2008/09/17 12:39:17 markus Exp $
|
|
||||||
--- nettest_bsd.c.orig Wed Sep 3 20:35:56 2008
|
|
||||||
+++ nettest_bsd.c Wed Sep 3 20:36:04 2008
|
|
||||||
@@ -4885,6 +4885,24 @@ recv_udp_stream()
|
|
||||||
send_response();
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
+
|
|
||||||
+ if (!udp_stream_request->ipaddress && !udp_stream_request->port) {
|
|
||||||
+ struct sockaddr_in temp;
|
|
||||||
+
|
|
||||||
+ bzero(&temp,sizeof(temp));
|
|
||||||
+ temp.sin_port = 0;
|
|
||||||
+ temp.sin_family = AF_INET;
|
|
||||||
+ temp.sin_addr.s_addr = 0;
|
|
||||||
+ if (bind(s_data,
|
|
||||||
+ (struct sockaddr *)&temp,
|
|
||||||
+ sizeof(struct sockaddr_in)) < 0) {
|
|
||||||
+ fprintf(where,
|
|
||||||
+ "netperf: recv_udp_stream: data socket bind failed errno %d\n",
|
|
||||||
+ errno);
|
|
||||||
+ fprintf(where," port: %d\n",ntohs(temp.sin_port));
|
|
||||||
+ fflush(where);
|
|
||||||
+ }
|
|
||||||
+ }
|
|
||||||
|
|
||||||
udp_stream_response->test_length = udp_stream_request->test_length;
|
|
||||||
|
|
13
benchmarks/netperf/patches/patch-src_dscp_c
Normal file
13
benchmarks/netperf/patches/patch-src_dscp_c
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
$OpenBSD: patch-src_dscp_c,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- src/dscp.c.orig Thu Apr 18 17:16:01 2013
|
||||||
|
+++ src/dscp.c Thu Apr 18 17:16:16 2013
|
||||||
|
@@ -52,6 +52,9 @@ const char * iptos2str(int iptos);
|
||||||
|
#if HAVE_NETINET_IN_SYSTM_H
|
||||||
|
#include <netinet/in_systm.h>
|
||||||
|
#endif
|
||||||
|
+#if HAVE_NETINET_IN_H
|
||||||
|
+#include <netinet/in.h>
|
||||||
|
+#endif
|
||||||
|
#if HAVE_NETINET_IP_H
|
||||||
|
#include <netinet/ip.h>
|
||||||
|
#endif
|
17
benchmarks/netperf/patches/patch-src_netcpu_sysctl_c
Normal file
17
benchmarks/netperf/patches/patch-src_netcpu_sysctl_c
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
$OpenBSD: patch-src_netcpu_sysctl_c,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- src/netcpu_sysctl.c.orig Thu Apr 18 17:35:34 2013
|
||||||
|
+++ src/netcpu_sysctl.c Thu Apr 18 17:41:12 2013
|
||||||
|
@@ -85,8 +85,12 @@ static void
|
||||||
|
get_cpu_time(CP_TIME_TYPE *cpu_time)
|
||||||
|
{
|
||||||
|
size_t cpu_time_len = CPUSTATES * sizeof (cpu_time[0]);
|
||||||
|
+ int mib[2];
|
||||||
|
|
||||||
|
- if (sysctlbyname("kern.cp_time", cpu_time, &cpu_time_len, NULL, 0) == -1) {
|
||||||
|
+ mib[0] = CTL_KERN;
|
||||||
|
+ mib[1] = KERN_CPTIME;
|
||||||
|
+
|
||||||
|
+ if (sysctl(mib, 2, cpu_time, &cpu_time_len, NULL, 0) == -1) {
|
||||||
|
fprintf (stderr, "Cannot get CPU time!\n");
|
||||||
|
exit (1);
|
||||||
|
}
|
16
benchmarks/netperf/patches/patch-src_netlib_c
Normal file
16
benchmarks/netperf/patches/patch-src_netlib_c
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
$OpenBSD: patch-src_netlib_c,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
|
||||||
|
- we don't support RFC3493 AI_ADDRCONFIG
|
||||||
|
|
||||||
|
--- src/netlib.c.orig Thu Apr 18 17:06:59 2013
|
||||||
|
+++ src/netlib.c Thu Apr 18 17:07:40 2013
|
||||||
|
@@ -151,6 +151,9 @@ char netlib_id[]="\
|
||||||
|
#if !defined(HAVE_GETADDRINFO) || !defined(HAVE_GETNAMEINFO)
|
||||||
|
# include "missing/getaddrinfo.h"
|
||||||
|
#endif
|
||||||
|
+#if !defined(AI_ADDRCONFIG)
|
||||||
|
+# define AI_ADDRCONFIG 0
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
|
||||||
|
#include "hist.h"
|
20
benchmarks/netperf/patches/patch-src_netserver_c
Normal file
20
benchmarks/netperf/patches/patch-src_netserver_c
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
$OpenBSD: patch-src_netserver_c,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
--- src/netserver.c.orig Thu Apr 18 17:11:28 2013
|
||||||
|
+++ src/netserver.c Thu Apr 18 17:12:01 2013
|
||||||
|
@@ -67,6 +67,8 @@ char netserver_id[]="\
|
||||||
|
# include <limits.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#include <sys/types.h>
|
||||||
|
+
|
||||||
|
#if HAVE_SYS_IPC_H
|
||||||
|
#include <sys/ipc.h>
|
||||||
|
#endif
|
||||||
|
@@ -137,7 +139,6 @@ char netserver_id[]="\
|
||||||
|
|
||||||
|
/* unconditional system includes */
|
||||||
|
|
||||||
|
-#include <sys/types.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <fcntl.h>
|
||||||
|
|
16
benchmarks/netperf/patches/patch-src_nettest_bsd_c
Normal file
16
benchmarks/netperf/patches/patch-src_nettest_bsd_c
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
$OpenBSD: patch-src_nettest_bsd_c,v 1.1 2013/04/18 18:29:20 sthen Exp $
|
||||||
|
|
||||||
|
- we don't support RFC3493 AI_ADDRCONFIG
|
||||||
|
|
||||||
|
--- src/nettest_bsd.c.orig Tue Jun 19 21:32:47 2012
|
||||||
|
+++ src/nettest_bsd.c Thu Apr 18 17:07:36 2013
|
||||||
|
@@ -140,6 +140,9 @@ char nettest_id[]="\
|
||||||
|
#if !defined(HAVE_GETADDRINFO) || !defined(HAVE_GETNAMEINFO)
|
||||||
|
# include "missing/getaddrinfo.h"
|
||||||
|
#endif
|
||||||
|
+#if !defined(AI_ADDRCONFIG)
|
||||||
|
+# define AI_ADDRCONFIG 0
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#include "netlib.h"
|
||||||
|
#include "netsh.h"
|
@ -1,13 +1,16 @@
|
|||||||
@comment $OpenBSD: PLIST,v 1.5 2004/08/06 14:37:29 espie Exp $
|
@comment $OpenBSD: PLIST,v 1.6 2013/04/18 18:29:20 sthen Exp $
|
||||||
bin/netperf
|
@bin bin/netperf
|
||||||
bin/netserver
|
@bin bin/netserver
|
||||||
|
@info info/netperf.info
|
||||||
@man man/man1/netperf.1
|
@man man/man1/netperf.1
|
||||||
@man man/man1/netserver.1
|
@man man/man1/netserver.1
|
||||||
share/netperf/
|
share/examples/netperf/
|
||||||
share/netperf/arr_script
|
share/examples/netperf/arr_script
|
||||||
share/netperf/snapshot_script
|
share/examples/netperf/packet_byte_script
|
||||||
share/netperf/tcp_range_script
|
share/examples/netperf/sctp_stream_script
|
||||||
share/netperf/tcp_rr_script
|
share/examples/netperf/snapshot_script
|
||||||
share/netperf/tcp_stream_script
|
share/examples/netperf/tcp_range_script
|
||||||
share/netperf/udp_rr_script
|
share/examples/netperf/tcp_rr_script
|
||||||
share/netperf/udp_stream_script
|
share/examples/netperf/tcp_stream_script
|
||||||
|
share/examples/netperf/udp_rr_script
|
||||||
|
share/examples/netperf/udp_stream_script
|
||||||
|
Loading…
Reference in New Issue
Block a user