netperf: update 2.3pl1 > 2.4.3 (#2180)

git-svn-id: svn://svn.openwrt.org/openwrt/packages@8397 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
olli 2007-08-11 15:46:14 +00:00
parent 4c40257271
commit 781064c798
2 changed files with 17 additions and 59 deletions

View File

@ -9,16 +9,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=netperf
PKG_VERSION:=2.3pl1
PKG_RELEASE:=1
PKG_VERSION:=2.4.3
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=ftp://ftp.netperf.org/netperf/archive/ \
ftp://ftp.cup.hp.com/dist/networking/benchmarks/netperf/
PKG_MD5SUM:=b74314d78af31cb13516fb9a372d2e86
PKG_CAT:=zcat
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_URL:=ftp://ftp.netperf.org/netperf/
PKG_MD5SUM:=391a0d98954c72a6ad7f08b8a115e1ce
include $(INCLUDE_DIR)/package.mk
@ -29,21 +25,22 @@ define Package/netperf
URL:=http://www.netperf.org/
endef
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
TARGET_NETPERF_HOME="/etc/netperf.conf" \
TARGET_CC="$(TARGET_CROSS)gcc" \
TARGET_CFLAGS="$(TARGET_CFLAGS)" \
TARGET_LIBS="" \
all
endef
define Package/netperf/install
define Package/netperf/install
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/netserver.init $(1)/etc/init.d/netserver
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/netperf $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/netserver $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/netperf $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/netserver $(1)/usr/bin/
$(INSTALL_DIR) $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/arr_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/packet_byte_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/sctp_stream_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/snapshot_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/tcp_range_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/tcp_rr_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/tcp_stream_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/udp_rr_script $(1)/lib/netperf
$(INSTALL_BIN) $(PKG_BUILD_DIR)/doc/examples/udp_stream_script $(1)/lib/netperf
endef
$(eval $(call BuildPackage,netperf))

View File

@ -1,39 +0,0 @@
--- 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