e09251fa722f988bf370eaf77fc923d01a3e1d8a
[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 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=vtun
12 PKG_VERSION:=2.6
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=@SF/vtun
17 PKG_MD5SUM:=309534fd03c5d13a19c43916f61f4bbf
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/vtun
25   SECTION:=net
26   CATEGORY:=Network
27   DEPENDS:=+kmod-tun +liblzo +libopenssl +zlib
28   TITLE:=VPN tunneling daemon
29   URL:=http://vtun.sourceforge.net
30 endef
31
32 define Package/vtun/conffiles
33 /etc/vtund.conf
34 endef
35
36 define Build/Configure
37         $(call Build/Configure/Default, \
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))