Date: Thursday, September 23, 2021 @ 20:49:49 Author: felixonmars Revision: 1022766
archrelease: copy trunk to community-staging-x86_64 Added: haskell-base-compat-batteries/repos/community-staging-x86_64/ haskell-base-compat-batteries/repos/community-staging-x86_64/PKGBUILD (from rev 1022765, haskell-base-compat-batteries/trunk/PKGBUILD) ----------+ PKGBUILD | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) Copied: haskell-base-compat-batteries/repos/community-staging-x86_64/PKGBUILD (from rev 1022765, haskell-base-compat-batteries/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2021-09-23 20:49:49 UTC (rev 1022766) @@ -0,0 +1,49 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> + +_hkgname=base-compat-batteries +pkgname=haskell-base-compat-batteries +pkgver=0.11.2 +pkgrel=148 +pkgdesc="base-compat with extra batteries" +url="https://hackage.haskell.org/package/base-compat-batteries" +license=('MIT') +arch=('x86_64') +depends=('ghc-libs' 'haskell-base-compat') +makedepends=('ghc') +checkdepends=('haskell-hspec' 'haskell-hspec-discover' 'haskell-quickcheck') +source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz) +sha512sums=('0b54b53bb762ca99cbfe82799a63f73229447325438ccae4849df676d14a4758177d9481391b628cca7921d9796ac3172ad8226b2530e151b7c59f86b82f381a') + +build() { + cd $_hkgname-$pkgver + + if (( CHECKFUNC )); then + _opts=('--enable-tests') + else + _opts=('--disable-tests') + fi + + runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \ + --prefix=/usr --docdir=/usr/share/doc/$pkgname "${_opts[@]}" \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid --ghc-option=-fllvm + runhaskell Setup build $MAKEFLAGS + 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 --show-details=direct +} + +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 +}