diff options
Diffstat (limited to 'pkgs/top-level/haskell-packages.nix')
-rw-r--r-- | pkgs/top-level/haskell-packages.nix | 91 |
1 files changed, 65 insertions, 26 deletions
diff --git a/pkgs/top-level/haskell-packages.nix b/pkgs/top-level/haskell-packages.nix index 7141f1d35fe00..b757c630420fe 100644 --- a/pkgs/top-level/haskell-packages.nix +++ b/pkgs/top-level/haskell-packages.nix @@ -9,25 +9,18 @@ let "ghc8107" ]; - nativeBignumIncludes = [ - "ghc90" - "ghc902" - "ghc92" - "ghc925" - "ghc926" - "ghc927" - "ghc928" - "ghc94" - "ghc945" - "ghc946" - "ghc947" - "ghc948" - "ghc96" - "ghc963" - "ghc964" - "ghc98" - "ghc981" - "ghcHEAD" + nativeBignumExcludes = integerSimpleIncludes ++ [ + # haskell.compiler sub groups + "integer-simple" + "native-bignum" + # Binary GHCs + "ghc865Binary" + "ghc8107Binary" + "ghc924Binary" + "ghc963Binary" + # ghcjs + "ghcjs" + "ghcjs810" ]; haskellLibUncomposable = import ../development/haskell-modules/lib { @@ -73,6 +66,10 @@ in { llvmPackages = pkgs.llvmPackages_12; }; + ghc963Binary = callPackage ../development/compilers/ghc/9.6.3-binary.nix { + llvmPackages = pkgs.llvmPackages_15; + }; + ghc8107 = callPackage ../development/compilers/ghc/8.10.7.nix { bootPkgs = # the oldest ghc with aarch64-darwin support is 8.10.5 @@ -295,8 +292,14 @@ in { }; ghc96 = compiler.ghc964; ghc981 = callPackage ../development/compilers/ghc/9.8.1.nix { - # No bindist packaged for 9.4.* yet - bootPkgs = packages.ghc947; + bootPkgs = + # For GHC 9.6 no armv7l bindists are available. + if stdenv.hostPlatform.isAarch32 then + packages.ghc963 + else if stdenv.hostPlatform.isPower64 && stdenv.hostPlatform.isLittleEndian then + packages.ghc963 + else + packages.ghc963Binary; inherit (buildPackages.python3Packages) sphinx; # Need to use apple's patched xattr until # https://github.com/xattr/xattr/issues/44 and @@ -306,9 +309,34 @@ in { buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15; llvmPackages = pkgs.llvmPackages_15; }; - ghc98 = compiler.ghc981; + ghc982 = callPackage ../development/compilers/ghc/9.8.2.nix { + bootPkgs = + # For GHC 9.6 no armv7l bindists are available. + if stdenv.hostPlatform.isAarch32 then + packages.ghc963 + else if stdenv.hostPlatform.isPower64 && stdenv.hostPlatform.isLittleEndian then + packages.ghc963 + else + packages.ghc963Binary; + 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 >= 11 && < 16 + buildTargetLlvmPackages = pkgsBuildTarget.llvmPackages_15; + llvmPackages = pkgs.llvmPackages_15; + }; + ghc98 = compiler.ghc982; ghcHEAD = callPackage ../development/compilers/ghc/head.nix { - bootPkgs = packages.ghc963; + bootPkgs = + # For GHC 9.6 no armv7l bindists are available. + if stdenv.hostPlatform.isAarch32 then + packages.ghc963 + else if stdenv.hostPlatform.isPower64 && stdenv.hostPlatform.isLittleEndian then + packages.ghc963 + else + packages.ghc963Binary; inherit (buildPackages.python3Packages) sphinx; # Need to use apple's patched xattr until # https://github.com/xattr/xattr/issues/44 and @@ -340,7 +368,7 @@ in { # with "native" and "gmp" backends. native-bignum = let nativeBignumGhcNames = pkgs.lib.filter - (name: builtins.elem name nativeBignumIncludes) + (name: !(builtins.elem name nativeBignumExcludes)) (pkgs.lib.attrNames compiler); in pkgs.recurseIntoAttrs (pkgs.lib.genAttrs nativeBignumGhcNames @@ -371,6 +399,12 @@ in { compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.2.x.nix { }; packageSetConfig = bootstrapPackageSet; }; + ghc963Binary = callPackage ../development/haskell-modules { + buildHaskellPackages = bh.packages.ghc963Binary; + ghc = bh.compiler.ghc963Binary; + compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.6.x.nix { }; + packageSetConfig = bootstrapPackageSet; + }; ghc8107 = callPackage ../development/haskell-modules { buildHaskellPackages = bh.packages.ghc8107; ghc = bh.compiler.ghc8107; @@ -441,7 +475,12 @@ in { ghc = bh.compiler.ghc981; compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.8.x.nix { }; }; - ghc98 = packages.ghc981; + ghc982 = callPackage ../development/haskell-modules { + buildHaskellPackages = bh.packages.ghc982; + ghc = bh.compiler.ghc982; + compilerConfig = callPackage ../development/haskell-modules/configuration-ghc-9.8.x.nix { }; + }; + ghc98 = packages.ghc982; ghcHEAD = callPackage ../development/haskell-modules { buildHaskellPackages = bh.packages.ghcHEAD; ghc = bh.compiler.ghcHEAD; @@ -479,7 +518,7 @@ in { native-bignum = let nativeBignumGhcNames = pkgs.lib.filter - (name: builtins.elem name nativeBignumIncludes) + (name: !(builtins.elem name nativeBignumExcludes)) (pkgs.lib.attrNames compiler); in pkgs.lib.genAttrs nativeBignumGhcNames |