haskell.compiler.ghc884: revert to reverse bootstraping using 8.10.2

Reverse bootstrapping is not supported by GHC upstream. In the case of
8.8.4 it just happens to work using 8.10.2, with later versions,
specifically 8.10.7 there seems to be some digressions in the generated /
used C code which cause 8.8.4 to fail to compile [1].

Thus we revert to using 8.10.2 for aarch64 and Musl which means: Still
no integer-simple and musl at the same time (however all other GHCs have
it, so it's probably not a problem) and no aarch64-darwin (GHC 8.8.4
can't target that architecture anyways). In short, the situation stays
the same.

[1]: https://github.com/NixOS/nixpkgs/pull/138523#issuecomment-927339953
This commit is contained in:
sternenseemann 2021-09-26 19:40:56 +02:00
parent 3fc911506a
commit 2034c06a0a
2 changed files with 6 additions and 2 deletions

View File

@ -346,6 +346,11 @@ stdenv.mkDerivation (rec {
] ++ lib.teams.haskell.members;
timeout = 24 * 3600;
inherit (ghc.meta) license platforms;
# integer-simple builds are broken with musl when bootstrapping using
# GHC 8.10.2 and below, however it is not possible to reverse bootstrap
# GHC 8.8.4 with GHC 8.10.7.
# See https://github.com/NixOS/nixpkgs/pull/138523#issuecomment-927339953
broken = hostPlatform.isMusl && enableIntegerSimple;
};
dontStrip = (targetPlatform.useAndroidPrebuilt || targetPlatform.isWasm);

View File

@ -73,10 +73,9 @@ in {
ghc884 = callPackage ../development/compilers/ghc/8.8.4.nix {
bootPkgs =
# aarch64 ghc865Binary gets SEGVs due to haskell#15449 or similar
# the oldest ghc with aarch64-darwin support is 8.10.5
# Musl bindists do not exist for ghc 8.6.5, so we use 8.10.* for them
if stdenv.isAarch64 || stdenv.hostPlatform.isMusl then
packages.ghc8107BinaryMinimal
packages.ghc8102BinaryMinimal
else
packages.ghc865Binary;
inherit (buildPackages.python3Packages) sphinx;