Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make compiler easier to configure #68

Open
jcpetruzza opened this issue Jan 8, 2019 · 0 comments
Open

Make compiler easier to configure #68

jcpetruzza opened this issue Jan 8, 2019 · 0 comments

Comments

@jcpetruzza
Copy link

The output of haskell-packages/default.nix at the moment looks something like this:

{ nixpkgs ? import <nixpkgs> {} }:

with nixpkgs;
let  ...
in callPackage (nixpkgs.path + "/pkgs/development/haskell-modules") {
  ghc = pkgs.haskell.compiler.ghc843;
  buildHaskellPackages = buildPackages.haskell.packages.ghc843;
  ...
}

It would be probably nicer if the compiler were another parameter. e.g.:

{ nixpkgs ? import <nixpkgs> {}, compiler ? "ghc843" }:

with nixpkgs;
let  ...
in callPackage (nixpkgs.path + "/pkgs/development/haskell-modules") {
  ghc = pkgs.haskell.compiler.${compiler};
  buildHaskellPackages = buildPackages.haskell.packages.${compiler};
  ...
}

That way one could more easily reuse the same expression with newer versions of nixpkgs, in particular one where only ghc844 is available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant