base16-schemes: unstable-2024-06-21 -> unstable-2024-11-12 (#356361)
[NixPkgs.git] / pkgs / top-level / haskell-packages.nix
blobb3f6a71d3315d08385574a0a8d0d936be088dd68
1 { buildPackages, pkgsBuildBuild, pkgsBuildTarget, pkgs, newScope, stdenv }:
3 let
4   # These are attributes in compiler that support integer-simple.
5   integerSimpleIncludes = [
6     "ghc88"
7     "ghc884"
8     "ghc810"
9     "ghc8107"
10   ];
12   nativeBignumExcludes = integerSimpleIncludes ++ [
13     # haskell.compiler sub groups
14     "integer-simple"
15     "native-bignum"
16     # Binary GHCs
17     "ghc865Binary"
18     "ghc8107Binary"
19     "ghc924Binary"
20     "ghc963Binary"
21     # ghcjs
22     "ghcjs"
23     "ghcjs810"
24   ];
26   haskellLibUncomposable = import ../development/haskell-modules/lib {
27     inherit (pkgs) lib;
28     inherit pkgs;
29   };
31   callPackage = newScope {
32     haskellLib = haskellLibUncomposable.compose;
33     overrides = pkgs.haskell.packageOverrides;
34   };
36   bootstrapPackageSet = self: super: {
37     mkDerivation = drv: super.mkDerivation (drv // {
38       doCheck = false;
39       doHaddock = false;
40       enableExecutableProfiling = false;
41       enableLibraryProfiling = false;
42       enableSharedExecutables = false;
43       enableSharedLibraries = false;
44     });
45   };
47   # Use this rather than `rec { ... }` below for sake of overlays.
48   inherit (pkgs.haskell) compiler packages;
50 in {
51   lib = haskellLibUncomposable;
53   package-list = callPackage ../development/haskell-modules/package-list.nix {};
55   # Always get boot compilers from `pkgsBuildBuild`. The boot (stage0) compiler
56   # is used to build another compiler (stage1) that'll be used to build the
57   # final compiler (stage2) (except when building a cross-compiler). This means
58   # that stage1's host platform is the same as stage0: build. Consequently,
59   # stage0 needs to be build->build.
60   #
61   # Note that we use bb.haskell.packages.*. haskell.packages.*.ghc is similar to
62   # stdenv: The ghc comes from the previous package set, i.e. this predicate holds:
63   # `name: pkgs: pkgs.haskell.packages.${name}.ghc == pkgs.buildPackages.haskell.compiler.${name}.ghc`.
64   # This isn't problematic since pkgsBuildBuild.buildPackages is also build->build,
65   # just something to keep in mind.
66   compiler = let bb = pkgsBuildBuild.haskell; in {
67     ghc865Binary = callPackage ../development/compilers/ghc/8.6.5-binary.nix {
68       # Should be llvmPackages_6 which has been removed from nixpkgs
69       llvmPackages = null;
70     };
72     ghc8107Binary = callPackage ../development/compilers/ghc/8.10.7-binary.nix {
73       llvmPackages = pkgs.llvmPackages_12;
74     };
76     ghc924Binary = callPackage ../development/compilers/ghc/9.2.4-binary.nix {
77       llvmPackages = pkgs.llvmPackages_12;
78     };
80     ghc963Binary = callPackage ../development/compilers/ghc/9.6.3-binary.nix {
81       llvmPackages = pkgs.llvmPackages_15;
82     };
84     ghc8107 = callPackage ../development/compilers/ghc/8.10.7.nix {
85       bootPkgs =
86         # the oldest ghc with aarch64-darwin support is 8.10.5
87         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
88           # to my (@a-m-joseph) knowledge there are no newer official binaries for this platform
89           bb.packages.ghc865Binary
90         else
91           bb.packages.ghc8107Binary;
92       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
93       python3 = buildPackages.python311; # so that we don't have two of them
94       # Need to use apple's patched xattr until
95       # https://github.com/xattr/xattr/issues/44 and
96       # https://github.com/xattr/xattr/issues/55 are solved.
97       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
98       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
99       llvmPackages = pkgs.llvmPackages_12;
100     };
101     ghc810 = compiler.ghc8107;
102     ghc902 = callPackage ../development/compilers/ghc/9.0.2.nix {
103       bootPkgs =
104         # the oldest ghc with aarch64-darwin support is 8.10.5
105         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
106           bb.packages.ghc810
107         else
108           bb.packages.ghc8107Binary;
109       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
110       python3 = buildPackages.python311; # so that we don't have two of them
111       inherit (buildPackages.darwin) autoSignDarwinBinariesHook xattr;
112       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
113       llvmPackages = pkgs.llvmPackages_12;
114     };
115     ghc90 = compiler.ghc902;
116     ghc925 = callPackage ../development/compilers/ghc/9.2.5.nix {
117       bootPkgs =
118         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
119           bb.packages.ghc810
120         else
121           bb.packages.ghc8107Binary;
122       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
123       python3 = buildPackages.python311; # so that we don't have two of them
124       # Need to use apple's patched xattr until
125       # https://github.com/xattr/xattr/issues/44 and
126       # https://github.com/xattr/xattr/issues/55 are solved.
127       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
128       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
129       llvmPackages = pkgs.llvmPackages_12;
130     };
131     ghc926 = callPackage ../development/compilers/ghc/9.2.6.nix {
132       bootPkgs =
133         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
134           bb.packages.ghc810
135         else
136           bb.packages.ghc8107Binary;
137       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
138       python3 = buildPackages.python311; # so that we don't have two of them
139       # Need to use apple's patched xattr until
140       # https://github.com/xattr/xattr/issues/44 and
141       # https://github.com/xattr/xattr/issues/55 are solved.
142       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
143       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
144       llvmPackages = pkgs.llvmPackages_12;
145     };
146     ghc927 = callPackage ../development/compilers/ghc/9.2.7.nix {
147       bootPkgs =
148         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
149           bb.packages.ghc810
150         else
151           bb.packages.ghc8107Binary;
152       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
153       python3 = buildPackages.python311; # so that we don't have two of them
154       # Need to use apple's patched xattr until
155       # https://github.com/xattr/xattr/issues/44 and
156       # https://github.com/xattr/xattr/issues/55 are solved.
157       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
158       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
159       llvmPackages = pkgs.llvmPackages_12;
160     };
161     ghc928 = callPackage ../development/compilers/ghc/9.2.8.nix {
162       bootPkgs =
163         if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
164           bb.packages.ghc810
165         else
166           bb.packages.ghc8107Binary;
167       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
168       python3 = buildPackages.python311; # so that we don't have two of them
169       # Need to use apple's patched xattr until
170       # https://github.com/xattr/xattr/issues/44 and
171       # https://github.com/xattr/xattr/issues/55 are solved.
172       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
173       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
174       llvmPackages = pkgs.llvmPackages_12;
175     };
176     ghc92 = compiler.ghc928;
177     ghc945 = callPackage ../development/compilers/ghc/9.4.5.nix {
178       bootPkgs =
179         # Building with 9.2 is broken due to
180         # https://gitlab.haskell.org/ghc/ghc/-/issues/21914
181         # Use 8.10 as a workaround where possible to keep bootstrap path short.
183         # On ARM text won't build with GHC 8.10.*
184         if stdenv.buildPlatform.isAarch then
185           # TODO(@sternenseemann): package bindist
186           bb.packages.ghc902
187         # No suitable bindists for powerpc64le
188         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
189           bb.packages.ghc902
190         else
191           bb.packages.ghc8107Binary;
192       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
193       python3 = buildPackages.python311; # so that we don't have two of them
194       # Need to use apple's patched xattr until
195       # https://github.com/xattr/xattr/issues/44 and
196       # https://github.com/xattr/xattr/issues/55 are solved.
197       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
198       # Support range >= 10 && < 14
199       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
200       llvmPackages = pkgs.llvmPackages_12;
201     };
202     ghc946 = callPackage ../development/compilers/ghc/9.4.6.nix {
203       bootPkgs =
204         # Building with 9.2 is broken due to
205         # https://gitlab.haskell.org/ghc/ghc/-/issues/21914
206         # Use 8.10 as a workaround where possible to keep bootstrap path short.
208         # On ARM text won't build with GHC 8.10.*
209         if stdenv.buildPlatform.isAarch then
210           # TODO(@sternenseemann): package bindist
211           bb.packages.ghc902
212         # No suitable bindists for powerpc64le
213         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
214           bb.packages.ghc902
215         else
216           bb.packages.ghc8107Binary;
217       inherit (buildPackages.python311Packages) sphinx; # a distutils issue with 3.12
218       python3 = buildPackages.python311; # so that we don't have two of them
219       # Need to use apple's patched xattr until
220       # https://github.com/xattr/xattr/issues/44 and
221       # https://github.com/xattr/xattr/issues/55 are solved.
222       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
223       # Support range >= 10 && < 14
224       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
225       llvmPackages = pkgs.llvmPackages_12;
226     };
227     ghc947 = callPackage ../development/compilers/ghc/9.4.7.nix {
228       bootPkgs =
229         # Building with 9.2 is broken due to
230         # https://gitlab.haskell.org/ghc/ghc/-/issues/21914
231         # Use 8.10 as a workaround where possible to keep bootstrap path short.
233         # On ARM text won't build with GHC 8.10.*
234         if stdenv.buildPlatform.isAarch then
235           # TODO(@sternenseemann): package bindist
236           bb.packages.ghc902
237         # No suitable bindists for powerpc64le
238         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
239           bb.packages.ghc902
240         else
241           bb.packages.ghc8107Binary;
242       inherit (buildPackages.python3Packages) sphinx;
243       # Need to use apple's patched xattr until
244       # https://github.com/xattr/xattr/issues/44 and
245       # https://github.com/xattr/xattr/issues/55 are solved.
246       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
247       # Support range >= 10 && < 14
248       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
249       llvmPackages = pkgs.llvmPackages_12;
250     };
251     ghc948 = callPackage ../development/compilers/ghc/9.4.8.nix {
252       bootPkgs =
253         # Building with 9.2 is broken due to
254         # https://gitlab.haskell.org/ghc/ghc/-/issues/21914
255         # Use 8.10 as a workaround where possible to keep bootstrap path short.
257         # On ARM text won't build with GHC 8.10.*
258         if stdenv.buildPlatform.isAarch then
259           # TODO(@sternenseemann): package bindist
260           bb.packages.ghc902
261         # No suitable bindists for powerpc64le
262         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
263           bb.packages.ghc902
264         else
265           bb.packages.ghc8107Binary;
266       inherit (buildPackages.python3Packages) sphinx;
267       # Need to use apple's patched xattr until
268       # https://github.com/xattr/xattr/issues/44 and
269       # https://github.com/xattr/xattr/issues/55 are solved.
270       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
271       # Support range >= 10 && < 14
272       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
273       llvmPackages = pkgs.llvmPackages_12;
274     };
275     ghc94 = compiler.ghc948;
276     ghc963 = callPackage ../development/compilers/ghc/9.6.3.nix {
277       bootPkgs =
278         # For GHC 9.2 no armv7l bindists are available.
279         if stdenv.buildPlatform.isAarch32 then
280           bb.packages.ghc928
281         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
282           bb.packages.ghc928
283         else
284           bb.packages.ghc924Binary;
285       inherit (buildPackages.python3Packages) sphinx;
286       # Need to use apple's patched xattr until
287       # https://github.com/xattr/xattr/issues/44 and
288       # https://github.com/xattr/xattr/issues/55 are solved.
289       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
290       # Support range >= 11 && < 16
291       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
292       llvmPackages = pkgs.llvmPackages_15;
293     };
294     ghc964 = callPackage ../development/compilers/ghc/9.6.4.nix {
295       bootPkgs =
296         # For GHC 9.2 no armv7l bindists are available.
297         if stdenv.buildPlatform.isAarch32 then
298           bb.packages.ghc928
299         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
300           bb.packages.ghc928
301         else
302           bb.packages.ghc924Binary;
303       inherit (buildPackages.python3Packages) sphinx;
304       # Need to use apple's patched xattr until
305       # https://github.com/xattr/xattr/issues/44 and
306       # https://github.com/xattr/xattr/issues/55 are solved.
307       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
308       # Support range >= 11 && < 16
309       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
310       llvmPackages = pkgs.llvmPackages_15;
311     };
312     ghc965 = callPackage ../development/compilers/ghc/9.6.5.nix {
313       bootPkgs =
314         # For GHC 9.2 no armv7l bindists are available.
315         if stdenv.buildPlatform.isAarch32 then
316           bb.packages.ghc928
317         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
318           bb.packages.ghc928
319         else
320           bb.packages.ghc924Binary;
321       inherit (buildPackages.python3Packages) sphinx;
322       # Need to use apple's patched xattr until
323       # https://github.com/xattr/xattr/issues/44 and
324       # https://github.com/xattr/xattr/issues/55 are solved.
325       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
326       # Support range >= 11 && < 16
327       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
328       llvmPackages = pkgs.llvmPackages_15;
329     };
330     ghc966 = callPackage ../development/compilers/ghc/9.6.6.nix {
331       bootPkgs =
332         # For GHC 9.2 no armv7l bindists are available.
333         if stdenv.buildPlatform.isAarch32 then
334           bb.packages.ghc928
335         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
336           bb.packages.ghc928
337         else
338           bb.packages.ghc924Binary;
339       inherit (buildPackages.python3Packages) sphinx;
340       # Need to use apple's patched xattr until
341       # https://github.com/xattr/xattr/issues/44 and
342       # https://github.com/xattr/xattr/issues/55 are solved.
343       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
344       # Support range >= 11 && < 16
345       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
346       llvmPackages = pkgs.llvmPackages_15;
347     };
348     ghc96 = compiler.ghc966;
349     ghc981 = callPackage ../development/compilers/ghc/9.8.1.nix {
350       bootPkgs =
351         # For GHC 9.6 no armv7l bindists are available.
352         if stdenv.buildPlatform.isAarch32 then
353           bb.packages.ghc963
354         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
355           bb.packages.ghc963
356         else
357           bb.packages.ghc963Binary;
358       inherit (buildPackages.python3Packages) sphinx;
359       # Need to use apple's patched xattr until
360       # https://github.com/xattr/xattr/issues/44 and
361       # https://github.com/xattr/xattr/issues/55 are solved.
362       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
363       # Support range >= 11 && < 16
364       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
365       llvmPackages = pkgs.llvmPackages_15;
366     };
367     ghc982 = callPackage ../development/compilers/ghc/9.8.2.nix {
368       bootPkgs =
369         # For GHC 9.6 no armv7l bindists are available.
370         if stdenv.buildPlatform.isAarch32 then
371           bb.packages.ghc963
372         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
373           bb.packages.ghc963
374         else
375           bb.packages.ghc963Binary;
376       inherit (buildPackages.python3Packages) sphinx;
377       # Need to use apple's patched xattr until
378       # https://github.com/xattr/xattr/issues/44 and
379       # https://github.com/xattr/xattr/issues/55 are solved.
380       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
381       # Support range >= 11 && < 16
382       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
383       llvmPackages = pkgs.llvmPackages_15;
384     };
385     ghc983 = callPackage ../development/compilers/ghc/9.8.3.nix {
386       bootPkgs =
387         # For GHC 9.6 no armv7l bindists are available.
388         if stdenv.buildPlatform.isAarch32 then
389           bb.packages.ghc963
390         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
391           bb.packages.ghc963
392         else
393           bb.packages.ghc963Binary;
394       inherit (buildPackages.python3Packages) sphinx;
395       # Need to use apple's patched xattr until
396       # https://github.com/xattr/xattr/issues/44 and
397       # https://github.com/xattr/xattr/issues/55 are solved.
398       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
399       # Support range >= 11 && < 16
400       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
401       llvmPackages = pkgs.llvmPackages_15;
402     };
403     ghc98 = compiler.ghc982; # HLS doesn't work yet with 9.8.3
404     ghc9101 = callPackage ../development/compilers/ghc/9.10.1.nix {
405       bootPkgs =
406         # For GHC 9.6 no armv7l bindists are available.
407         if stdenv.buildPlatform.isAarch32 then
408           bb.packages.ghc963
409         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
410           bb.packages.ghc963
411         else if stdenv.buildPlatform.isDarwin then
412           # it seems like the GHC 9.6.* bindists are built with a different
413           # toolchain than we are using (which I'm guessing from the fact
414           # that 9.6.4 bindists pass linker flags our ld doesn't support).
415           # With both 9.6.3 and 9.6.4 binary it is impossible to link against
416           # the clock package (probably a hsc2hs problem).
417           bb.packages.ghc963
418         else
419           bb.packages.ghc963Binary;
420       inherit (buildPackages.python3Packages) sphinx;
421       # Need to use apple's patched xattr until
422       # https://github.com/xattr/xattr/issues/44 and
423       # https://github.com/xattr/xattr/issues/55 are solved.
424       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
425       # 2023-01-15: Support range >= 11 && < 16
426       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15;
427       llvmPackages = pkgs.llvmPackages_15;
428     };
429     ghc910 = compiler.ghc9101;
430     ghcHEAD = callPackage ../development/compilers/ghc/head.nix {
431       bootPkgs =
432         # For GHC 9.6 no armv7l bindists are available.
433         if stdenv.buildPlatform.isAarch32 then
434           bb.packages.ghc963
435         else if stdenv.buildPlatform.isPower64 && stdenv.buildPlatform.isLittleEndian then
436           bb.packages.ghc963
437         else
438           bb.packages.ghc963Binary;
439       inherit (buildPackages.python3Packages) sphinx;
440       # Need to use apple's patched xattr until
441       # https://github.com/xattr/xattr/issues/44 and
442       # https://github.com/xattr/xattr/issues/55 are solved.
443       inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
444       # 2023-01-15: Support range >= 11 && < 16
445       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_18;
446       llvmPackages = pkgs.llvmPackages_18;
447     };
449     ghcjs = compiler.ghcjs810;
450     ghcjs810 = callPackage ../development/compilers/ghcjs/8.10 {
451       bootPkgs = bb.packages.ghc810;
452       ghcjsSrcJson = ../development/compilers/ghcjs/8.10/git.json;
453       stage0 = ../development/compilers/ghcjs/8.10/stage0.nix;
454     };
456     # The integer-simple attribute set contains all the GHC compilers
457     # build with integer-simple instead of integer-gmp.
458     integer-simple = let
459       integerSimpleGhcNames = pkgs.lib.filter
460         (name: builtins.elem name integerSimpleIncludes)
461         (pkgs.lib.attrNames compiler);
462     in pkgs.recurseIntoAttrs (pkgs.lib.genAttrs
463       integerSimpleGhcNames
464       (name: compiler.${name}.override { enableIntegerSimple = true; }));
466     # Starting from GHC 9, integer-{simple,gmp} is replaced by ghc-bignum
467     # with "native" and "gmp" backends.
468     native-bignum = let
469       nativeBignumGhcNames = pkgs.lib.filter
470         (name: !(builtins.elem name nativeBignumExcludes))
471         (pkgs.lib.attrNames compiler);
472     in pkgs.recurseIntoAttrs (pkgs.lib.genAttrs
473       nativeBignumGhcNames
474       (name: compiler.${name}.override { enableNativeBignum = true; }));
475   };
477   # Default overrides that are applied to all package sets.
478   packageOverrides = self : super : {};
480   # Always get compilers from `buildPackages`
481   packages = let bh = buildPackages.haskell; in {
483     ghc865Binary = callPackage ../development/haskell-modules {
484       buildHaskellPackages = bh.packages.ghc865Binary;
485       ghc = bh.compiler.ghc865Binary;
486       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-8.6.x.nix { };
487       packageSetConfig = bootstrapPackageSet;
488     };
489     ghc8107Binary = callPackage ../development/haskell-modules {
490       buildHaskellPackages = bh.packages.ghc8107Binary;
491       ghc = bh.compiler.ghc8107Binary;
492       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-8.10.x.nix { };
493       packageSetConfig = bootstrapPackageSet;
494     };
495     ghc924Binary = callPackage ../development/haskell-modules {
496       buildHaskellPackages = bh.packages.ghc924Binary;
497       ghc = bh.compiler.ghc924Binary;
498       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
499       packageSetConfig = bootstrapPackageSet;
500     };
501     ghc963Binary = callPackage ../development/haskell-modules {
502       buildHaskellPackages = bh.packages.ghc963Binary;
503       ghc = bh.compiler.ghc963Binary;
504       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { };
505       packageSetConfig = bootstrapPackageSet;
506     };
507     ghc8107 = callPackage ../development/haskell-modules {
508       buildHaskellPackages = bh.packages.ghc8107;
509       ghc = bh.compiler.ghc8107;
510       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-8.10.x.nix { };
511     };
512     ghc810 = packages.ghc8107;
513     ghc902 = callPackage ../development/haskell-modules {
514       buildHaskellPackages = bh.packages.ghc902;
515       ghc = bh.compiler.ghc902;
516       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.0.x.nix { };
517     };
518     ghc90 = packages.ghc902;
519     ghc925 = callPackage ../development/haskell-modules {
520       buildHaskellPackages = bh.packages.ghc925;
521       ghc = bh.compiler.ghc925;
522       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
523     };
524     ghc926 = callPackage ../development/haskell-modules {
525       buildHaskellPackages = bh.packages.ghc926;
526       ghc = bh.compiler.ghc926;
527       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
528     };
529     ghc927 = callPackage ../development/haskell-modules {
530       buildHaskellPackages = bh.packages.ghc927;
531       ghc = bh.compiler.ghc927;
532       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
533     };
534     ghc928 = callPackage ../development/haskell-modules {
535       buildHaskellPackages = bh.packages.ghc928;
536       ghc = bh.compiler.ghc928;
537       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
538     };
539     ghc92 = packages.ghc928;
540     ghc945 = callPackage ../development/haskell-modules {
541       buildHaskellPackages = bh.packages.ghc945;
542       ghc = bh.compiler.ghc945;
543       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
544     };
545     ghc946 = callPackage ../development/haskell-modules {
546       buildHaskellPackages = bh.packages.ghc946;
547       ghc = bh.compiler.ghc946;
548       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
549     };
550     ghc947 = callPackage ../development/haskell-modules {
551       buildHaskellPackages = bh.packages.ghc947;
552       ghc = bh.compiler.ghc947;
553       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
554     };
555     ghc948 = callPackage ../development/haskell-modules {
556       buildHaskellPackages = bh.packages.ghc948;
557       ghc = bh.compiler.ghc948;
558       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
559     };
560     ghc94 = packages.ghc948;
561     ghc963 = callPackage ../development/haskell-modules {
562       buildHaskellPackages = bh.packages.ghc963;
563       ghc = bh.compiler.ghc963;
564       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { };
565     };
566     ghc964 = callPackage ../development/haskell-modules {
567       buildHaskellPackages = bh.packages.ghc964;
568       ghc = bh.compiler.ghc964;
569       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { };
570     };
571     ghc965 = callPackage ../development/haskell-modules {
572       buildHaskellPackages = bh.packages.ghc965;
573       ghc = bh.compiler.ghc965;
574       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { };
575     };
576     ghc966 = callPackage ../development/haskell-modules {
577       buildHaskellPackages = bh.packages.ghc966;
578       ghc = bh.compiler.ghc966;
579       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { };
580     };
581     ghc96 = packages.ghc966;
582     ghc981 = callPackage ../development/haskell-modules {
583       buildHaskellPackages = bh.packages.ghc981;
584       ghc = bh.compiler.ghc981;
585       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.8.x.nix { };
586     };
587     ghc982 = callPackage ../development/haskell-modules {
588       buildHaskellPackages = bh.packages.ghc982;
589       ghc = bh.compiler.ghc982;
590       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.8.x.nix { };
591     };
592     ghc983 = callPackage ../development/haskell-modules {
593       buildHaskellPackages = bh.packages.ghc983;
594       ghc = bh.compiler.ghc983;
595       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.8.x.nix { };
596     };
597     ghc98 = packages.ghc982; # HLS doesn't work yet with 9.8.3
598     ghc9101 = callPackage ../development/haskell-modules {
599       buildHaskellPackages = bh.packages.ghc9101;
600       ghc = bh.compiler.ghc9101;
601       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.10.x.nix { };
602     };
603     ghc910 = packages.ghc9101;
604     ghcHEAD = callPackage ../development/haskell-modules {
605       buildHaskellPackages = bh.packages.ghcHEAD;
606       ghc = bh.compiler.ghcHEAD;
607       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.12.x.nix { };
608     };
610     ghcjs = packages.ghcjs810;
611     ghcjs810 = callPackage ../development/haskell-modules rec {
612       buildHaskellPackages = ghc.bootPkgs;
613       ghc = bh.compiler.ghcjs810;
614       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-8.10.x.nix { };
615       packageSetConfig = callPackage ../development/haskell-modules/configuration-ghcjs-8.x.nix { };
616     };
618     # The integer-simple attribute set contains package sets for all the GHC compilers
619     # using integer-simple instead of integer-gmp.
620     integer-simple =
621       let
622         integerSimpleGhcNames = pkgs.lib.filter
623           (name: builtins.elem name integerSimpleIncludes)
624           (pkgs.lib.attrNames packages);
625       in
626       pkgs.lib.genAttrs integerSimpleGhcNames
627         (name:
628           packages.${name}.override (oldAttrs: {
629             ghc = bh.compiler.integer-simple.${name};
630             buildHaskellPackages = bh.packages.integer-simple.${name};
631             overrides =
632               pkgs.lib.composeExtensions
633                 (oldAttrs.overrides or (_: _: {}))
634                 (_: _: { integer-simple = null; });
635           })
636         );
638     native-bignum =
639       let
640         nativeBignumGhcNames = pkgs.lib.filter
641           (name: !(builtins.elem name nativeBignumExcludes))
642           (pkgs.lib.attrNames compiler);
643       in
644       pkgs.lib.genAttrs nativeBignumGhcNames
645         (name:
646           packages.${name}.override {
647             ghc = bh.compiler.native-bignum.${name};
648             buildHaskellPackages = bh.packages.native-bignum.${name};
649           }
650         );
651   };