[packages] add vpzone - A flexible multipurpose layer 3 VPN daemon
authorNicolas Thill <nico@openwrt.org>
Tue, 1 Jun 2010 09:08:57 +0000 (09:08 +0000)
committerNicolas Thill <nico@openwrt.org>
Tue, 1 Jun 2010 09:08:57 +0000 (09:08 +0000)
SVN-Revision: 21646

net/vpzone/Makefile [new file with mode: 0644]
net/vpzone/files/vpzone.conf [new file with mode: 0644]
net/vpzone/files/vpzone.init [new file with mode: 0644]
net/vpzone/patches/001-no_werror.patch [new file with mode: 0644]
net/vpzone/patches/002-ipv6_inc_fix.patch [new file with mode: 0644]

diff --git a/net/vpzone/Makefile b/net/vpzone/Makefile
new file mode 100644 (file)
index 0000000..cf7641a
--- /dev/null
@@ -0,0 +1,47 @@
+#
+# Copyright (C) 2010 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=vpzone
+PKG_VERSION:=0.1.2
+PKG_RELEASE:=1
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
+PKG_SOURCE_URL:=@SF/vpzone
+PKG_MD5SUM:=9b8a142a217f69ece0163b2026dc8585
+
+PKG_FIXUP:=libtool
+PKG_INSTALL:=1
+
+include $(INCLUDE_DIR)/package.mk
+
+define Package/vpzone
+  CATEGORY:=Network
+  SECTION:=net
+  SUBMENU:=VPN
+  TITLE:=A flexible multipurpose layer 3 VPN daemon
+  URL:=http://vpzone.sourceforge.net/
+  DEPENDS:=+libcares +libevent +libgnutls +kmod-ipv6
+endef
+
+define Package/vpzone/conffiles
+/etc/vpzone/vpzone.conf
+endef
+
+define Package/vpzone/install
+       $(INSTALL_DIR) $(1)/usr/bin
+       $(CP) $(PKG_INSTALL_DIR)/usr/bin/vpzone $(1)/usr/bin/
+       $(INSTALL_DIR) $(1)/usr/lib/vpzone
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/vpzone/*.so $(1)/usr/lib/vpzone/
+       $(INSTALL_DIR) $(1)/etc/init.d
+       $(INSTALL_BIN) ./files/vpzone.init $(1)/etc/init.d/vpzone
+       $(INSTALL_DIR) $(1)/etc/vpzone
+       $(INSTALL_CONF) ./files/vpzone.conf $(1)/etc/vpzone/
+endef
+
+$(eval $(call BuildPackage,vpzone))
diff --git a/net/vpzone/files/vpzone.conf b/net/vpzone/files/vpzone.conf
new file mode 100644 (file)
index 0000000..9a7940b
--- /dev/null
@@ -0,0 +1,28 @@
+# vpzone.conf - vpzone configuration file
+
+log-file /var/log/vpzone.log
+log-level 3
+
+load tcp # mandatory
+#load udp
+#load gnutls
+#load babeld
+#load simple_vp
+#load manage
+
+device vpz0
+
+dev-ip fe80::8c7:3280:8ae3:6882/64 # mandatory link-local ip address
+dev-ip 2001:218:420::45/64 # mandatory VPN ip address
+
+group nogroup
+user nobody
+
+#server tcp:ssl:0.0.0.0
+
+#manage secret
+
+#cafile /etc/vpzone/ca.crt
+#crlfile /etc/vpzone/crl.pem
+#dhfile /etc/vpzone/dh.pem
+#certnkey-files /etc/vpzone/cert.crt /etc/vpzone/keyfile
diff --git a/net/vpzone/files/vpzone.init b/net/vpzone/files/vpzone.init
new file mode 100644 (file)
index 0000000..8007ff7
--- /dev/null
@@ -0,0 +1,13 @@
+#!/bin/sh /etc/rc.common
+
+START=50
+DAEMON=vpzone
+PID_F=/var/run/$DAEMON.pid
+
+start() {
+       start-stop-daemon -p $PID_F -x $DAEMON -S -b -m
+}
+
+stop() {
+       start-stop-daemon -p $PID_F -x $DAEMON -K
+}
diff --git a/net/vpzone/patches/001-no_werror.patch b/net/vpzone/patches/001-no_werror.patch
new file mode 100644 (file)
index 0000000..514bc79
--- /dev/null
@@ -0,0 +1,22 @@
+--- a/configure
++++ b/configure
+@@ -14776,7 +14776,7 @@ fi
+-VPZONE_CFLAGS="-std=gnu99 -Wall -Werror -Wextra -fdiagnostics-show-option ${DEV_CFLAGS}"
++VPZONE_CFLAGS="-std=gnu99 -Wall -Wextra -fdiagnostics-show-option ${DEV_CFLAGS}"
+ VPZONE_LDFLAGS="-ldl -levent -lcares"
+--- a/configure.ac
++++ b/configure.ac
+@@ -65,7 +65,7 @@ dnl # #######################
+ dnl Compiler and Linker flags
+ dnl # #######################
+-VPZONE_CFLAGS="-std=gnu99 -Wall -Werror -Wextra -fdiagnostics-show-option ${DEV_CFLAGS}"
++VPZONE_CFLAGS="-std=gnu99 -Wall -Wextra -fdiagnostics-show-option ${DEV_CFLAGS}"
+ AC_SUBST(VPZONE_CFLAGS)
+ VPZONE_LDFLAGS="-ldl -levent -lcares"
+ AC_SUBST(VPZONE_LDFLAGS)
diff --git a/net/vpzone/patches/002-ipv6_inc_fix.patch b/net/vpzone/patches/002-ipv6_inc_fix.patch
new file mode 100644 (file)
index 0000000..d062bcf
--- /dev/null
@@ -0,0 +1,11 @@
+--- a/src/include/iface.h
++++ b/src/include/iface.h
+@@ -36,7 +36,7 @@
+ /*A temporary and *dirty* fix against bad headers 
+ on some system (<linux/ipv6.h> conflicting with <netinet/in.h>)...*/
+ #include <linux/types.h>
+-#include <linux/in6.h>
++/*#include <linux/in6.h>*/
+ struct in6_ifreq 
+ {
+       struct in6_addr ifr6_addr;