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

Felix Yan felixonmars at archlinux.org
Sun Dec 24 06:44:46 UTC 2017


    Date: Sunday, December 24, 2017 @ 06:44:45
  Author: felixonmars
Revision: 275647

archrelease: copy trunk to community-staging-x86_64

Added:
  haskell-config-ini/repos/community-staging-x86_64/
  haskell-config-ini/repos/community-staging-x86_64/PKGBUILD
    (from rev 275646, haskell-config-ini/trunk/PKGBUILD)

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

Copied: haskell-config-ini/repos/community-staging-x86_64/PKGBUILD (from rev 275646, haskell-config-ini/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2017-12-24 06:44:45 UTC (rev 275647)
@@ -0,0 +1,49 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
+
+_hkgname=config-ini
+pkgname=haskell-config-ini
+pkgver=0.2.1.1
+pkgrel=3
+pkgdesc="A library for simple INI-based configuration files."
+url="https://github.com/aisamanra/config-ini"
+license=("custom:BSD3")
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-text' 'haskell-unordered-containers' 'haskell-megaparsec')
+makedepends=('ghc' 'haskell-ini' 'haskell-hedgehog' 'haskell-doctest' 'haskell-microlens')
+source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz")
+sha512sums=('d6cc340b84cda249f9a3f06d8d7508a78a11d045bd82cd9bd34e19efa31720a85186c2e4f30a837365a3c82979ec170b9bc5ebe937db881796f858cd16d855d9')
+
+prepare() {
+    sed -i 's/doctest \[ /doctest [ "-dynamic", /' $_hkgname-$pkgver/test/doctest/Main.hs
+}
+
+build() {
+    cd "${srcdir}/${_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() {
+    # https://github.com/aisamanra/config-ini/issues/12
+    cd $_hkgname-$pkgver
+    runhaskell Setup test || warning "Tests failed"
+}
+
+package() {
+    cd "${srcdir}/${_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