Added overrideScope for callPackageWith

Consequently removing several ad-hoc definitions of the same concept.
This commit is contained in:
Will Fancher
2017-07-13 14:56:13 -04:00
parent 5a5f8613e0
commit 8b764960e9
4 changed files with 52 additions and 64 deletions
+1 -6
View File
@@ -5,14 +5,9 @@ let
lib = pkgs.callPackage ./lib.nix {};
# FIXME: add support for overrideScope
callPackageWithScope = scope: drv: args: stdenv.lib.callPackageWith scope drv args;
mkScope = scope: pkgs // scope;
packages = self:
let
defaultScope = mkScope self;
callPackage = drv: args: callPackageWithScope defaultScope drv args;
callPackage = stdenv.lib.callPackageWith (pkgs // self);
in
import ./hex-packages.nix {
inherit pkgs stdenv callPackage;