mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-20 06:08:08 +00:00
add netperf package (thanks to Janos)
SVN-Revision: 2870
This commit is contained in:
parent
19c1532868
commit
29e35fc2ea
@ -91,6 +91,7 @@ source "package/mini_httpd/Config.in"
|
|||||||
source "package/mini_sendmail/Config.in"
|
source "package/mini_sendmail/Config.in"
|
||||||
source "package/mtr/Config.in"
|
source "package/mtr/Config.in"
|
||||||
source "package/net-snmp/Config.in"
|
source "package/net-snmp/Config.in"
|
||||||
|
source "package/netperf/Config.in"
|
||||||
source "package/netstat-nat/Config.in"
|
source "package/netstat-nat/Config.in"
|
||||||
source "package/nfs-server/Config.in"
|
source "package/nfs-server/Config.in"
|
||||||
source "package/nmap/Config.in"
|
source "package/nmap/Config.in"
|
||||||
|
@ -138,6 +138,7 @@ package-$(BR2_PACKAGE_NANO) += nano
|
|||||||
package-$(BR2_COMPILE_NCURSES) += ncurses
|
package-$(BR2_COMPILE_NCURSES) += ncurses
|
||||||
package-$(BR2_COMPILE_NDISC6) += ndisc
|
package-$(BR2_COMPILE_NDISC6) += ndisc
|
||||||
package-$(BR2_COMPILE_NET_SNMP) += net-snmp
|
package-$(BR2_COMPILE_NET_SNMP) += net-snmp
|
||||||
|
package-$(BR2_PACKAGE_NETPERF) += netperf
|
||||||
package-$(BR2_PACKAGE_NETSTAT_NAT) += netstat-nat
|
package-$(BR2_PACKAGE_NETSTAT_NAT) += netstat-nat
|
||||||
package-$(BR2_PACKAGE_NFS_SERVER) += nfs-server
|
package-$(BR2_PACKAGE_NFS_SERVER) += nfs-server
|
||||||
package-$(BR2_PACKAGE_NMAP) += nmap
|
package-$(BR2_PACKAGE_NMAP) += nmap
|
||||||
|
6
openwrt/package/netperf/Config.in
Normal file
6
openwrt/package/netperf/Config.in
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
config BR2_PACKAGE_NETPERF
|
||||||
|
prompt "netperf........................... network performance measurement tool"
|
||||||
|
tristate
|
||||||
|
default m if CONFIG_DEVEL
|
||||||
|
help
|
||||||
|
Program and service to do network performance measurement.
|
40
openwrt/package/netperf/Makefile
Normal file
40
openwrt/package/netperf/Makefile
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
# $Id$
|
||||||
|
|
||||||
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
|
PKG_NAME:=netperf
|
||||||
|
PKG_VERSION:=2.3pl1
|
||||||
|
PKG_RELEASE:=1
|
||||||
|
PKG_MD5SUM:=b74314d78af31cb13516fb9a372d2e86
|
||||||
|
|
||||||
|
PKG_SOURCE_URL:=ftp://ftp.netperf.org/netperf/archive/ \
|
||||||
|
ftp://ftp.cup.hp.com/dist/networking/benchmarks/netperf/
|
||||||
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
|
PKG_CAT:=zcat
|
||||||
|
|
||||||
|
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||||
|
|
||||||
|
include $(TOPDIR)/package/rules.mk
|
||||||
|
|
||||||
|
$(eval $(call PKG_template,NETPERF,netperf,$(PKG_VERSION)$(PKG_RELEASE),$(ARCH)))
|
||||||
|
|
||||||
|
$(PKG_BUILD_DIR)/.configured:
|
||||||
|
touch $@
|
||||||
|
|
||||||
|
$(PKG_BUILD_DIR)/.built:
|
||||||
|
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||||
|
TARGET_NETPERF_HOME="/etc/netperf.conf" \
|
||||||
|
TARGET_CC=$(TARGET_CROSS)gcc \
|
||||||
|
TARGET_CFLAGS="$(TARGET_CFLAGS)" \
|
||||||
|
TARGET_LIBS="" \
|
||||||
|
all
|
||||||
|
touch $@
|
||||||
|
|
||||||
|
$(IPKG_NETPERF):
|
||||||
|
install -d -m0755 $(IDIR_NETPERF)/etc/init.d
|
||||||
|
install -m0755 ./files/netserver.init $(IDIR_NETPERF)/etc/init.d/S51netserver
|
||||||
|
install -d -m0755 $(IDIR_NETPERF)/usr/bin
|
||||||
|
install -m0755 $(PKG_BUILD_DIR)/netperf $(IDIR_NETPERF)/usr/bin/
|
||||||
|
install -m0755 $(PKG_BUILD_DIR)/netserver $(IDIR_NETPERF)/usr/bin/
|
||||||
|
$(RSTRIP) $(IDIR_NETPERF)
|
||||||
|
$(IPKG_BUILD) $(IDIR_NETPERF) $(PACKAGE_DIR)
|
3
openwrt/package/netperf/files/netserver.init
Normal file
3
openwrt/package/netperf/files/netserver.init
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
test -n "$FAILSAFE" && exit
|
||||||
|
/usr/bin/netserver
|
9
openwrt/package/netperf/ipkg/netperf.control
Normal file
9
openwrt/package/netperf/ipkg/netperf.control
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
Package: netperf
|
||||||
|
Priority: optional
|
||||||
|
Version: 2.3pl1
|
||||||
|
Section: network
|
||||||
|
Architecture: mipsel
|
||||||
|
Maintainer: Barnabas Kalman <barnik@vescont.com>
|
||||||
|
Source: ftp://ftp.cup.hp.com/dist/networking/benchmarks/
|
||||||
|
Description: Program and service to do network performance measurement.
|
||||||
|
|
@ -0,0 +1,39 @@
|
|||||||
|
--- netperf-2.3pl1.orig/makefile 2004-09-21 23:33:40.000000000 +0200
|
||||||
|
+++ netperf-2.3pl1/makefile 2005-12-30 15:35:08.924238576 +0100
|
||||||
|
@@ -15,8 +15,7 @@
|
||||||
|
# for the rest of the world, it is probably better to put the binaries
|
||||||
|
# in /usr/local/netperf or /opt/netperf
|
||||||
|
#
|
||||||
|
-#NETPERF_HOME = /usr/local/netperf
|
||||||
|
-NETPERF_HOME = /opt/netperf
|
||||||
|
+NETPERF_HOME = $(TARGET_NETPERF_HOME)
|
||||||
|
|
||||||
|
# The compiler on your system might be somewhere else, and/or have
|
||||||
|
# a different name.
|
||||||
|
@@ -40,7 +39,7 @@
|
||||||
|
# You may safely ignore that warning.
|
||||||
|
#
|
||||||
|
|
||||||
|
-CC = cc
|
||||||
|
+CC = $(TARGET_CC)
|
||||||
|
|
||||||
|
# Adding flags to CFLAGS enables some non-mainline features. For
|
||||||
|
# more information, please consult the source code.
|
||||||
|
@@ -113,7 +112,7 @@
|
||||||
|
# netserver via the netperf command line with -T
|
||||||
|
|
||||||
|
LOG_FILE=DEBUG_LOG_FILE="\"/tmp/netperf.debug\""
|
||||||
|
-CFLAGS = -O -D$(LOG_FILE) -DNEED_MAKEFILE_EDIT
|
||||||
|
+CFLAGS = -D$(LOG_FILE) $(TARGET_CFLAGS)
|
||||||
|
|
||||||
|
# Some platforms, and some options, require additional libraries.
|
||||||
|
# you can add to the "LIBS =" line to accomplish this. if you find
|
||||||
|
@@ -136,7 +135,7 @@
|
||||||
|
# -lresolv - required for -DDO_DNS on RedHat 7.1
|
||||||
|
# -lsocket -lbind - required for Zeta OS
|
||||||
|
|
||||||
|
-LIBS= -lm
|
||||||
|
+LIBS= -lm $(TARGET_LIBS)
|
||||||
|
|
||||||
|
# ---------------------------------------------------------------
|
||||||
|
# it should not be the case that anything below this line needs to
|
Loading…
Reference in New Issue
Block a user