Date: Tuesday, August 11, 2020 @ 23:54:47
  Author: felixonmars
Revision: 675252

archrelease: copy trunk to community-staging-x86_64

Added:
  haskell-text-short/repos/community-staging-x86_64/
  haskell-text-short/repos/community-staging-x86_64/PKGBUILD
    (from rev 675251, haskell-text-short/trunk/PKGBUILD)

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

Copied: haskell-text-short/repos/community-staging-x86_64/PKGBUILD (from rev 
675251, haskell-text-short/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD                           (rev 0)
+++ community-staging-x86_64/PKGBUILD   2020-08-11 23:54:47 UTC (rev 675252)
@@ -0,0 +1,50 @@
+# Maintainer: Felix Yan <felixonm...@archlinux.org>
+# Contributor: Arch Haskell Team <arch-hask...@haskell.org>
+
+_hkgname=text-short
+pkgname=haskell-text-short
+pkgver=0.1.3
+pkgrel=42
+pkgdesc="Memory-efficient representation of Unicode text strings"
+url="https://github.com/hvr/text-short";
+license=("BSD")
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-hashable')
+makedepends=('ghc' 'haskell-quickcheck-instances' 'haskell-tasty' 
'haskell-tasty-hunit'
+             'haskell-tasty-quickcheck')
+source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz";)
+sha512sums=('6d7a5379dbaf28a201dd44229959a293acb5ff57c4659a6a34af37e46b2e6fc5eb61a00ba26d36dd08795456246429ec20236af8e342fd0d03bfcf6d06d69428')
+
+prepare() {
+    cd $_hkgname-$pkgver
+    sed -i 's/< *4.13/<5/;s/< *0.6/<1/;s/< *1.3/<2/' $_hkgname.cabal
+}
+
+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 \
+            -f-asserts
+    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
+}
+
+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
+}

Reply via email to