Skip to content

Commit e65abfd

Browse files
diegodivjaschutte
authored andcommitted
Update flake.nix to make GHC 9.10.1 and GHC 9.8.2 available (#2810)
* Update GHC 9.6.2 to 9.6.6. * Enable GHC 9.8.2 and remove GHC 9.0.2. * Export ghcVersion from flake.nix. * Remove Hackage calls for packages already in nixpkgs. * Add GHC 9.10.1. * Add comments to overlays. * Make GHC 9.10 the default in flake.nix. * Remove commented code.
1 parent dd48692 commit e65abfd

File tree

5 files changed

+32
-80
lines changed

5 files changed

+32
-80
lines changed

flake.lock

Lines changed: 21 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,9 @@
8383
in
8484
assert pkgs.lib.asserts.assertOneOf "defaultGhcVersion" defaultGhcVersion ghcVersions;
8585
{
86+
# Export the variable so that other flakes can use it.
87+
ghcVersion = defaultGhcVersion;
88+
8689
packages = {
8790
inherit (pkgs."clashPackages-${defaultGhcVersion}")
8891
clash-benchmark

nix/overlay-ghc910.nix

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@ in
2525
hedgehog-fakedata = doJailbreak (markUnbroken prev.hedgehog-fakedata);
2626

2727
# Fails on GHC 9.10 with:
28-
# library/Text/Regex/PCRE/Heavy.hs:123: failure in expression `head $ scan [re|\s*entry (\d+) (\w+)\s*&?|] (" entry 1 hello &entry 2 hi" :: String)'
29-
# expected: (" entry 1 hello &",["1","hello"])
30-
# but got: <interactive>:55:1: warning: [GHC-63394] [-Wx-partial]
31-
# ^
32-
# In the use of ‘head’
28+
# library/Text/Regex/PCRE/Heavy.hs:123: failure in expression `head $ scan [re|\s*entry (\d+) (\w+)\s*&?|] (" entry 1 hello &entry 2 hi" :: String)'
29+
# expected: (" entry 1 hello &",["1","hello"])
30+
# but got: <interactive>:55:1: warning: [GHC-63394] [-Wx-partial]
31+
# ^
32+
# In the use of ‘head’
3333
# (imported from Prelude.Compat, but defined in GHC.Internal.List):
3434
# "This is a partial function, it throws an error on empty lists. Use pattern matching, 'Data.List.uncons' or 'Data.Maybe.listToMaybe' instead. Consider refactoring to use "Data.List.NonEmpty"."
3535
# (" entry 1 hello &",["1","hello"])
36-
36+
3737
pcre-heavy = dontCheck prev.pcre-heavy;
3838

3939
# Relies on older versions of text.
@@ -46,17 +46,6 @@ in
4646

4747
th-desugar = prev.th-desugar_1_17;
4848

49-
# We need a new tasty-flaky. The one from Hackage doesn't build for some weird
50-
# reason..
51-
tasty-flaky = prev.callCabal2nix "tasty-flaky" (pkgs.fetchFromGitHub {
52-
owner = "LaurentRDC";
53-
repo = "tasty-flaky";
54-
rev = "fc31a9d622c1eb60030a50152258a9bef785e365";
55-
sha256 = "sha256-irLM3aVMxpBgsM72ArulMXcoLY2glalVkG//Lrj2JBI=";
56-
}) {};
57-
58-
tasty = prev.tasty_1_5;
59-
6049
singletons-th = prev.singletons-th_3_4;
6150

6251
# nixplgs doesn't include revision 1, changing dependency on template-haskell.

nix/overlay-ghc96.nix

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{ pkgs }:
22
final: prev:
33
let
4-
inherit (pkgs.haskell.lib) doJailbreak markUnbroken dontCheck;
4+
inherit (pkgs.haskell.lib) doJailbreak markUnbroken;
55
in
66
{
77
# Use an older version than the default in nixpkgs. Since rewrite-inspector
@@ -41,24 +41,4 @@ in
4141

4242
# Marken as broken, but compiles anyway.
4343
hedgehog-fakedata = doJailbreak (markUnbroken prev.hedgehog-fakedata);
44-
45-
# We need a new tasty-flaky. The one from Hackage doesn't build for some weird
46-
# reason..
47-
tasty-flaky = prev.callCabal2nix "tasty-flaky" (pkgs.fetchFromGitHub {
48-
owner = "LaurentRDC";
49-
repo = "tasty-flaky";
50-
rev = "fc31a9d622c1eb60030a50152258a9bef785e365";
51-
sha256 = "sha256-irLM3aVMxpBgsM72ArulMXcoLY2glalVkG//Lrj2JBI=";
52-
}) {};
53-
54-
# This version of tasty isn't available in the nix ghc96 package set
55-
tasty = prev.callHackageDirect {
56-
pkg = "tasty";
57-
ver = "1.5.3";
58-
sha256 = "sha256-Ogd8J4aHNeL+xmcRWuJeGBNaePyLs5yo1IoMzvWrVPY=";
59-
} {};
60-
61-
# The tests (not the package itself!) require a tasty <1.5, which won't work as we pull in
62-
# tasty 1.5.3. Solution: don't test!
63-
time-compat = dontCheck prev.time-compat;
6444
}

nix/overlay-ghc98.nix

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{ pkgs }:
22
final: prev:
33
let
4-
inherit (pkgs.haskell.lib) doJailbreak markUnbroken dontCheck;
4+
inherit (pkgs.haskell.lib) doJailbreak markUnbroken;
55
in
66
{
77
# Use an older version than the default in nixpkgs. Since rewrite-inspector
@@ -20,24 +20,4 @@ in
2020

2121
# Marken as broken, but compiles anyway.
2222
hedgehog-fakedata = doJailbreak (markUnbroken prev.hedgehog-fakedata);
23-
24-
# We need a new tasty-flaky. The one from Hackage doesn't build for some weird
25-
# reason..
26-
tasty-flaky = prev.callCabal2nix "tasty-flaky" (pkgs.fetchFromGitHub {
27-
owner = "LaurentRDC";
28-
repo = "tasty-flaky";
29-
rev = "fc31a9d622c1eb60030a50152258a9bef785e365";
30-
sha256 = "sha256-irLM3aVMxpBgsM72ArulMXcoLY2glalVkG//Lrj2JBI=";
31-
}) {};
32-
33-
# This version of tasty isn't available in the nix ghc96 package set
34-
tasty = prev.callHackageDirect {
35-
pkg = "tasty";
36-
ver = "1.5.3";
37-
sha256 = "sha256-Ogd8J4aHNeL+xmcRWuJeGBNaePyLs5yo1IoMzvWrVPY=";
38-
} {};
39-
40-
# The tests (not the package itself!) require a tasty <1.5, which won't work as we pull in
41-
# tasty 1.5.3. Solution: don't test!
42-
time-compat = dontCheck prev.time-compat;
4323
}

0 commit comments

Comments
 (0)