[arch-commits] Commit in (3 files)

Felix Yan felixonmars at archlinux.org
Wed Jul 31 13:18:03 UTC 2019


    Date: Wednesday, July 31, 2019 @ 13:18:02
  Author: felixonmars
Revision: 495537

addpkg: haskell-weigh 0.0.14-1

Added:
  haskell-weigh/
  haskell-weigh/trunk/
  haskell-weigh/trunk/PKGBUILD

----------+
 PKGBUILD |   42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

Added: haskell-weigh/trunk/PKGBUILD
===================================================================
--- haskell-weigh/trunk/PKGBUILD	                        (rev 0)
+++ haskell-weigh/trunk/PKGBUILD	2019-07-31 13:18:02 UTC (rev 495537)
@@ -0,0 +1,42 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=weigh
+pkgname=haskell-weigh
+pkgver=0.0.14
+pkgrel=1
+pkgdesc="Measure allocations of a Haskell functions/values"
+url="https://github.com/fpco/weigh"
+license=('BSD')
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-split' 'haskell-temporary')
+makedepends=('ghc')
+source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
+sha512sums=('877df5b488eb7d2f2a3447cb3cf5ce891622b8ba26544ab734b5d119bd0bc215364faaa34edb99e89e8a51254e26689f52852caa0e4fd54ce0e614e6d1454d3f')
+
+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"
+}



More information about the arch-commits mailing list