[arch-commits] Commit in haskell-base-compat-batteries/repos (2 files)

Felix Yan felixonmars at archlinux.org
Sun Dec 29 23:26:19 UTC 2019


    Date: Sunday, December 29, 2019 @ 23:26:19
  Author: felixonmars
Revision: 544065

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 544064, 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 544064, haskell-base-compat-batteries/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2019-12-29 23:26:19 UTC (rev 544065)
@@ -0,0 +1,49 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=base-compat-batteries
+pkgname=haskell-base-compat-batteries
+pkgver=0.11.0
+pkgrel=2
+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=('40b9a4ad696df743e9833120f594077653533d05ee66a03d7a79072505d226d578ad3226304b527556384cc30a4e4ab84898686acc3188e585859ae6b089c177')
+
+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
+    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"
+}



More information about the arch-commits mailing list