net/stunnel: Update to 5.38
[feed/packages.git] / net / stunnel / Makefile
1 #
2 # Copyright (C) 2006-2014 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:=stunnel
11 PKG_VERSION:=5.38
12 PKG_RELEASE:=1
13
14 PKG_LICENSE:=GPL-2.0+
15 PKG_MAINTAINER:=Daniel Engberg <daniel.engberg.lists@pyret.net>
16 PKG_LICENSE_FILES:=COPYING COPYRIGHT.GPL
17
18 PKG_SOURCE_URL:= \
19 http://ftp.nluug.nl/pub/networking/stunnel/ \
20 http://www.usenix.org.uk/mirrors/stunnel/
21 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
22 PKG_MD5SUM:=09ada29ba1683ab1fd1f31d7bed8305127a0876537e836a40cb83851da034fd5
23
24 PKG_FIXUP:=autoreconf
25 PKG_INSTALL:=1
26
27 include $(INCLUDE_DIR)/package.mk
28
29 define Package/stunnel
30 SECTION:=net
31 CATEGORY:=Network
32 DEPENDS:=+libopenssl +zlib +libpthread
33 TITLE:=SSL TCP Wrapper
34 URL:=http://www.stunnel.org/
35 endef
36
37 define Package/stunnel/description
38 Stunnel is a program that allows you to encrypt arbitrary TCP
39 connections inside SSL (Secure Sockets Layer) available on both Unix
40 and Windows. Stunnel can allow you to secure non-SSL aware daemons and
41 protocols (like POP, IMAP, LDAP, etc) by having Stunnel provide the
42 encryption, requiring no changes to the daemon's code.
43 endef
44
45 define Package/stunnel/conffiles
46 /etc/stunnel/stunnel.conf
47 endef
48
49
50 CONFIGURE_ARGS+= \
51 --with-random=/dev/urandom \
52 --with-threads=pthread \
53 --with-ssl=$(STAGING_DIR)/usr \
54 --disable-libwrap \
55 --disable-systemd
56
57 ifeq ($(CONFIG_IPV6),n)
58 CONFIGURE_ARGS+= \
59 --disable-ipv6
60 endif
61
62 define Build/Compile
63 mkdir -p $(PKG_INSTALL_DIR)/etc/stunnel
64 echo '#dummy' > $(PKG_INSTALL_DIR)/etc/stunnel/stunnel.pem
65 $(call Build/Compile/Default)
66 endef
67
68 define Package/stunnel/install
69 $(INSTALL_DIR) $(1)/usr/bin
70 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/stunnel $(1)/usr/bin/
71 $(INSTALL_DIR) $(1)/usr/lib/stunnel
72 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/stunnel/libstunnel.so $(1)/usr/lib/stunnel/
73 $(INSTALL_DIR) $(1)/etc/stunnel
74 $(INSTALL_CONF) ./files/stunnel.conf $(1)/etc/stunnel/stunnel.conf
75 $(INSTALL_DIR) $(1)/etc/init.d
76 $(INSTALL_BIN) ./files/stunnel.init $(1)/etc/init.d/stunnel
77 endef
78
79 $(eval $(call BuildPackage,stunnel))