[arch-commits] Commit in (4 files)

Felix Yan felixonmars at archlinux.org
Fri Jan 3 22:08:35 UTC 2020


    Date: Friday, January 3, 2020 @ 22:08:34
  Author: felixonmars
Revision: 547762

addpkg: haskell-language-haskell-extract 0.2.4-1

Added:
  haskell-language-haskell-extract/
  haskell-language-haskell-extract/repos/
  haskell-language-haskell-extract/trunk/
  haskell-language-haskell-extract/trunk/PKGBUILD

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

Added: haskell-language-haskell-extract/trunk/PKGBUILD
===================================================================
--- haskell-language-haskell-extract/trunk/PKGBUILD	                        (rev 0)
+++ haskell-language-haskell-extract/trunk/PKGBUILD	2020-01-03 22:08:34 UTC (rev 547762)
@@ -0,0 +1,42 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=language-haskell-extract
+pkgname=haskell-language-haskell-extract
+pkgver=0.2.4
+pkgrel=1
+pkgdesc="Module to automatically extract functions from the local code"
+url="https://github.com/finnsson/language-haskell-extract"
+license=('BSD')
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-regex-posix')
+makedepends=('ghc')
+source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
+sha512sums=('6408459abf9d531ccbe7d65766d38fcb93f4d3f9c77db1a706231bf6d8ad6f845fcefc4fbb03833f45c74f21f324a44760f3c89ff093c69f1f9999e64344ab4d')
+
+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 "BSD3.txt" "${pkgdir}/usr/share/licenses/${pkgname}/BSD3.txt"
+    rm -f "${pkgdir}/usr/share/doc/${pkgname}/BSD3.txt"
+}



More information about the arch-commits mailing list