1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
2 # Contributor: Arch Haskell Team <arch-haskell@haskell.org>
5 pkgname=haskell-monad-control
8 pkgdesc="Lift control operations, like exception catching, through monad transformers"
9 url="https://github.com/basvandijk/monad-control"
12 depends=('ghc-libs' 'haskell-transformers-base' 'haskell-transformers-compat')
13 makedepends=('ghc' 'uusi')
14 source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz")
15 sha512sums=('b82ac2d3b2ab1892f79bab1341c9ff17ea89b988438cfd40c246f5ffe4560cb2b77e4a1ed1aa9dc2bb64644b9d6da76eda7b40acf8cc34bb03e77b18127e93a1')
25 runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \
26 --prefix=/usr --docdir=/usr/share/doc/$pkgname --datasubdir=$pkgname --enable-tests \
27 --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid --ghc-option=-fllvm
28 runhaskell Setup build $MAKEFLAGS
29 runhaskell Setup register --gen-script
30 runhaskell Setup unregister --gen-script
31 sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh
32 sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
38 install -D -m744 register.sh "$pkgdir"/usr/share/haskell/register/$pkgname.sh
39 install -D -m744 unregister.sh "$pkgdir"/usr/share/haskell/unregister/$pkgname.sh
40 runhaskell Setup copy --destdir="$pkgdir"
41 install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
42 rm -f "$pkgdir"/usr/share/doc/$pkgname/LICENSE