From 669f9453dc94c5ab24a425536b98c7f4d5cce359 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Tue, 15 May 2018 03:28:39 +0200 Subject: [PATCH] haskellPackages.hnix: jailbreak & fix tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Some of the new tests need the `nix` executable on `PATH`. One also needs `hpack`, but we really don’t want to embiggen (heh) the closure because of that. --- .../haskell-modules/configuration-common.nix | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index c18c69f9a44..8278b4bdc5e 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -208,6 +208,9 @@ self: super: { # https://github.com/jputcu/serialport/issues/25 serialport = dontCheck super.serialport; + serialise = dontCheck super.serialise; + cryptohash-sha512 = dontCheck super.cryptohash-sha512; + # https://github.com/kazu-yamamoto/simple-sendfile/issues/17 simple-sendfile = dontCheck super.simple-sendfile; @@ -247,7 +250,17 @@ self: super: { digit = doJailbreak super.digit; # https://github.com/jwiegley/hnix/issues/98 - tied to an older deriving-compat - hnix = doJailbreak super.hnix; + hnix = doJailbreak (overrideCabal super.hnix (old: { + patches = old.patches or [] ++ [ + # should land in hnix-5.2 + (pkgs.fetchpatch { + url = "https://github.com/haskell-nix/hnix/commit/9cfe060a9dbe9e7c64867956a0523eed9661803a.patch"; + sha256 = "0ci4n7nw2pzqw0gkmkp4szzvxjyb143a4znjm39jmb0s397a68sh"; + name = "disable-hpack-test-by-default.patch"; + }) + ]; + testHaskellDepends = old.testHaskellDepends or [] ++ [ pkgs.nix ]; + })); # Fails for non-obvious reasons while attempting to use doctest. search = dontCheck super.search;