hnix-store/default.nix

25 lines
893 B
Nix
Raw Normal View History

2022-08-22 03:44:31 +03:00
{ rev ? "272fad732d39b24c4549c475176e0d8cbc8c897a"
2022-04-22 13:49:07 +03:00
, pkgs ?
if ((rev == "") || (rev == "default") || (rev == "local"))
then import <nixpkgs> {}
# Do not guard with hash, so the project is able to use current channels (rolling `rev`) of Nixpkgs
else import (builtins.fetchTarball "https://github.com/NixOS/nixpkgs/archive/${rev}.tar.gz") {}
// {
# Try to build dependencies even if they are marked broken.
config.allowBroken = true;
}
}: let
overlay = import ./overlay.nix pkgs pkgs.haskell.lib;
2019-03-10 02:32:01 +03:00
overrideHaskellPackages = orig: {
buildHaskellPackages =
orig.buildHaskellPackages.override overrideHaskellPackages;
overrides = if orig ? overrides
then pkgs.lib.composeExtensions orig.overrides overlay
else overlay;
};
in {
haskellPackages =
pkgs.haskellPackages.override overrideHaskellPackages;
inherit pkgs;
}