diff options
author | matoro <matoro@users.noreply.github.com> | 2022-07-13 11:42:24 -0400 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2022-07-22 22:15:01 +0000 |
commit | b56175dcd6bec0258efa66203421189252a759bb (patch) | |
tree | 35f83a43d0d6ffb2c131f1f1a57db78d137eec1e /dev-haskell/cryptonite | |
parent | dev-haskell/cookie: keyword 0.4.4 for ~ppc64 (diff) | |
download | gentoo-b56175dcd6bec0258efa66203421189252a759bb.tar.gz gentoo-b56175dcd6bec0258efa66203421189252a759bb.tar.bz2 gentoo-b56175dcd6bec0258efa66203421189252a759bb.zip |
dev-haskell/cryptonite: add 0.28
Signed-off-by: matoro <matoro@users.noreply.github.com>
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-haskell/cryptonite')
-rw-r--r-- | dev-haskell/cryptonite/Manifest | 2 | ||||
-rw-r--r-- | dev-haskell/cryptonite/cryptonite-0.28.ebuild | 58 | ||||
-rw-r--r-- | dev-haskell/cryptonite/metadata.xml | 1 |
3 files changed, 61 insertions, 0 deletions
diff --git a/dev-haskell/cryptonite/Manifest b/dev-haskell/cryptonite/Manifest index 155a3ff2a2b2..cd4401e72f6f 100644 --- a/dev-haskell/cryptonite/Manifest +++ b/dev-haskell/cryptonite/Manifest @@ -1 +1,3 @@ DIST cryptonite-0.26.tar.gz 581153 BLAKE2B 2becdd3d0c6f1e037fd4d38143a2a8644e38e9826faa271c971d4feff8a4ab1e4c0a04df338c99a8454cff626f79f3334a0a37b19cc136f33e7c8f53e66bd33a SHA512 4236d411542fd104e5cace61fbdeda615f7d13e442594d7fa12acc682d917b0494b10b242a88fef19e91e93489797206fee07497bff92e43d3849ebac8ee11b0 +DIST cryptonite-0.28.tar.gz 616309 BLAKE2B 3fa11777574fab06c264709d4de7b56fd4b276fbee93f4731683a9a18f83cf77d2042679f2eac3044d336c5be382e1e4eb0c90862c20b0f452eaafdee401e616 SHA512 c1e485522938f94f15910a5b5a4a3e4dfecbb62df463c80faaa51e9d883c2612611b8486bd0fd13660766cfb6d62d366fbbd03df2db874d525514aae247b6242 +DIST cryptonite-338.patch 1823 BLAKE2B 99a502e16ec061b37e1d3dc343760c86c1eb1cecf23a9061ef3198082d2777fa129196af3322153558e1da7e87b125bfa3a1e32501482767bbbe2e4ca874d65f SHA512 1f00a31791fef52e7bdb2b052912f8ede9022ee4013d1f74321ff10517c4c8df68be9b97d4bfd88140f5686b3b9d01e0937909dd5a2c462920e559accde8e72d diff --git a/dev-haskell/cryptonite/cryptonite-0.28.ebuild b/dev-haskell/cryptonite/cryptonite-0.28.ebuild new file mode 100644 index 000000000000..72d0c2fc464b --- /dev/null +++ b/dev-haskell/cryptonite/cryptonite-0.28.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# ebuild generated by hackport 0.6.7.9999 +#hackport: flags: -check_alignment,-old_toolchain_inliner,+support_deepseq,support_aesni:cpu_flags_x86_aes,support_pclmuldq:cpu_flags_x86_sse4_1,support_sse:cpu_flags_x86_sse,support_rdrand:cpu_flags_x86_rdrand + +CABAL_FEATURES="lib profile haddock hoogle hscolour test-suite" +inherit flag-o-matic haskell-cabal + +DESCRIPTION="Cryptography Primitives sink" +HOMEPAGE="https://github.com/haskell-crypto/cryptonite" +SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz + https://github.com/haskell-crypto/cryptonite/pull/338.patch -> ${PN}-338.patch" + +LICENSE="BSD" +SLOT="0/${PV}" +KEYWORDS="~amd64 ~ppc64 ~x86" +IUSE="cpu_flags_x86_rdrand cpu_flags_x86_aes cpu_flags_x86_sse cpu_flags_x86_sse4_1 +integer-gmp +target-attributes" + +RDEPEND=">=dev-haskell/basement-0.0.6:=[profile?] + >=dev-haskell/memory-0.14.18:=[profile?] + >=dev-lang/ghc-8.4.3:= + virtual/libc +" +DEPEND="${RDEPEND} + >=dev-haskell/cabal-2.2.0.1 + test? ( dev-haskell/tasty + dev-haskell/tasty-hunit + dev-haskell/tasty-kat + dev-haskell/tasty-quickcheck ) +" + +PATCHES=( "${DISTDIR}"/${PN}-338.patch ) + +src_prepare() { + default + + # On AVX2 cryptonite's own test suite crashes on unaligned access: + # https://github.com/haskell-crypto/cryptonite/issues/347 + # Disable extensions that might require extra alignment. + use amd64 && append-flags -mno-avx2 + use x86 && append-flags -mno-avx2 +} + +src_configure() { + haskell-cabal_src_configure \ + --flag=-check_alignment \ + $(cabal_flag integer-gmp integer-gmp) \ + --flag=-old_toolchain_inliner \ + $(cabal_flag cpu_flags_x86_aes support_aesni) \ + --flag=support_deepseq \ + $(cabal_flag cpu_flags_x86_sse4_1 support_pclmuldq) \ + $(cabal_flag cpu_flags_x86_rdrand support_rdrand) \ + $(cabal_flag cpu_flags_x86_sse support_sse) \ + $(cabal_flag target-attributes use_target_attributes) +} diff --git a/dev-haskell/cryptonite/metadata.xml b/dev-haskell/cryptonite/metadata.xml index 11b4001ffcbf..91b640f27b37 100644 --- a/dev-haskell/cryptonite/metadata.xml +++ b/dev-haskell/cryptonite/metadata.xml @@ -30,6 +30,7 @@ </longdescription> <use> <flag name="integer-gmp">Whether or not to use GMP for some functions</flag> + <flag name="target-attributes">use GCC / clang function attributes instead of global target options.</flag> </use> <upstream> <remote-id type="github">haskell-crypto/cryptonite</remote-id> |