diff --git a/default.nix b/default.nix index 296f6e41796..eb21f8e7b4e 100644 --- a/default.nix +++ b/default.nix @@ -17,8 +17,11 @@ stackage = sources."stackage.nix"; }; } + # haskell-nix has to be used differently in flakes/no-flakes scenarios: + # - When imported from flakes, 'haskellNix.overlay' needs to be passed here. + # - When imported from default.nix without flakes, default to haskellNix.overlays , haskellNixOverlays ? haskellNix.overlays -, packages ? import ./nix { inherit system sources crossSystem config sourcesOverride haskellNixOverlays checkMaterialization enableHaskellProfiling; } +, packages ? import ./nix { inherit system sources crossSystem config sourcesOverride haskellNix haskellNixOverlays checkMaterialization enableHaskellProfiling; } # An explicit git rev to use, passed when we are in Hydra # Whether to check that the pinned shas for haskell.nix are correct. We want this to be # false, generally, since it does more work, but we set it to true in the CI diff --git a/flake.nix b/flake.nix index 5c223d9057d..890bddcafb6 100644 --- a/flake.nix +++ b/flake.nix @@ -15,9 +15,7 @@ haskellNixOverlays = [ haskell-nix.overlay ]; }; - inherit (topLevel) pkgs plutus ownOverlays; - inherit (plutus) haskell iohkNix; - inherit (plutus.lib) buildPursPackage buildNodeModules filterNpm gitignore-nix; + inherit (topLevel) pkgs plutus; in rec { packages = rec { diff --git a/nix/default.nix b/nix/default.nix index ff3d40fb575..09f18ca111d 100644 --- a/nix/default.nix +++ b/nix/default.nix @@ -3,17 +3,9 @@ , config ? { } , overlays ? [ ] , sourcesOverride ? { } -, sources ? import ./sources.nix { } // sourcesOverride -, haskellNix ? import sources."haskell.nix" { - sourcesOverride = { - hackage = sources."hackage.nix"; - stackage = sources."stackage.nix"; - }; - } - # haskell-nix has to be used differently in flakes/no-flakes scenarios: - # - When imported from flakes, 'haskellNix.overlay' needs to be passed here. - # - When imported from default.nix without flakes, default to haskellNix.overlays -, haskellNixOverlays ? haskellNix.overlays +, sources +, haskellNix +, haskellNixOverlays , checkMaterialization ? false , enableHaskellProfiling ? false }: @@ -38,5 +30,5 @@ let in { - inherit pkgs plutus sources ownOverlays; + inherit pkgs plutus sources; }