From 2039380ea094cb725c933cea0d8f929229aba1a7 Mon Sep 17 00:00:00 2001 From: Jens Petersen Date: Sun, 17 Feb 2019 22:44:10 +0800 Subject: [PATCH] refresh to cabal-rpm-0.13 --- cryptohash-sha1-0.11.100.1.cabal | 62 ++++++++++++++++++++++---------- ghc-cryptohash-sha1.spec | 21 ++++++++--- 2 files changed, 60 insertions(+), 23 deletions(-) diff --git a/cryptohash-sha1-0.11.100.1.cabal b/cryptohash-sha1-0.11.100.1.cabal index 3da46d5..984a07f 100644 --- a/cryptohash-sha1-0.11.100.1.cabal +++ b/cryptohash-sha1-0.11.100.1.cabal @@ -1,21 +1,47 @@ +cabal-version: >=1.10 name: cryptohash-sha1 version: 0.11.100.1 -x-revision: 2 -description: - A practical incremental and one-pass, pure API to the - - (including support) - with performance close to the fastest implementations available in other languages. - . - The implementation is made in C with a haskell FFI wrapper that hides the C implementation. - . - NOTE: This package has been forked off @cryptohash-0.11.7@ because the @cryptohash@ package has been - deprecated and so this package continues to satisfy the need for a lightweight package - providing the SHA1 hash algorithm without any dependencies on packages other than - @base@ and @bytestring@. - . - Consequently, this package can be used as a drop-in replacement for @cryptohash@'s - "Crypto.Hash.SHA1" module, though with a clearly smaller footprint. +x-revision: 3 + +synopsis: Fast, pure and practical SHA-1 implementation +description: { + +A practical incremental and one-pass, pure API to +the [SHA-1 cryptographic hash algorithm](https://en.wikipedia.org/wiki/SHA-1) according +to [FIPS 180-4](http://dx.doi.org/10.6028/NIST.FIPS.180-4) +with performance close to the fastest implementations available in other languages. +. +The core SHA-1 algorithm is implemented in C and is thus expected +to be as fast as the standard [sha1sum(1) tool](https://linux.die.net/man/1/sha1sum). +(If, instead, you require a pure Haskell implementation and performance is secondary, please refer to the [SHA package](https://hackage.haskell.org/package/SHA).) +. +Additionally, this package provides support for +. +- HMAC-SHA-1: SHA-1-based [Hashed Message Authentication Codes](https://en.wikipedia.org/wiki/HMAC) (HMAC) +. +conforming to [RFC6234](https://tools.ietf.org/html/rfc6234), [RFC4231](https://tools.ietf.org/html/rfc4231), [RFC5869](https://tools.ietf.org/html/rfc5869), et al.. +. +=== Packages in the @cryptohash-*@ family +. +- +- +- +- +. +=== Relationship to the @cryptohash@ package and its API +. +This package has been originally a fork of @cryptohash-0.11.7@ because the @cryptohash@ +package had been deprecated and so this package continues to satisfy the need for a +lightweight package providing the SHA-1 hash algorithm without any dependencies on packages +other than @base@ and @bytestring@. The API exposed by @cryptohash-sha1-0.11.*@'s +"Crypto.Hash.SHA1" module is guaranteed to remain a compatible superset of the API provided +by the @cryptohash-0.11.7@'s module of the same name. +. +Consequently, this package is designed to be used as a drop-in replacement for @cryptohash-0.11.7@'s +"Crypto.Hash.SHA1" module, though with +a [clearly smaller footprint by almost 3 orders of magnitude](https://www.reddit.com/r/haskell/comments/5lxv75/psa_please_use_unique_module_names_when_uploading/dbzegx3/). + +} license: BSD3 license-file: LICENSE @@ -23,10 +49,8 @@ copyright: Vincent Hanquez, Herbert Valerio Riedel maintainer: Herbert Valerio Riedel homepage: https://github.com/hvr/cryptohash-sha1 bug-reports: https://github.com/hvr/cryptohash-sha1/issues -synopsis: Fast, pure and practical SHA-1 implementation category: Data, Cryptography build-type: Simple -cabal-version: >=1.10 tested-with: GHC == 7.4.2 , GHC == 7.6.3 , GHC == 7.8.4 @@ -42,7 +66,7 @@ source-repository head library default-language: Haskell2010 - build-depends: base >= 4.5 && < 4.12 + build-depends: base >= 4.5 && < 4.13 , bytestring >= 0.9.2 && < 0.11 hs-source-dirs: src diff --git a/ghc-cryptohash-sha1.spec b/ghc-cryptohash-sha1.spec index 4ff71f4..002da87 100644 --- a/ghc-cryptohash-sha1.spec +++ b/ghc-cryptohash-sha1.spec @@ -1,4 +1,4 @@ -# generated by cabal-rpm-0.12.5 +# generated by cabal-rpm-0.13 # https://fedoraproject.org/wiki/Packaging:Haskell %global pkg_name cryptohash-sha1 @@ -8,17 +8,19 @@ Name: ghc-%{pkg_name} Version: 0.11.100.1 -Release: 9%{?dist} +Release: 10%{?dist} Summary: Fast, pure and practical SHA-1 implementation License: BSD Url: https://hackage.haskell.org/package/%{pkg_name} +# Begin cabal-rpm sources: Source0: https://hackage.haskell.org/package/%{pkgver}/%{pkgver}.tar.gz Source1: https://hackage.haskell.org/package/%{pkgver}/%{pkg_name}.cabal#/%{pkgver}.cabal +# End cabal-rpm sources +# Begin cabal-rpm deps: BuildRequires: ghc-Cabal-devel BuildRequires: ghc-rpm-macros -# Begin cabal-rpm deps: BuildRequires: ghc-bytestring-devel %if %{with tests} BuildRequires: ghc-SHA-devel @@ -61,16 +63,22 @@ files. %prep +# Begin cabal-rpm setup: %setup -q -n %{pkgver} -cp -p %{SOURCE1} %{pkg_name}.cabal +cp -bp %{SOURCE1} %{pkg_name}.cabal +# End cabal-rpm setup %build +# Begin cabal-rpm build: %ghc_lib_build +# End cabal-rpm build %install +# Begin cabal-rpm install %ghc_lib_install +# End cabal-rpm install %check @@ -86,7 +94,9 @@ cp -p %{SOURCE1} %{pkg_name}.cabal %files -f %{name}.files +# Begin cabal-rpm files: %license LICENSE +# End cabal-rpm files %files devel -f %{name}-devel.files @@ -94,6 +104,9 @@ cp -p %{SOURCE1} %{pkg_name}.cabal %changelog +* Sun Feb 17 2019 Jens Petersen - 0.11.100.1-10 +- refresh to cabal-rpm-0.13 + * Sat Feb 16 2019 Jens Petersen - 0.11.100.1-9 - use revised .cabal file