### this file is sourced not run
# source: james

repo=libetpan
pkgname=${repo} # for SLACKDESC

# Uncomment either section [1] master commit or [2] official release below.

hash=f8ac22aa878fb08ae774e051bc9aa59a5d8aafe4
MD5SUM=1ee7b0c7e23037f68cf121a62ec35e73
hash7=${hash#???????}; hash7=${hash%$hash7}
fetch_date=2020.04
PKGVER=1.9.4.$fetch_date

TARBALL=$pkgname-$PKGVER.tar.gz
SRC_URL=https://github.com/dinhviethoa/$repo/archive/$hash.tar.gz

PKGARCH=x86_64
PKGBUILD=1
BUNDLE=

SLACKREQ='expat openssl libbdb libcyrus-sasl' # liblockfile build-time only
SLACKDESC="$pkgname: $pkgname $PKGVER (Mail access library)
$pkgname: 
$pkgname: The purpose of this mail library is to provide a portable, efficient 
$pkgname: framework for different kinds of mail access: IMAP, SMTP, POP and 
$pkgname: NNTP.
$pkgname: 
$pkgname: https://github.com/dinhviethoa/libetpan
$pkgname: 
$pkgname: 
$pkgname: 
$pkgname: 
"

### default pkg_download
### default pkg_prepare
### default pkg_package

### build
pkg_build() {
	CONFFLAGS="$CONFFLAGS --disable-static --enable-ipv6"
	cd /tmp/libetpan* &&
	NOCONFIGURE=1 ./autogen.sh &&
	pkg_build_autoconf &&
	pkg_build_slackdesc &&

	# buggy libetpan.pc - it pulls liblockfile even if we compile it with static liblockfile
	sed -i -e 's|-llockfile||' /usr/$LIBDIR/pkgconfig/libetpan.pc
}

# vim:ft=sh:

