haskell.nix icon indicating copy to clipboard operation
haskell.nix copied to clipboard

haskell.nix is not robust to using a different compiler version

Open mpickering opened this issue 5 years ago • 1 comments

I am trying to use 8.8-alpha2 with haskell.nix and there are many places where a fixed set of compilers are assumed.

For example

  • ghcHackagePatches.${compiler.nix-name} -- I deleted this and got a bit further
  • error: attribute '2.5.0.0' missing, at /home/matt/HieDb/pkgs.nix:76:30 caused by this line "Cabal".revision = (((hackage."Cabal")."2.5.0.0").revisions).default;. There is no need to rebuild Cabal as it is a boot package. I already have it installed in the global package db.
  • I deleted all the rest of the boot libraries from pkgs.nix and got a bit further.
  • error: attribute 'ghc88020190424' missing, at /nix/store/r8pdhzpakxhwvzpx0ga17nwfcz546dri-haskell.nix/modules/hackage.nix:69:15 -- that comes from this line, default = pkgs.buildPackages.haskell.compiler.${config.compiler.nix-name}; -- I don't want to use a version of the compiler from normal nixpkgs. Apparently this like this so I can override it. I can't find the documentation about where to apply this config but it looks convenient.. I work out I am meant to set the option ghc.package = compiler.
  • error: attribute 'ghc' missing, at /home/matt/HieDb/.plan.nix/hiedb.nix:40:14 -- https://gist.github.com/mpickering/86fab73862cd8d316fbd76ad69cec2e4

At this point, I gave up.

mpickering avatar Jun 29 '19 16:06 mpickering

@mpickering Did you resolve this?

I've ran into the same issue and so far it seems that we may be able to use specific iohk-ghc compilers from iohk/ghc release repo...if that is the case, then we should be able to use a custom compiler

rmourey26 avatar Oct 25 '22 23:10 rmourey26