net/mwan3: add Makefile postinst and postrm for rpcd
[feed/packages.git] / net / mwan3 / Makefile
1 #
2 # Copyright (C) 2006-2014 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:=mwan3
11 PKG_VERSION:=2.6.1
12 PKG_RELEASE:=1
13 PKG_MAINTAINER:=Florian Eckert <fe@dev.tdt.de>
14 PKG_LICENSE:=GPLv2
15
16 include $(INCLUDE_DIR)/package.mk
17
18 define Package/mwan3
19 SECTION:=net
20 CATEGORY:=Network
21 SUBMENU:=Routing and Redirection
22 DEPENDS:=+ip +ipset +iptables +iptables-mod-conntrack-extra +iptables-mod-ipopt
23 TITLE:=Multiwan hotplug script with connection tracking support
24 MAINTAINER:=Florian Eckert <fe@dev.tdt.de>
25 PKGARCH:=all
26 endef
27
28 define Package/mwan3/description
29 Hotplug script which makes configuration of multiple WAN interfaces simple
30 and manageable. With loadbalancing/failover support for up to 250 wan
31 interfaces, connection tracking and an easy to manage traffic ruleset.
32 endef
33
34 define Package/mwan3/conffiles
35 /etc/config/mwan3
36 /etc/mwan3.user
37 endef
38
39 define Build/Compile
40 endef
41
42 define Package/mwan3/postinst
43 #!/bin/sh
44 if [ -z "$${IPKG_INSTROOT}" ]; then
45 /etc/init.d/rpcd restart
46 fi
47 exit 0
48 endef
49
50 define Package/mwan3/postrm
51 #!/bin/sh
52 if [ -z "$${IPKG_INSTROOT}" ]; then
53 /etc/init.d/rpcd restart
54 fi
55 exit 0
56 endef
57
58 define Package/mwan3/install
59 $(CP) ./files/* $(1)
60 endef
61
62 $(eval $(call BuildPackage,mwan3))