Add aprx (#3727)
[openwrt/svn-archive/archive.git] / net / net-tools / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=net-tools
12 PKG_VERSION:=1.60
13 PKG_RELEASE:=1
14
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/
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
20
21 include $(INCLUDE_DIR)/package.mk
22
23 define Package/net-tools
24 SECTION:=net
25 CATEGORY:=Network
26 TITLE:=Original net-tools
27 URL:=http://www.tazenda.demon.co.uk/phil/net-tools/
28 endef
29
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,
33 route and slattach.
34 endef
35
36 define Build/Compile
37 $(MAKE) -C $(PKG_BUILD_DIR) \
38 CC="$(TARGET_CC)" \
39 COPTS="$(TARGET_CFLAGS)"
40 endef
41
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/
57 endef
58
59 # FIXME: check if commands are really provided by busybox (busybox | grep <name>)
60 define Package/net-tools/postrm
61 #!/bin/sh
62 ln -sf busybox $${IPKG_INSTROOT}/bin/netstat
63 ln -sf ../bin/busybox $${IPKG_INSTROOT}/sbin/route
64 endef
65
66 $(eval $(call BuildPackage,net-tools))