From b83efe1e00531db386b119fc00a13ab0353d9d8e Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 27 Dec 2020 10:08:11 +0000 Subject: [PATCH] dev-haskell/linear: allow new base-orphans-0.8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reported-by: Toralf Förster Closes: https://bugs.gentoo.org/761820 Package-Manager: Portage-3.0.12, Repoman-3.0.2 Signed-off-by: Sergei Trofimovich --- .../files/linear-1.20.9-base-orphans-0.8.3.patch | 13 +++++++++++++ dev-haskell/linear/linear-1.20.9.ebuild | 2 ++ 2 files changed, 15 insertions(+) create mode 100644 dev-haskell/linear/files/linear-1.20.9-base-orphans-0.8.3.patch diff --git a/dev-haskell/linear/files/linear-1.20.9-base-orphans-0.8.3.patch b/dev-haskell/linear/files/linear-1.20.9-base-orphans-0.8.3.patch new file mode 100644 index 0000000000000..c497de0b36a40 --- /dev/null +++ b/dev-haskell/linear/files/linear-1.20.9-base-orphans-0.8.3.patch @@ -0,0 +1,13 @@ +--- a/src/Linear/Instances.hs ++++ b/src/Linear/Instances.hs +@@ -21,8 +21,10 @@ import Control.Monad.Zip + import Data.Complex + import Data.Orphans () + ++#if ! MIN_VERSION_base_orphans(0,8,3) + instance MonadZip Complex where + mzipWith = liftA2 + + instance MonadFix Complex where + mfix f = (let a :+ _ = f a in a) :+ (let _ :+ a = f a in a) ++#endif diff --git a/dev-haskell/linear/linear-1.20.9.ebuild b/dev-haskell/linear/linear-1.20.9.ebuild index ebf29418bf02f..2a04c9081129f 100644 --- a/dev-haskell/linear/linear-1.20.9.ebuild +++ b/dev-haskell/linear/linear-1.20.9.ebuild @@ -47,6 +47,8 @@ DEPEND="${RDEPEND} >=dev-haskell/test-framework-hunit-0.3 ) " +PATCHES=("${FILESDIR}"/${P}-base-orphans-0.8.3.patch) + src_configure() { haskell-cabal_src_configure \ --flag=-herbie \