# -*- shell-script -*- # # Maintainer: Erich Eckner # Contributor: Adrian C. pkgname=alpine pkgver=2.21.999.r30.7346da5 _commit=${pkgver##*.} pkgrel=1 arch=("i686" "x86_64") pkgdesc="Apache licensed PINE mail user agent" url="http://alpine.freeiz.com" license=("APACHE") depends=("libldap" "krb5" "gettext") makedepends=('openssl' 'git') optdepends=("aspell: for spell-checking support" "hunspell: for spell-checking support" "topal: glue program that links GnuPG and alpine") provides=("pine") conflicts=("pine" "re-alpine") replaces=("pine") options=("!makeflags") source=("alpine::git://repo.or.cz/alpine.git#commit=${_commit}") sha512sums=('SKIP') prepare() { sed -i ' /^\s*ERR_free_strings();\s*$/d /^\s*EVP_cleanup();\s*$/d ' "${srcdir}/${pkgname}/pith/smime.c" } pkgver() { cd "${srcdir}/${pkgname}" _rev=$( git rev-parse --short master ) _pkgver=$( git archive "${_rev}" -- Makefile | \ tar -Ox | \ sed -n ' /^VERSION\s*=/!d = s/^.*=\s*// p ' | \ sed ' N s/\n/ / ' ) _line=${_pkgver% *} _pkgver=${_pkgver#* } _rev_count=$( git rev-list "${_rev}" ^$(git blame -L${_line},${_line} "${_rev}" -- Makefile | cut -d' ' -f1) --count ) printf '%s.r%s.%s' \ "${_pkgver}" \ "${_rev_count}" \ "${_rev}" } build() { cd "${srcdir}/${pkgname}" # Configure Alpine ./configure --prefix=/usr \ --without-passfile --without-tcl --disable-shared \ --with-system-pinerc=/etc/${pkgname}.d/pine.conf \ --with-system-fixed-pinerc=/etc/${pkgname}.d/pine.conf.fixed # Build Alpine make } package() { cd "${srcdir}/${pkgname}" # Install Alpine make DESTDIR="${pkgdir}" install }