[arch-commits] Commit in cabal-install/repos/community-x86_64 (4 files)
Felix Yan
felixonmars at gemini.archlinux.org
Sat Feb 12 13:38:26 UTC 2022
Date: Saturday, February 12, 2022 @ 13:38:26
Author: felixonmars
Revision: 1132781
archrelease: copy trunk to community-x86_64
Added:
cabal-install/repos/community-x86_64/PKGBUILD
(from rev 1132780, cabal-install/trunk/PKGBUILD)
cabal-install/repos/community-x86_64/cabal-install-base16-bytestring1.0.patch
(from rev 1132780, cabal-install/trunk/cabal-install-base16-bytestring1.0.patch)
Deleted:
cabal-install/repos/community-x86_64/PKGBUILD
cabal-install/repos/community-x86_64/cabal-install-base16-bytestring1.0.patch
------------------------------------------+
PKGBUILD | 92 ++++++++---------
cabal-install-base16-bytestring1.0.patch | 156 ++++++++++++++---------------
2 files changed, 124 insertions(+), 124 deletions(-)
Deleted: PKGBUILD
===================================================================
--- PKGBUILD 2022-02-12 13:38:16 UTC (rev 1132780)
+++ PKGBUILD 2022-02-12 13:38:26 UTC (rev 1132781)
@@ -1,46 +0,0 @@
-# Maintainer: Felix Yan <felixonmars at archlinux.org>
-# Contributor: Thomas Dziedzic <gostrc at gmail.com>
-# Contributor: Vesa Kaihlavirta <vesa at archlinux.org>
-# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
-
-pkgname=cabal-install
-pkgver=3.4.0.0
-pkgrel=98
-pkgdesc="The command-line interface for Cabal and Hackage."
-url="https://hackage.haskell.org/package/cabal-install"
-license=('BSD')
-arch=('x86_64')
-depends=('ghc-libs' 'haskell-async' 'haskell-base16-bytestring' 'haskell-cryptohash-sha256'
- 'haskell-echo' 'haskell-edit-distance' 'haskell-hackage-security' 'haskell-hashable'
- 'haskell-http' 'haskell-network-uri' 'haskell-random' 'haskell-regex-base'
- 'haskell-regex-posix' 'haskell-resolv' 'haskell-tar' 'haskell-zlib' 'haskell-lukko')
-makedepends=('ghc' 'uusi')
-source=("https://hackage.haskell.org/package/cabal-install-${pkgver}/cabal-install-${pkgver}.tar.gz"
- $pkgname-base16-bytestring1.0.patch)
-sha512sums=('0fd93c86c59e3c626341be3c67e69a1502f1ce1413b4a456cd930d5449cabdaeb033ac5f47673db0e708fc194aadf8ab0aa2904b6b0f195b57907c5b40588323'
- '966e2f0e3fd1cff3d673cb91f73b2a42049653e39a3025cdbbf86ec8ebfbd49bad278c8d01f521bbe580369bd11baf2aa7f8195e0ae450efd8ae615d13aa2300')
-
-prepare() {
- cd $pkgname-$pkgver
- patch -p2 -i ../$pkgname-base16-bytestring1.0.patch
- uusi -u base $pkgname.cabal
-}
-
-build() {
- cd $pkgname-$pkgver
-
- runhaskell Setup configure -O --prefix=/usr --enable-executable-dynamic --disable-library-vanilla \
- --docdir="/usr/share/doc/${pkgname}"
- runhaskell Setup build $MAKEFLAGS
-}
-
-package() {
- cd $pkgname-$pkgver
- runhaskell Setup copy --destdir="${pkgdir}"
-
- install -Dm644 LICENSE \
- "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
-
- install -Dm644 bash-completion/cabal \
- "${pkgdir}/usr/share/bash-completion/completions/cabal"
-}
Copied: cabal-install/repos/community-x86_64/PKGBUILD (from rev 1132780, cabal-install/trunk/PKGBUILD)
===================================================================
--- PKGBUILD (rev 0)
+++ PKGBUILD 2022-02-12 13:38:26 UTC (rev 1132781)
@@ -0,0 +1,46 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Thomas Dziedzic <gostrc at gmail.com>
+# Contributor: Vesa Kaihlavirta <vesa at archlinux.org>
+# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
+
+pkgname=cabal-install
+pkgver=3.4.0.0
+pkgrel=99
+pkgdesc="The command-line interface for Cabal and Hackage."
+url="https://hackage.haskell.org/package/cabal-install"
+license=('BSD')
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-async' 'haskell-base16-bytestring' 'haskell-cryptohash-sha256'
+ 'haskell-echo' 'haskell-edit-distance' 'haskell-hackage-security' 'haskell-hashable'
+ 'haskell-http' 'haskell-network-uri' 'haskell-random' 'haskell-regex-base'
+ 'haskell-regex-posix' 'haskell-resolv' 'haskell-tar' 'haskell-zlib' 'haskell-lukko')
+makedepends=('ghc' 'uusi')
+source=("https://hackage.haskell.org/package/cabal-install-${pkgver}/cabal-install-${pkgver}.tar.gz"
+ $pkgname-base16-bytestring1.0.patch)
+sha512sums=('0fd93c86c59e3c626341be3c67e69a1502f1ce1413b4a456cd930d5449cabdaeb033ac5f47673db0e708fc194aadf8ab0aa2904b6b0f195b57907c5b40588323'
+ '966e2f0e3fd1cff3d673cb91f73b2a42049653e39a3025cdbbf86ec8ebfbd49bad278c8d01f521bbe580369bd11baf2aa7f8195e0ae450efd8ae615d13aa2300')
+
+prepare() {
+ cd $pkgname-$pkgver
+ patch -p2 -i ../$pkgname-base16-bytestring1.0.patch
+ uusi -u base $pkgname.cabal
+}
+
+build() {
+ cd $pkgname-$pkgver
+
+ runhaskell Setup configure -O --prefix=/usr --enable-executable-dynamic --disable-library-vanilla \
+ --docdir="/usr/share/doc/${pkgname}"
+ runhaskell Setup build $MAKEFLAGS
+}
+
+package() {
+ cd $pkgname-$pkgver
+ runhaskell Setup copy --destdir="${pkgdir}"
+
+ install -Dm644 LICENSE \
+ "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+
+ install -Dm644 bash-completion/cabal \
+ "${pkgdir}/usr/share/bash-completion/completions/cabal"
+}
Deleted: cabal-install-base16-bytestring1.0.patch
===================================================================
--- cabal-install-base16-bytestring1.0.patch 2022-02-12 13:38:16 UTC (rev 1132780)
+++ cabal-install-base16-bytestring1.0.patch 2022-02-12 13:38:26 UTC (rev 1132781)
@@ -1,78 +0,0 @@
-diff --git a/cabal-install/Distribution/Client/HashValue.hs b/cabal-install/Distribution/Client/HashValue.hs
-index 54b8aee9e..11e647c1c 100644
---- a/cabal-install/Distribution/Client/HashValue.hs
-+++ b/cabal-install/Distribution/Client/HashValue.hs
-@@ -1,3 +1,4 @@
-+{-# LANGUAGE CPP #-}
- {-# LANGUAGE DeriveDataTypeable #-}
- {-# LANGUAGE DeriveGeneric #-}
- module Distribution.Client.HashValue (
-@@ -72,10 +73,14 @@ hashFromTUF (Sec.Hash hashstr) =
- --TODO: [code cleanup] either we should get TUF to use raw bytestrings or
- -- perhaps we should also just use a base16 string as the internal rep.
- case Base16.decode (BS.pack hashstr) of
-+#if MIN_VERSION_base16_bytestring(1,0,0)
-+ Right hash -> HashValue hash
-+ Left _ -> error "hashFromTUF: cannot decode base16"
-+#else
- (hash, trailing) | not (BS.null hash) && BS.null trailing
- -> HashValue hash
- _ -> error "hashFromTUF: cannot decode base16 hash"
--
-+#endif
-
- -- | Truncate a 32 byte SHA256 hash to
- --
-diff --git a/cabal-install/src/Distribution/Client/HttpUtils.hs b/cabal-install/src/Distribution/Client/HttpUtils.hs
-index 9b8a8ecb844..0c334bec44a 100644
---- a/cabal-install/Distribution/Client/HttpUtils.hs
-+++ b/cabal-install/Distribution/Client/HttpUtils.hs
-@@ -1,4 +1,5 @@
- {-# LANGUAGE BangPatterns #-}
-+{-# LANGUAGE CPP #-}
- -----------------------------------------------------------------------------
- -- | Separate module for HTTP actions, using a proxy server if one exists.
- -----------------------------------------------------------------------------
-@@ -182,7 +183,11 @@ downloadURI transport verbosity uri path = do
- fragmentParser = do
- _ <- P.string "#sha256="
- str <- some P.hexDigit
-+#if MIN_VERSION_base16_bytestring(1,0,0)
-+ return (Base16.decodeLenient (BS8.pack str))
-+#else
- return (fst (Base16.decode (BS8.pack str)))
-+#endif
-
- ------------------------------------------------------------------------------
- -- Utilities for repo url management
-diff --git a/cabal-install/src/Distribution/Client/HttpUtils.hs b/cabal-install/src/Distribution/Client/HttpUtils.hs
-index 0c334bec44a..6de14f3c661 100644
---- a/cabal-install/Distribution/Client/HttpUtils.hs
-+++ b/cabal-install/Distribution/Client/HttpUtils.hs
-@@ -183,10 +183,11 @@ downloadURI transport verbosity uri path = do
- fragmentParser = do
- _ <- P.string "#sha256="
- str <- some P.hexDigit
-+ let bs = Base16.decode (BS8.pack str)
- #if MIN_VERSION_base16_bytestring(1,0,0)
-- return (Base16.decodeLenient (BS8.pack str))
-+ either fail return bs
- #else
-- return (fst (Base16.decode (BS8.pack str)))
-+ return (fst bs)
- #endif
-
- ------------------------------------------------------------------------------
-diff --git a/cabal-install/cabal-install.cabal b/cabal-install/cabal-install.cabal
-index ee49fe245..6d423fdb3 100644
---- a/cabal-install/cabal-install.cabal
-+++ b/cabal-install/cabal-install.cabal
-@@ -319,7 +319,7 @@ executable cabal
- async >= 2.0 && < 2.3,
- array >= 0.4 && < 0.6,
- base >= 4.8 && < 4.15,
-- base16-bytestring >= 0.1.1 && < 0.2,
-+ base16-bytestring >= 0.1.1 && < 1.1.0.0,
- binary >= 0.7.3 && < 0.9,
- bytestring >= 0.10.6.0 && < 0.11,
- Cabal == 3.2.*,
Copied: cabal-install/repos/community-x86_64/cabal-install-base16-bytestring1.0.patch (from rev 1132780, cabal-install/trunk/cabal-install-base16-bytestring1.0.patch)
===================================================================
--- cabal-install-base16-bytestring1.0.patch (rev 0)
+++ cabal-install-base16-bytestring1.0.patch 2022-02-12 13:38:26 UTC (rev 1132781)
@@ -0,0 +1,78 @@
+diff --git a/cabal-install/Distribution/Client/HashValue.hs b/cabal-install/Distribution/Client/HashValue.hs
+index 54b8aee9e..11e647c1c 100644
+--- a/cabal-install/Distribution/Client/HashValue.hs
++++ b/cabal-install/Distribution/Client/HashValue.hs
+@@ -1,3 +1,4 @@
++{-# LANGUAGE CPP #-}
+ {-# LANGUAGE DeriveDataTypeable #-}
+ {-# LANGUAGE DeriveGeneric #-}
+ module Distribution.Client.HashValue (
+@@ -72,10 +73,14 @@ hashFromTUF (Sec.Hash hashstr) =
+ --TODO: [code cleanup] either we should get TUF to use raw bytestrings or
+ -- perhaps we should also just use a base16 string as the internal rep.
+ case Base16.decode (BS.pack hashstr) of
++#if MIN_VERSION_base16_bytestring(1,0,0)
++ Right hash -> HashValue hash
++ Left _ -> error "hashFromTUF: cannot decode base16"
++#else
+ (hash, trailing) | not (BS.null hash) && BS.null trailing
+ -> HashValue hash
+ _ -> error "hashFromTUF: cannot decode base16 hash"
+-
++#endif
+
+ -- | Truncate a 32 byte SHA256 hash to
+ --
+diff --git a/cabal-install/src/Distribution/Client/HttpUtils.hs b/cabal-install/src/Distribution/Client/HttpUtils.hs
+index 9b8a8ecb844..0c334bec44a 100644
+--- a/cabal-install/Distribution/Client/HttpUtils.hs
++++ b/cabal-install/Distribution/Client/HttpUtils.hs
+@@ -1,4 +1,5 @@
+ {-# LANGUAGE BangPatterns #-}
++{-# LANGUAGE CPP #-}
+ -----------------------------------------------------------------------------
+ -- | Separate module for HTTP actions, using a proxy server if one exists.
+ -----------------------------------------------------------------------------
+@@ -182,7 +183,11 @@ downloadURI transport verbosity uri path = do
+ fragmentParser = do
+ _ <- P.string "#sha256="
+ str <- some P.hexDigit
++#if MIN_VERSION_base16_bytestring(1,0,0)
++ return (Base16.decodeLenient (BS8.pack str))
++#else
+ return (fst (Base16.decode (BS8.pack str)))
++#endif
+
+ ------------------------------------------------------------------------------
+ -- Utilities for repo url management
+diff --git a/cabal-install/src/Distribution/Client/HttpUtils.hs b/cabal-install/src/Distribution/Client/HttpUtils.hs
+index 0c334bec44a..6de14f3c661 100644
+--- a/cabal-install/Distribution/Client/HttpUtils.hs
++++ b/cabal-install/Distribution/Client/HttpUtils.hs
+@@ -183,10 +183,11 @@ downloadURI transport verbosity uri path = do
+ fragmentParser = do
+ _ <- P.string "#sha256="
+ str <- some P.hexDigit
++ let bs = Base16.decode (BS8.pack str)
+ #if MIN_VERSION_base16_bytestring(1,0,0)
+- return (Base16.decodeLenient (BS8.pack str))
++ either fail return bs
+ #else
+- return (fst (Base16.decode (BS8.pack str)))
++ return (fst bs)
+ #endif
+
+ ------------------------------------------------------------------------------
+diff --git a/cabal-install/cabal-install.cabal b/cabal-install/cabal-install.cabal
+index ee49fe245..6d423fdb3 100644
+--- a/cabal-install/cabal-install.cabal
++++ b/cabal-install/cabal-install.cabal
+@@ -319,7 +319,7 @@ executable cabal
+ async >= 2.0 && < 2.3,
+ array >= 0.4 && < 0.6,
+ base >= 4.8 && < 4.15,
+- base16-bytestring >= 0.1.1 && < 0.2,
++ base16-bytestring >= 0.1.1 && < 1.1.0.0,
+ binary >= 0.7.3 && < 0.9,
+ bytestring >= 0.10.6.0 && < 0.11,
+ Cabal == 3.2.*,
More information about the arch-commits
mailing list