2015-04-19 16:47:45 +00:00
|
|
|
{ pkgs, callPackage, stdenv }:
|
2011-03-12 17:28:15 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
rec {
|
2009-04-18 12:47:11 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
lib = import ../development/haskell-modules/lib.nix { inherit pkgs; };
|
2010-11-15 20:28:42 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
compiler = {
|
2010-08-30 17:10:21 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
ghc6102Binary = callPackage ../development/compilers/ghc/6.10.2-binary.nix { gmp = pkgs.gmp4; };
|
|
|
|
ghc704Binary = callPackage ../development/compilers/ghc/7.0.4-binary.nix ({ gmp = pkgs.gmp4; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc742Binary = callPackage ../development/compilers/ghc/7.4.2-binary.nix ({ gmp = pkgs.gmp4; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
2014-06-13 08:22:46 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
ghc6104 = callPackage ../development/compilers/ghc/6.10.4.nix { ghc = compiler.ghc6102Binary; };
|
|
|
|
ghc6123 = callPackage ../development/compilers/ghc/6.12.3.nix { ghc = compiler.ghc6102Binary; };
|
|
|
|
ghc704 = callPackage ../development/compilers/ghc/7.0.4.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc722 = callPackage ../development/compilers/ghc/7.2.2.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc742 = callPackage ../development/compilers/ghc/7.4.2.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc763 = callPackage ../development/compilers/ghc/7.6.3.nix ({ ghc = compiler.ghc704Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc784 = callPackage ../development/compilers/ghc/7.8.4.nix ({ ghc = compiler.ghc742Binary; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghc7101 = callPackage ../development/compilers/ghc/7.10.1.nix ({ ghc = compiler.ghc784; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
|
|
|
ghcHEAD = callPackage ../development/compilers/ghc/head.nix ({ inherit (packages.ghc784) ghc alex happy; } // stdenv.lib.optionalAttrs stdenv.isDarwin {
|
|
|
|
libiconv = pkgs.darwin.libiconv;
|
|
|
|
});
|
2014-10-13 08:16:23 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
ghcjs = packages.ghc7101.callPackage ../development/compilers/ghcjs {
|
|
|
|
ghc = compiler.ghc7101;
|
2014-06-09 08:31:29 +00:00
|
|
|
};
|
2015-05-15 13:25:53 +00:00
|
|
|
|
|
|
|
jhc = callPackage ../development/compilers/jhc {
|
|
|
|
inherit (packages.ghc763) ghcWithPackages;
|
|
|
|
};
|
|
|
|
|
|
|
|
uhc = callPackage ../development/compilers/uhc/default.nix ({
|
|
|
|
stdenv = pkgs.clangStdenv;
|
|
|
|
inherit (pkgs.haskellPackages) ghcWithPackages;
|
|
|
|
});
|
|
|
|
|
2014-06-09 08:31:29 +00:00
|
|
|
};
|
2014-05-30 01:00:04 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
packages = {
|
2014-02-08 20:16:43 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
ghc6104 = callPackage ../development/haskell-modules { ghc = compiler.ghc6104; };
|
|
|
|
ghc6123 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc6123;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-6.12.x.nix { };
|
2014-10-18 14:59:46 +00:00
|
|
|
};
|
2015-04-19 16:47:45 +00:00
|
|
|
ghc704 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc704;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.0.x.nix { };
|
2014-06-28 14:45:16 +00:00
|
|
|
};
|
2015-04-19 16:47:45 +00:00
|
|
|
ghc722 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc722;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.2.x.nix { };
|
|
|
|
};
|
|
|
|
ghc742 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc742;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.4.x.nix { };
|
|
|
|
};
|
|
|
|
ghc763 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc763;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.6.x.nix { };
|
|
|
|
};
|
|
|
|
ghc784 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc784;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.8.x.nix { };
|
|
|
|
};
|
|
|
|
ghc7101 = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghc7101;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-7.10.x.nix { };
|
|
|
|
};
|
|
|
|
ghcHEAD = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghcHEAD;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghc-head.nix { };
|
|
|
|
};
|
|
|
|
ghcjs = callPackage ../development/haskell-modules {
|
|
|
|
ghc = compiler.ghcjs;
|
|
|
|
packageSetConfig = callPackage ../development/haskell-modules/configuration-ghcjs.nix { };
|
Re-write the Haskell Platform out of haskell-defaults.nix.
1) Packages formerly called haskell-haskell-platform-ghcXYZ-VVVV.X.Y.Z are
now called haskell-platform-VVVV.X.Y.Z. The latest version can be
installed by running "nix-env -i haskell-platform".
2) The attributes haskellPackages_ghcXYZ.haskellPlatform no longer exist.
Instead, we have attributes like haskellPlatformPackages."2012_4_0_0".
(The last numeric bit must be quoted when used in a Nix file, but not on
the command line to nix-env, nix-build, etc.) The latest Platform has a
top-level alias called simply haskellPlatform.
3) The haskellPackages_ghcXYZ package sets offer the latest version of every
library that GHC x.y.z can compile. For example, if 2.7 is the latest
version of QuickCheck and if GHC 7.0.4 can compile that version, then
haskellPackages_ghc704.QuickCheck refers to version 2.7.
4) All intermediate GHC releases were dropped from all-packages.nix to
simplify our configuration. What remains is a haskellPackages_ghcXYZ set
for the latest version of every major release branch, i.e. GHC 6.10.4,
6.12.3, 7.0.4, 7.2.2, 7.4.2, 7.6.3, 7.8.2, and 7.9.x (HEAD snapshot).
5) The ghcXYZPrefs functions in haskell-defaults.nix now inherit overrides
from newer to older compilers, i.e. an override configured for GHC 7.0.4
will automatically apply to GHC 6.12.3 and 6.10.4, too. This change has
reduced the redundancy in those configuration functions. The downside is
that overriding an attribute for only one particular GHC version has become
more difficult. In practice, this case doesn't occur much, though.
6) The 'cabal' builder has a brand-new argument called 'extension'. That
function is "self : super : {}" by default and users can override it to
mess with the attribute set passed to cabal.mkDerivation. An example use
would be the definition of darcs in all-packages.nix:
| darcs = haskellPackages.darcs.override {
| cabal = haskellPackages.cabal.override {
| extension = self : super : {
| isLibrary = false;
| configureFlags = "-f-library " + super.configureFlags or "";
| };
| };
| };
In this case, extension disables building the library part of the package
to give us an executable-only version that has no dependencies on GHC or
any other Haskell packages.
The 'self' argument refers to the final version of the attribute set and
'super' refers to the original attribute set.
Note that ...
- Haskell Platform packages always provide the Haddock binary that came with
the compiler.
- Haskell Platform 2009.2.0.2 is broken because of build failures in cgi and
cabal-install.
- Haskell Platform 2010.1.0.0 is broken becasue of build failures in cgi.
2014-05-07 17:36:45 +00:00
|
|
|
};
|
2010-08-30 17:10:21 +00:00
|
|
|
|
2015-04-19 16:47:45 +00:00
|
|
|
};
|
2015-01-08 14:38:47 +00:00
|
|
|
}
|