poco: moved to github
[packages.git] / net / autossh / Makefile
1 #
2 # Copyright (C) 2006-2012 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:=autossh
11 PKG_VERSION:=1.4b
12 PKG_RELEASE:=6
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
15 PKG_SOURCE_URL:=http://www.harding.motd.ca/autossh/
16 PKG_MD5SUM:=8f9aa006f6f69e912d3c2f504622d6f7
17
18 include $(INCLUDE_DIR)/package.mk
19
20 define Package/autossh
21   SECTION:=net
22   CATEGORY:=Network
23   TITLE:=Autossh client
24   URL:=http://www.harding.motd.ca/autossh/
25   SUBMENU:=SSH
26 endef
27
28 define Build/Compile
29         $(call Build/Compile/Default, -f Makefile \
30                 CFLAGS="$(TARGET_CFLAGS) -Wall -D\"SSH_PATH=\\\"\$$$$(SSH)\\\"\" -D\"VER=\\\"\$$$$(VER)\\\"\"" \
31                 all \
32         )
33 endef
34
35 define Package/autossh/install
36         $(INSTALL_DIR) $(1)/usr/sbin
37         $(INSTALL_BIN) $(PKG_BUILD_DIR)/autossh $(1)/usr/sbin/
38         $(INSTALL_DIR) $(1)/etc/init.d
39         $(INSTALL_BIN) ./files/autossh.init $(1)/etc/init.d/autossh
40         $(INSTALL_DIR) $(1)/etc/config
41         $(INSTALL_DATA) ./files/autossh.config $(1)/etc/config/autossh
42         $(INSTALL_DIR) $(1)/etc/hotplug.d/iface
43         $(INSTALL_DATA) ./files/autossh.hotplug $(1)/etc/hotplug.d/iface/20-autossh
44 endef
45
46 define Package/autossh/conffiles
47 /etc/config/autossh
48 endef
49
50 $(eval $(call BuildPackage,autossh))