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

Felix Yan felixonmars at gemini.archlinux.org
Mon Jan 10 17:01:13 UTC 2022


    Date: Monday, January 10, 2022 @ 17:01:12
  Author: felixonmars
Revision: 1099509

archrelease: copy trunk to community-staging-x86_64

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

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

Copied: haskell-newtype/repos/community-staging-x86_64/PKGBUILD (from rev 1099508, haskell-newtype/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2022-01-10 17:01:12 UTC (rev 1099509)
@@ -0,0 +1,42 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=newtype
+pkgname=haskell-newtype
+pkgver=0.2.2.0
+pkgrel=12
+pkgdesc="A typeclass and set of functions for working with newtypes"
+url="https://hackage.haskell.org/package/${_hkgname}"
+license=('BSD')
+arch=('x86_64')
+depends=('ghc-libs')
+makedepends=('ghc')
+source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
+sha512sums=('9d8b344ac5f6ff62d8100b95dd879715639af2d8d1f63a8cb17a18fa7c4f427eade49aa3d6b47034351ac0f2cb5061013f6321038bff1053eb3aa84faf157a5b')
+
+prepare() {
+    cd $_hkgname-$pkgver
+    sed -i 's/< *4.14/<5/' $_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 \
+        --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid --ghc-option=-fllvm
+    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