[arch-commits] Commit in haskell-resolv/repos (2 files)

Felix Yan felixonmars at archlinux.org
Tue Mar 31 23:12:23 UTC 2020


    Date: Tuesday, March 31, 2020 @ 23:12:23
  Author: felixonmars
Revision: 608542

archrelease: copy trunk to community-staging-x86_64

Added:
  haskell-resolv/repos/community-staging-x86_64/
  haskell-resolv/repos/community-staging-x86_64/PKGBUILD
    (from rev 608541, haskell-resolv/trunk/PKGBUILD)

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

Copied: haskell-resolv/repos/community-staging-x86_64/PKGBUILD (from rev 608541, haskell-resolv/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2020-03-31 23:12:23 UTC (rev 608542)
@@ -0,0 +1,46 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=resolv
+pkgname=haskell-resolv
+pkgver=0.1.1.3
+pkgrel=12
+pkgdesc="Domain Name Service (DNS) lookup via the libresolv standard library routines"
+url="https://github.com/hvr/resolv"
+license=('GPL')
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-base16-bytestring')
+makedepends=('ghc' 'haskell-tasty' 'haskell-tasty-hunit')
+source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
+sha512sums=('59189b3b2c1811f7e4fc3e79f66e5264751479996584e59713cb3ad2cf6d855f202b1db3a02ad57692ee7c55c75a5dc6b5fd008f853f2923923558d923c8129a')
+
+prepare() {
+    cd $_hkgname-$pkgver
+    sed -i 's/< *1.2/<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
+    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"
+    rm -f "$pkgdir"/usr/share/doc/$pkgname/LICENSE
+}



More information about the arch-commits mailing list