### this file is sourced not run
PKGVER=5.28
PKGBUILD=1
PKGARCH=x86_64

# source: post BLFS 7.8 2016-01-06
TARBALL=stunnel-$PKGVER.tar.gz
MD5SUM=2c39ae0be771f91bf5b0205beafddca6
SRC_URL=https://www.stunnel.org/downloads/$TARBALL
BUNDLE=

SLACKREQ=openssl
SLACKDESC="stunnel: stunnel $PKGVER (SSL Tunnel tool)  
stunnel:  
stunnel: The stunnel package contains a program that allows you to encrypt 
stunnel: arbitrary TCP connections inside SSL (Secure Sockets Layer) so you 
stunnel: can easily communicate with clients over secure channels. stunnel can 
stunnel: be used to add SSL functionality to commonly used Inetd daemons like 
stunnel: POP-2, POP-3, and IMAP servers, to standalone daemons like NNTP, SMTP 
stunnel: and HTTP, and in tunneling PPP over network sockets without changes 
stunnel: to the server package source code.  
stunnel: 
stunnel: 
"

### default pkg_download
### prepare
pkg_prepare() {
	pkg_prepare_default &&
	mkdir -p etc/stunnel &&
	cp tmp/pkg/stunnel.pem tmp/pkg/stunnel.conf-sample etc/stunnel
}

### default pkg_package
### build
pkg_build() {
#	return 1
	CONFFLAGS="$CONFFLAGS --disable-libwrap --enable-ipv6 --disable-fips --disable-systemd"
	MAKEINSTALLFLAGS="$MAKEINSTALLFLAGS docdir=/usr/share/doc/stunnel-$PKGVER"
	pkg_build_autoconf &&
	pkg_build_slackdesc
}
