Date: Wednesday, January 8, 2020 @ 10:14:25 Author: felixonmars Revision: 550172
archrelease: copy trunk to community-staging-x86_64 Added: haskell-hspec-wai/repos/community-staging-x86_64/ haskell-hspec-wai/repos/community-staging-x86_64/PKGBUILD (from rev 550171, haskell-hspec-wai/trunk/PKGBUILD) ----------+ PKGBUILD | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) Copied: haskell-hspec-wai/repos/community-staging-x86_64/PKGBUILD (from rev 550171, haskell-hspec-wai/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2020-01-08 10:14:25 UTC (rev 550172) @@ -0,0 +1,45 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Arch Haskell Team <arch-hask...@haskell.org> + +_hkgname=hspec-wai +pkgname=haskell-hspec-wai +pkgver=0.9.2 +pkgrel=90 +pkgdesc="Experimental Hspec support for testing WAI applications" +url="https://github.com/hspec/hspec-wai" +license=("MIT") +arch=('x86_64') +depends=('ghc-libs' 'haskell-quickcheck' 'haskell-base-compat' 'haskell-case-insensitive' + 'haskell-hspec' 'haskell-hspec-core' 'haskell-hspec-expectations' 'haskell-http-types' + 'haskell-wai' 'haskell-wai-extra') +makedepends=('ghc') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('a3a6a24fc948d924f60f55da7d133446c57549f9967a47adafa8f8df057370472348f9413477a4f78f5068233a6b103396810e611161735ec75f87b6d9673edb') + +build() { + cd $_hkgname-$pkgver + + runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \ + --prefix=/usr --docdir=/usr/share/doc/$pkgname --enable-tests \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid + runhaskell Setup build + runhaskell Setup register --gen-script + runhaskell Setup unregister --gen-script + sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh + sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh +} + +check() { + cd $_hkgname-$pkgver + runhaskell Setup test +} + +package() { + cd $_hkgname-$pkgver + + install -D -m744 register.sh "$pkgdir"/usr/share/haskell/register/$pkgname.sh + install -D -m744 unregister.sh "$pkgdir"/usr/share/haskell/unregister/$pkgname.sh + runhaskell Setup copy --destdir="$pkgdir" + install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE" +}