[arch-commits] Commit in haskell-spdx/repos (3 files)

Felix Yan felixonmars at gemini.archlinux.org
Sun Nov 28 20:08:36 UTC 2021


    Date: Sunday, November 28, 2021 @ 20:08:36
  Author: felixonmars
Revision: 1055443

archrelease: copy trunk to community-staging-x86_64

Added:
  haskell-spdx/repos/community-staging-x86_64/
  haskell-spdx/repos/community-staging-x86_64/PKGBUILD
    (from rev 1055442, haskell-spdx/trunk/PKGBUILD)
  haskell-spdx/repos/community-staging-x86_64/cabal-3.4.patch
    (from rev 1055442, haskell-spdx/trunk/cabal-3.4.patch)

-----------------+
 PKGBUILD        |   51 +++++++++++++++++++++++++++++++++++++++++++++++++++
 cabal-3.4.patch |   38 ++++++++++++++++++++++++++++++++++++++
 2 files changed, 89 insertions(+)

Copied: haskell-spdx/repos/community-staging-x86_64/PKGBUILD (from rev 1055442, haskell-spdx/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2021-11-28 20:08:36 UTC (rev 1055443)
@@ -0,0 +1,51 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
+
+_hkgname=spdx
+pkgname=haskell-spdx
+pkgver=1.0.0.2
+pkgrel=113
+pkgdesc="SPDX license expression language, Extras"
+url="https://github.com/phadej/spdx"
+license=("BSD")
+arch=('x86_64')
+depends=('ghc-libs')
+makedepends=('ghc' 'uusi' 'haskell-base-compat' 'haskell-tasty' 'haskell-tasty-quickcheck')
+source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz"
+        cabal-3.4.patch)
+sha512sums=('2fb48d204a0c85269d4dbd6bd98efefb0691adc3eb654228b90b244c0d062e0e2f23c42e5f7ef9ab27a2f988654485fec11c3bdc0642b9b17d35791dd80f1548'
+            'edcd5676c3bdcc1f45bd41c8c465defb3b423e46330dbdf0037bf5d59658c4491c9979422077ba1fe598da12ca8b15a01d8f3d2de0a65d8bcc7f6e842a51d56e')
+
+prepare() {
+    cd $_hkgname-$pkgver
+    patch -p1 -i ../cabal-3.4.patch
+    uusi -u base -u base-compat -u tasty $_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 --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
+}
+
+check() {
+    cd $_hkgname-$pkgver
+    runhaskell Setup test --show-details=direct
+}
+
+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
+}

Copied: haskell-spdx/repos/community-staging-x86_64/cabal-3.4.patch (from rev 1055442, haskell-spdx/trunk/cabal-3.4.patch)
===================================================================
--- community-staging-x86_64/cabal-3.4.patch	                        (rev 0)
+++ community-staging-x86_64/cabal-3.4.patch	2021-11-28 20:08:36 UTC (rev 1055443)
@@ -0,0 +1,38 @@
+From 8afaa090a5f52a9dbde057b79ccf9739bcef8812 Mon Sep 17 00:00:00 2001
+From: Oleg Grenrus <oleg.grenrus at iki.fi>
+Date: Sat, 6 Feb 2021 11:55:15 +0200
+Subject: [PATCH] Allow Cabal-3.4
+
+---
+ spdx.cabal          | 6 +++---
+ tests/Generators.hs | 4 +++-
+ 2 files changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/spdx.cabal b/spdx.cabal
+index a9ad636..4174b21 100644
+--- a/spdx.cabal
++++ b/spdx.cabal
+@@ -49,7 +49,7 @@ library
+   ghc-options:      -Wall
+   build-depends:
+     , base          >=4.3.0.0 && <4.15
+-    , Cabal         ^>=2.4.0.1 || ^>=3.0.0.0 || ^>=3.2.0.0
++    , Cabal         ^>=2.4.0.1 || ^>=3.0.0.0 || ^>=3.2.0.0 || ^>=3.4.0.0
+     , containers    >=0.5.0.0 && <0.7
+     , transformers  >=0.3     && <0.6
+ 
+diff --git a/tests/Generators.hs b/tests/Generators.hs
+index 90ef406..1a048d3 100644
+--- a/tests/Generators.hs
++++ b/tests/Generators.hs
+@@ -15,7 +15,9 @@ import           Distribution.SPDX
+ import           Distribution.SPDX.Extra.Internal (LatticeSyntax(..))
+ 
+ latestLicenseListVersion :: LicenseListVersion
+-#if MIN_VERSION_Cabal(3,0,0)
++#if MIN_VERSION_Cabal(3,4,0)
++latestLicenseListVersion = LicenseListVersion_3_9
++#elif MIN_VERSION_Cabal(3,0,0)
+ latestLicenseListVersion = LicenseListVersion_3_6
+ #else
+ latestLicenseListVersion = LicenseListVersion_3_2



More information about the arch-commits mailing list