about summary refs log tree commit diff
path: root/pkgs/top-level/haskell-packages.nix
diff options
context:
space:
mode:
authorsternenseemann <sternenseemann@systemli.org>2022-11-09 01:42:43 +0100
committersternenseemann <sternenseemann@systemli.org>2022-11-09 23:44:01 +0100
commit3d361be06a18752bc97a5a484d29fc279b0446d0 (patch)
tree9ef1d5519a88a02bbaea27a1bf10054d0ffaea9f /pkgs/top-level/haskell-packages.nix
parentb11e56a75c6768340906894681982335630b58c8 (diff)
downloadnixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar.gz
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar.bz2
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar.lz
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar.xz
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.tar.zst
nixlib-3d361be06a18752bc97a5a484d29fc279b0446d0.zip
haskell.packages.ghc94: revert to 9.4.2
Due to https://gitlab.haskell.org/ghc/ghc/-/issues/22425, we'll
tentatively stay with 9.4.2 for now. 9.4.3 is available explicitly
via haskell.packagse.ghc943 if you need it (e.g. on aarch64).
Diffstat (limited to 'pkgs/top-level/haskell-packages.nix')
-rw-r--r--pkgs/top-level/haskell-packages.nix35
1 files changed, 33 insertions, 2 deletions
diff --git a/pkgs/top-level/haskell-packages.nix b/pkgs/top-level/haskell-packages.nix
index 6896d02f3cb6..65188e6c0ccd 100644
--- a/pkgs/top-level/haskell-packages.nix
+++ b/pkgs/top-level/haskell-packages.nix
@@ -19,6 +19,7 @@ let
     "ghc924"
     "ghc925"
     "ghc92"
+    "ghc942"
     "ghc943"
     "ghc94"
     "ghcHEAD"
@@ -31,6 +32,7 @@ let
     "ghc924"
     "ghc925"
     "ghc94"
+    "ghc942"
     "ghc943"
     "ghcHEAD"
   ];
@@ -184,6 +186,30 @@ in {
       llvmPackages = pkgs.llvmPackages_12;
     };
     ghc92 = ghc925;
+    ghc942 = callPackage ../development/compilers/ghc/9.4.2.nix {
+      bootPkgs =
+        # Building with 9.2 is broken due to
+        # https://gitlab.haskell.org/ghc/ghc/-/issues/21914
+        # Use 8.10 as a workaround where possible to keep bootstrap path short.
+
+        # On ARM text won't build with GHC 8.10.*
+        if stdenv.hostPlatform.isAarch then
+          # TODO(@sternenseemann): package bindist
+          packages.ghc902
+        # No suitable bindists for powerpc64le
+        else if stdenv.hostPlatform.isPower64 && stdenv.hostPlatform.isLittleEndian then
+          packages.ghc902
+        else
+          packages.ghc8107Binary;
+      inherit (buildPackages.python3Packages) sphinx;
+      # Need to use apple's patched xattr until
+      # https://github.com/xattr/xattr/issues/44 and
+      # https://github.com/xattr/xattr/issues/55 are solved.
+      inherit (buildPackages.darwin) xattr autoSignDarwinBinariesHook;
+      # Support range >= 10 && < 14
+      buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
+      llvmPackages = pkgs.llvmPackages_12;
+    };
     ghc943 = callPackage ../development/compilers/ghc/9.4.3.nix {
       bootPkgs =
         # Building with 9.2 is broken due to
@@ -208,7 +234,7 @@ in {
       buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_12;
       llvmPackages = pkgs.llvmPackages_12;
     };
-    ghc94 = ghc943;
+    ghc94 = ghc942;
     ghcHEAD = callPackage ../development/compilers/ghc/head.nix {
       bootPkgs =
         # For GHC 9.2 no armv7l bindists are available.
@@ -335,12 +361,17 @@ in {
       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { };
     };
     ghc92 = ghc925;
+    ghc942 = callPackage ../development/haskell-modules {
+      buildHaskellPackages = bh.packages.ghc942;
+      ghc = bh.compiler.ghc942;
+      compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
+    };
     ghc943 = callPackage ../development/haskell-modules {
       buildHaskellPackages = bh.packages.ghc943;
       ghc = bh.compiler.ghc943;
       compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.4.x.nix { };
     };
-    ghc94 = ghc943;
+    ghc94 = ghc942;
     ghcHEAD = callPackage ../development/haskell-modules {
       buildHaskellPackages = bh.packages.ghcHEAD;
       ghc = bh.compiler.ghcHEAD;