0d74fd148e0d246f9b511ad2e8d703ec03daaec4
[packages.git] / net / vtun / 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
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=vtun
11 PKG_VERSION:=3.0.1
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=@SF/vtun
16 PKG_MD5SUM:=c342ffe77055d4248a38f0b380f28c1b
17
18 include $(INCLUDE_DIR)/package.mk
19
20 define Package/vtun
21   SECTION:=net
22   CATEGORY:=Network
23   DEPENDS:=+kmod-tun +liblzo +libopenssl +zlib
24   TITLE:=VPN tunneling daemon
25   URL:=http://vtun.sourceforge.net
26   SUBMENU:=VPN
27 endef
28
29 define Package/vtun/conffiles
30 /etc/vtund.conf
31 endef
32
33 define Build/Configure
34         $(call Build/Configure/Default, \
35                 --with-lzo-headers="$(STAGING_DIR)/usr/include/lzo" \
36                 --with-lzo-lib="$(STAGING_DIR)/usr/lib/" \
37                 --with-ssl-headers="$(STAGING_DIR)/usr/include/openssl" \
38                 , \
39                 LIBS="-L$(STAGING_DIR)/usr/lib" \
40                 BLOWFISH_HDR_DIR="$(STAGING_DIR)/usr/include/openssl" \
41                 LZO_HDR_DIR="$(STAGING_DIR)/usr/include/lzo" \
42                 SSL_HDR_DIR="$(STAGING_DIR)/usr/include/openssl" \
43         )
44 endef
45
46 define Build/Compile    
47         $(call Build/Compile/Default,vtund)
48 endef
49
50 define Package/vtun/install     
51         $(INSTALL_DIR) $(1)/etc
52         $(INSTALL_CONF) $(PKG_BUILD_DIR)/vtund.conf $(1)/etc/
53         $(INSTALL_DIR) $(1)/usr/sbin
54         $(INSTALL_BIN) $(PKG_BUILD_DIR)/vtund $(1)/usr/sbin/
55 endef
56
57 $(eval $(call BuildPackage,vtun))