bridge-utils: moved to github
[packages.git] / net / rinetd / Makefile
1 #
2 # Copyright (C) 2009-2011 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=rinetd
11 PKG_VERSION:=0.62
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=rinetd.tar.gz
15 PKG_SOURCE_URL:=http://www.boutell.com/rinetd/http
16 PKG_MD5SUM:=28c78bac648971724c46f1a921154c4f
17 PKG_UNPACK=$(HOST_TAR) -C $(PKG_BUILD_DIR) --strip-components=1 -xzf $(DL_DIR)/$(PKG_SOURCE)
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/rinetd
22   SECTION:=net
23   CATEGORY:=Network
24   SUBMENU:=Routing and Redirection
25   TITLE:=rinetd - Internet Redirection Server
26   URL:=http://www.boutell.com/rinetd/
27 endef
28
29 define Package/rinetd/conffiles
30 /etc/config/rinetd
31 endef
32
33 define Package/rinetd/description
34   Rinetd redirects TCP connections from one IP address and port to another.
35   Rinetd is a single-process server which handles any number of connections
36   to the address/port pairs specified in the configuration.
37   Since rinetd runs as a single process using nonblocking I/O, it is able to
38   redirect a large number of connections without a severe impact on the
39   machine.
40 endef
41
42 define Build/Compile
43         $(MAKE) -C $(PKG_BUILD_DIR) \
44                 CC="$(TARGET_CC)" \
45                 CFLAGS="$(TARGET_CFLAGS)" \
46                 rinetd
47 endef
48
49 define Package/rinetd/install
50         $(INSTALL_DIR) $(1)/usr/sbin
51         $(INSTALL_BIN) $(PKG_BUILD_DIR)/rinetd $(1)/usr/sbin
52         $(INSTALL_DIR) $(1)/etc/config
53         $(INSTALL_CONF) ./files/rinetd.config $(1)/etc/config/rinetd
54         $(INSTALL_DIR) $(1)/etc/init.d
55         $(INSTALL_BIN) ./files/rinetd.init $(1)/etc/init.d/rinetd
56
57 endef
58
59 $(eval $(call BuildPackage,rinetd))