summaryrefslogtreecommitdiff
path: root/dev-haskell/quickcheck-classes-base
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-08-01 22:03:23 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-08-01 22:03:23 +0100
commit590b9b7b03bf4651e099949e318755af7cfa81b8 (patch)
tree54c184b7d26c25f1922bfeaf19a1dd45a2e3b1eb /dev-haskell/quickcheck-classes-base
parentf4fc10428424904caf2035cffc442195cb088b2c (diff)
gentoo resync : 01.08.2021
Diffstat (limited to 'dev-haskell/quickcheck-classes-base')
-rw-r--r--dev-haskell/quickcheck-classes-base/Manifest7
-rw-r--r--dev-haskell/quickcheck-classes-base/files/quickcheck-classes-base-0.6.2.0-laws.patch51
-rw-r--r--dev-haskell/quickcheck-classes-base/metadata.xml23
-rw-r--r--dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.2.0.ebuild (renamed from dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.0.0.ebuild)17
4 files changed, 63 insertions, 35 deletions
diff --git a/dev-haskell/quickcheck-classes-base/Manifest b/dev-haskell/quickcheck-classes-base/Manifest
index e16e8ec39090..2fe8363d75e2 100644
--- a/dev-haskell/quickcheck-classes-base/Manifest
+++ b/dev-haskell/quickcheck-classes-base/Manifest
@@ -1,3 +1,4 @@
-DIST quickcheck-classes-base-0.6.0.0.tar.gz 25760 BLAKE2B d09794c63da8311836e6422006d262fca21f7d71b473b69f57bd49b3ed2e39f29fcfd18b73fd311db4f6b1cca390cc579f2438481dbd680841c835d7d0d9f557 SHA512 3d0a7c68ab1cdaddbd272df633e0704f5ee3997b3a86fe79cb960f7c84f8546f3360b9d52ada45b9db6344135f0aab1093d5304935ae19f43d235790fba83216
-EBUILD quickcheck-classes-base-0.6.0.0.ebuild 1143 BLAKE2B 9f80f952b5ebe7f421bea47b9fd028ceb8f21aacf6a73dac28e5d7a321b43eef02df93ee78ba347a1e588ae56b5b8562b58b6c84fd1734e62143ea6940874993 SHA512 55d5b608286319e3bedeb2f0601556045420b05520062ecc5ef9e1b41f68b05a05ccdbcd204f38c73079da86ce494c60c8977cd9212cc92b667e7dc2f3327c91
-MISC metadata.xml 1568 BLAKE2B 977b3e776e54bd046d3dd86ee971c47c58f2b302cd1788ea4c5c379aad84e8f0915afa0b6c55148e4d8120fb26f23e8ca0787c5ff386c8bbedb457e35504fdb3 SHA512 481c27afee017ea85e28760e56ec5a5173c977683a89c27ab254db1c08935ccea91178017db2eb8ba489b1a8942f4963f6564b6b128ab064592b795af0192d39
+AUX quickcheck-classes-base-0.6.2.0-laws.patch 1639 BLAKE2B d07511518debc5aa09d712c460fd3414665ad0203fff44f42ea49b17db83c44b0095ac17716df76235d01744d75d65a7255ab33a4e3c98dc0444adc90c6f0a94 SHA512 03b78a341a3d81d096e65d8b038edf6e41b5525b8d6c1c2e44647a73c8980cdd199256ab3a717bf5dde43fe575da4211dff76853fd5cd4b353401ba6bdda1cd1
+DIST quickcheck-classes-base-0.6.2.0.tar.gz 26732 BLAKE2B aa3b7be411c66b72eb07c81e9fe2c1accdde254ae8e510080d7b0ea93df0148317a61633f96fe459ab329af112eee3d8243fb728f5416d95d258b90a40d1d9cf SHA512 730255f74582081e65fa8c6b36ab8a2c26991a8e7d8140361151614e7a9619f178e50820cdfc3bf5771f1688dce369f9d71de683bc89481a20f8d2382ae4b58d
+EBUILD quickcheck-classes-base-0.6.2.0.ebuild 999 BLAKE2B cd8398936d72fde7af5760c0a4a0bcdbf66f32ac343f52d9ff7a2268bc0eb30c39a68f7b8fa0aa5498aebdcf144d7b6e2439bf25c1defa6000e942f671ac789b SHA512 34a8bc4dbf1cc6f29575166ba739a4c3659062852fe33952301331285f0102d55e85f8f3ec61e40b76e1c19a56a537356922e303f900383974b65b45fafa76d8
+MISC metadata.xml 572 BLAKE2B d14ea6d21b0c3e817e7ee74ca37288963b20cd8225be8340f8dce74f5c7245076f17d743cc5b3406def78535cb1e0f138e93f5052683a03158fe40d1bb56db90 SHA512 91923b6821ff8fe60378006acd03cc8a1187fe79f22748df93b67bd27da20da2a23bc5a9a8e83d5dd4710dd7f722e2d89b485593ed686fedf5d1fab0e23f42f6
diff --git a/dev-haskell/quickcheck-classes-base/files/quickcheck-classes-base-0.6.2.0-laws.patch b/dev-haskell/quickcheck-classes-base/files/quickcheck-classes-base-0.6.2.0-laws.patch
new file mode 100644
index 000000000000..f806f226a06d
--- /dev/null
+++ b/dev-haskell/quickcheck-classes-base/files/quickcheck-classes-base-0.6.2.0-laws.patch
@@ -0,0 +1,51 @@
+From b59ab822c261283004c2e87cffc653dc2b35c030 Mon Sep 17 00:00:00 2001
+From: Sergei Trofimovich <slyfox@gentoo.org>
+Date: Fri, 30 Jul 2021 23:23:19 +0100
+Subject: [PATCH] quickcheck-classes-base: move qe1_q under UNARY_LAWS define
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+In https://bugs.gentoo.org/804870 Toralf noticed a build failure:
+
+```
+ $ cabal build --flags=binary-laws --flags=-unary-laws
+ Configuring quickcheck-classes-base-0.6.2.0...
+ Preprocessing library for quickcheck-classes-base-0.6.2.0..
+ Building library for quickcheck-classes-base-0.6.2.0..
+ [ 1 of 30] Compiling Test.QuickCheck.Classes.Internal ( src/Test/QuickCheck/Classes/Internal.hs, dist/build/Test/QuickCheck/Classes/Internal.o, dist/build/Test/QuickCheck/Classes/Internal.dyn_o )
+
+ src/Test/QuickCheck/Classes/Internal.hs:79:5: error:
+ Not in scope: ‘eq1_2’
+ |
+ 79 | , eq1_2
+ | ^^^^^
+```
+
+In happens due to a mismatch between export and definition #ifdef guards.
+The change fised declaration to match definition.
+
+Reported-by: Toralf Förster
+Bug: https://bugs.gentoo.org/804870
+Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
+---
+ quickcheck-classes-base/src/Test/QuickCheck/Classes/Internal.hs | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/src/Test/QuickCheck/Classes/Internal.hs
++++ b/src/Test/QuickCheck/Classes/Internal.hs
+@@ -73,10 +73,10 @@ module Test.QuickCheck.Classes.Internal
+ , isTrue#
+ #if HAVE_UNARY_LAWS
+ , eq1
++ , eq1_2
+ #endif
+ #if HAVE_BINARY_LAWS
+ , eq2
+- , eq1_2
+ #endif
+ , readMaybe
+ ) where
+--
+2.32.0
+
diff --git a/dev-haskell/quickcheck-classes-base/metadata.xml b/dev-haskell/quickcheck-classes-base/metadata.xml
index 435de9480d90..26c36c8090b5 100644
--- a/dev-haskell/quickcheck-classes-base/metadata.xml
+++ b/dev-haskell/quickcheck-classes-base/metadata.xml
@@ -6,28 +6,7 @@
<name>Gentoo Haskell</name>
</maintainer>
<use>
+ <flag name="binary-laws">Include infrastructure for testing class laws of binary type constructors. Disabling `unary-laws` while keeping `binary-laws` enabled is an unsupported configuration.</flag>
<flag name="unary-laws">Include infrastructure for testing class laws of unary type constructors.</flag>
- <flag name="binary-laws">Include infrastructure for testing class laws of binary type constructors.
-Disabling `unary-laws` while keeping `binary-laws` enabled is an unsupported
-configuration.</flag>
</use>
- <longdescription>
- This libary is a minimal variant of `quickcheck-classes` that
- only provides laws for typeclasses from `base`. The main purpose
- of splitting this out is so that `primitive` can depend on
- `quickcheck-classes-base` in its test suite, avoiding the circular
- dependency that arises if `quickcheck-classes` is used instead.
-
- This library provides QuickCheck properties to ensure
- that typeclass instances adhere to the set of laws that
- they are supposed to. There are other libraries that do
- similar things, such as `genvalidity-hspec` and `checkers`.
- This library differs from other solutions by not introducing
- any new typeclasses that the user needs to learn.
-
- /Note:/ on GHC &lt; 8.5, this library uses the higher-kinded typeclasses
- ('Data.Functor.Classes.Show1', 'Data.Functor.Classes.Eq1', 'Data.Functor.Classes.Ord1', etc.),
- but on GHC &gt;= 8.5, it uses `-XQuantifiedConstraints` to express these
- constraints more cleanly.
- </longdescription>
</pkgmetadata>
diff --git a/dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.0.0.ebuild b/dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.2.0.ebuild
index 8b0c61a1e9d7..7bd0238e1887 100644
--- a/dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.0.0.ebuild
+++ b/dev-haskell/quickcheck-classes-base/quickcheck-classes-base-0.6.2.0.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-# ebuild generated by hackport 0.6.2
+# ebuild generated by hackport 0.6.7.9999
CABAL_FEATURES="lib profile haddock hoogle hscolour"
inherit haskell-cabal
@@ -17,21 +17,18 @@ SLOT="0/${PV}"
KEYWORDS="~amd64 ~x86"
IUSE="+binary-laws +unary-laws"
-RDEPEND=">=dev-haskell/base-orphans-0.1:=[profile?]
- dev-haskell/bifunctors:=[profile?]
- dev-haskell/contravariant:=[profile?]
- dev-haskell/fail:=[profile?]
- >=dev-haskell/semigroups-0.17:=[profile?]
- dev-haskell/tagged:=[profile?]
- >=dev-lang/ghc-8.0.1:=
+RDEPEND="dev-haskell/contravariant:=[profile?]
+ >=dev-lang/ghc-8.4.3:=
binary-laws? ( >=dev-haskell/quickcheck-2.10.0:2=[profile?] )
unary-laws? ( >=dev-haskell/quickcheck-2.10.0:2=[profile?] )
!unary-laws? ( !binary-laws? ( >=dev-haskell/quickcheck-2.7:2=[profile?] ) )
"
DEPEND="${RDEPEND}
- >=dev-haskell/cabal-1.24.0.0
+ >=dev-haskell/cabal-2.4
"
+PATCHES=("${FILESDIR}"/${P}-laws.patch)
+
src_configure() {
haskell-cabal_src_configure \
$(cabal_flag binary-laws binary-laws) \