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

Felix Yan felixonmars at archlinux.org
Sat Dec 26 03:29:42 UTC 2020


    Date: Saturday, December 26, 2020 @ 03:29:41
  Author: felixonmars
Revision: 791776

archrelease: copy trunk to community-staging-x86_64

Added:
  haskell-network-bsd/repos/community-staging-x86_64/
  haskell-network-bsd/repos/community-staging-x86_64/PKGBUILD
    (from rev 791775, haskell-network-bsd/trunk/PKGBUILD)

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

Copied: haskell-network-bsd/repos/community-staging-x86_64/PKGBUILD (from rev 791775, haskell-network-bsd/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2020-12-26 03:29:41 UTC (rev 791776)
@@ -0,0 +1,42 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=network-bsd
+pkgname=haskell-network-bsd
+pkgver=2.8.1.0
+pkgrel=46
+pkgdesc="POSIX network database (<netdb.h>) API"
+url="https://github.com/haskell/network-bsd"
+license=('MIT')
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-network')
+makedepends=('ghc')
+source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
+sha512sums=('b2f66c6705c490e1cbaab6ca88444294bc90b3711da4039046a9279060ed41228ab855b40039f56bd02eabcc0351200de3e043a108a0cdc98192d563702de7f3')
+
+prepare() {
+    cd $_hkgname-$pkgver
+    sed -i 's/< *3.0/<4/' $_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 $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
+}
+
+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