2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR)/rules.mk
15 PKG_MD5SUM:=888774accab40217dde927e21979c165
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
17 PKG_SOURCE_URL:=http://www.tazenda.demon.co.uk/phil/net-tools/
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
21 include $(INCLUDE_DIR)/package.mk
23 define Package/net-tools
26 TITLE:=Original net-tools
27 URL:=http://www.tazenda.demon.co.uk/phil/net-tools/
30 define Package/net-tools/description
31 The net-tools package contains usual linux commands:
32 arp, hostname, ipmaddr, iptunnel, mii-tool, nameif, netstat, plipconfig, rarp,
37 $(MAKE) -C $(PKG_BUILD_DIR) \
39 COPTS="$(TARGET_CFLAGS)"
42 define Package/net-tools/install
43 $(INSTALL_DIR) $(1)/bin
44 $(INSTALL_BIN) $(PKG_BUILD_DIR)/netstat $(1)/bin/
45 $(INSTALL_DIR) $(1)/sbin
46 $(INSTALL_BIN) $(PKG_BUILD_DIR)/route $(1)/sbin/
47 $(INSTALL_DIR) $(1)/usr/sbin
48 $(INSTALL_BIN) $(PKG_BUILD_DIR)/arp $(1)/usr/sbin/
49 $(INSTALL_BIN) $(PKG_BUILD_DIR)/hostname $(1)/usr/sbin/
50 $(INSTALL_BIN) $(PKG_BUILD_DIR)/ipmaddr $(1)/usr/sbin/
51 $(INSTALL_BIN) $(PKG_BUILD_DIR)/iptunnel $(1)/usr/sbin/
52 $(INSTALL_BIN) $(PKG_BUILD_DIR)/mii-tool $(1)/usr/sbin/
53 $(INSTALL_BIN) $(PKG_BUILD_DIR)/nameif $(1)/usr/sbin/
54 $(INSTALL_BIN) $(PKG_BUILD_DIR)/plipconfig $(1)/usr/sbin/
55 $(INSTALL_BIN) $(PKG_BUILD_DIR)/rarp $(1)/usr/sbin/
56 $(INSTALL_BIN) $(PKG_BUILD_DIR)/slattach $(1)/usr/sbin/
59 # FIXME: check if commands are really provided by busybox (busybox | grep <name>)
60 define Package/net-tools/postrm
62 ln -sf busybox $${IPKG_INSTROOT}/bin/netstat
63 ln -sf ../bin/busybox $${IPKG_INSTROOT}/sbin/route
66 $(eval $(call BuildPackage,net-tools))