diff --git a/pkgs/build-support/cabal/default.nix b/pkgs/build-support/cabal/default.nix index 38f2c4c6115..c1b8d6d5fea 100644 --- a/pkgs/build-support/cabal/default.nix +++ b/pkgs/build-support/cabal/default.nix @@ -92,13 +92,12 @@ # pass the '--enable-tests' flag to cabal in the configure stage # and run any regression test suites the package might have - doCheck = true; + doCheck = stdenv.lib.versionOlder "7" ghc.ghcVersion; extraConfigureFlags = [ (stdenv.lib.enableFeature enableLibraryProfiling "library-profiling") (stdenv.lib.enableFeature self.enableSplitObjs "split-objs") - (stdenv.lib.enableFeature self.doCheck "tests") - ]; + ] ++ stdenv.lib.optional (stdenv.lib.versionOlder "7" ghc.ghcVersion) (stdenv.lib.enableFeature self.doCheck "tests"); # compiles Setup and configures configurePhase = ''