summaryrefslogtreecommitdiff
path: root/package/openvpn/Makefile
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2009-05-30 20:39:07 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2009-05-30 20:39:07 +0200
commitba3359722cbf8aa7b0ed39e1f81d1d74ec88fecd (patch)
tree10c726d162bc0ded85eb7aeacf8f246bd39ad63a /package/openvpn/Makefile
parentbbd610f15a71b27c955175cb98392b114717fd47 (diff)
optimize ipkg package management
- generate ipkg control file from PKG_* variables - automatically install init scripts from ./files/*.init set #PKG pkgname to set the binary package - rename FWINIT -> INIT - move postinst and conffiles meta data to ./files - update the packages to the latest upstream version - remove some unready or unused package (strongswan,..) more cleanups needed after allmodconfig
Diffstat (limited to 'package/openvpn/Makefile')
-rw-r--r--package/openvpn/Makefile42
1 files changed, 22 insertions, 20 deletions
diff --git a/package/openvpn/Makefile b/package/openvpn/Makefile
index 879882a0b..b18303d75 100644
--- a/package/openvpn/Makefile
+++ b/package/openvpn/Makefile
@@ -9,32 +9,38 @@ PKG_NAME:= openvpn
PKG_VERSION:= 2.0.9
PKG_RELEASE:= 7
PKG_MD5SUM:= 60745008b90b7dbe25fe8337c550fec6
-
-MASTER_SITES:= http://openvpn.net/release/ \
+PKG_DESCR:= Open Source VPN solution using SSL
+PKG_SECTION:= net
+PKG_DEPENDS:= kmod-tun
+PKG_URL:= http://openvpn.net
+PKG_SITES:= http://openvpn.net/release/ \
${MASTER_SITE_SOURCEFORGE:=openvpn/}
include $(TOPDIR)/mk/package.mk
-$(eval $(call PKG_template,OPENVPN,openvpn,$(PKG_VERSION)-$(PKG_RELEASE)))
-$(eval $(call PKG_template,OPENVPN_EASY_RSA,openvpn-easy-rsa,$(PKG_VERSION)-$(PKG_RELEASE)))
+ifeq ($(ADK_COMPILE_OPENVPN_WITH_OPENSSL),y)
+PKG_DEPENDS+= libopenssl
+endif
+
+ifneq ($(ADK_COMPILE_OPENVPN_WITH_LZO),y)
+PKG_DEPENDS+= liblzo
+endif
-PKG_DEPEND:="kmod-tun"
+$(eval $(call PKG_template,OPENVPN,${PKG_NAME},$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+$(eval $(call PKG_template,OPENVPN_EASY_RSA,openvpn-easy-rsa,$(PKG_VERSION)-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
ifneq ($(ADK_COMPILE_OPENVPN_WITH_OPENSSL),y)
DISABLE_OPENSSL:=--disable-ssl --disable-crypto
-else
-PKG_DEPEND+=", libopenssl"
endif
ifneq ($(ADK_COMPILE_OPENVPN_WITH_LZO),y)
DISABLE_LZO:=--disable-lzo
-else
-PKG_DEPEND+=", liblzo"
endif
ifneq ($(ADK_COMPILE_OPENVPN_WITH_SERVER),y)
DISABLE_SERVER:=--disable-server
endif
+
ifneq ($(ADK_COMPILE_OPENVPN_WITH_HTTP),y)
DISABLE_HTTP:=--disable-http
endif
@@ -67,20 +73,16 @@ INSTALL_STYLE= auto
post-install:
# main package
- install -d -m0755 $(IDIR_OPENVPN)/usr/sbin
- $(CP) $(WRKINST)/usr/sbin/openvpn $(IDIR_OPENVPN)/usr/sbin/
- install -d -m0755 $(IDIR_OPENVPN)/etc/init.d
- $(CP) ./files/openvpn.init $(IDIR_OPENVPN)/etc/init.d/openvpn
- install -d -m0755 $(IDIR_OPENVPN)/etc/openvpn
+ ${INSTALL_DIR} $(IDIR_OPENVPN)/usr/sbin $(IDIR_OPENVPN)/etc/openvpn
+ ${INSTALL_BIN} $(WRKINST)/usr/sbin/openvpn $(IDIR_OPENVPN)/usr/sbin/
$(CP) ./files/openvpn.conf $(IDIR_OPENVPN)/etc/openvpn/
- echo "Depends: $(PKG_DEPEND)" >> $(IDIR_OPENVPN)/CONTROL/control
# subpackage easy-rsa
- install -d -m0755 $(IDIR_OPENVPN_EASY_RSA)/usr/sbin
- install -d -m0755 $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/keys
+ ${INSTALL_DIR} $(IDIR_OPENVPN_EASY_RSA)/usr/sbin $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/keys
touch $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/keys/index.txt
$(CP) ./files/serial $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/keys
- $(CP) $(WRKBUILD)/easy-rsa/2.0/{build-*,clean-all,inherit-inter,list-crl,pkitool,revoke-full,sign-req,whichopensslcnf} $(IDIR_OPENVPN_EASY_RSA)/usr/sbin
- install -m 0644 $(WRKBUILD)/easy-rsa/2.0/openssl.cnf $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/openssl.cnf
- install -m 0644 $(WRKBUILD)/easy-rsa/2.0/vars $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/vars
+ $(CP) $(WRKBUILD)/easy-rsa/2.0/{build-*,clean-all,inherit-inter,list-crl,pkitool,revoke-full,sign-req,whichopensslcnf} \
+ $(IDIR_OPENVPN_EASY_RSA)/usr/sbin
+ ${INSTALL_DATA} $(WRKBUILD)/easy-rsa/2.0/openssl.cnf $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/openssl.cnf
+ ${INSTALL_DATA} $(WRKBUILD)/easy-rsa/2.0/vars $(IDIR_OPENVPN_EASY_RSA)/etc/easy-rsa/vars
include ${TOPDIR}/mk/pkg-bottom.mk