on iko/ghcjs-patch-master help sign in
Reduce `roots` to a single derivation. (#774)
32baaacHamish Mackenzie
@@ -1,6 +1,9 @@
1This file contains a summary of changes to Haskell.nix and `nix-tools`
1This file contains a summary of changes to Haskell.nix and `nix-tools`
2that will impact users.
2that will impact users.
3
3
4+## July ?, 2020
5+* Changed `haskell-nix.roots` and `p.roots` to single derivations.
6+
4## July 8, 2020
7## July 8, 2020
5* Removed `sources.nixpkgs-default`, use `sources.nixpkgs` instead.
8* Removed `sources.nixpkgs-default`, use `sources.nixpkgs` instead.
6* Removed `./nixpkgs` directory, use `(import ./. {}).sources`
9* Removed `./nixpkgs` directory, use `(import ./. {}).sources`
overlays/haskell.nix+6−8
@@ -620,14 +620,12 @@ final: prev: {
620 withInputs = final.recurseIntoAttrs;
620 withInputs = final.recurseIntoAttrs;
621
621
622 # Add this to your tests to make all the dependencies of haskell.nix
622 # Add this to your tests to make all the dependencies of haskell.nix
623− # are tested and cached.
623+ # are tested and cached. Consider using `p.roots` where `p` is a
624− roots = compiler-nix-name: final.recurseIntoAttrs {
624+ # project as it will automatically match the `compiler-nix-name`
625− Level0 = roots' compiler-nix-name 0;
625+ # of the project.
626− Level1 = roots' compiler-nix-name 1;
626+ roots = compiler-nix-name: final.linkFarm "haskell-nix-roots-${compiler-nix-name}"
627− # Should be safe to use this now we have materialized everything
627+ (final.lib.mapAttrsToList (name: path: { inherit name path; })
628− # except the tests
629− Level2 = roots' compiler-nix-name 2;
628+ (roots' compiler-nix-name 2));
630− };
631
629
632 roots' = compiler-nix-name: ifdLevel:
630 roots' = compiler-nix-name: ifdLevel:
633 final.recurseIntoAttrs ({
631 final.recurseIntoAttrs ({