summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorJohn Ericson <Ericson2314@Yahoo.com>2017-03-23 19:18:43 -0400
committerJohn Ericson <Ericson2314@Yahoo.com>2017-04-17 17:13:01 -0400
commitb477851f3427e3353d530ab0d47b63fe2686dd4b (patch)
tree8fcd551e3f71e20c03848cb299d816a8d1682687 /pkgs
parent213d29f6b7c44cdc5182dacad78de047063845fa (diff)
downloadnixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar.gz
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar.bz2
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar.lz
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar.xz
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.tar.zst
nixpkgs-b477851f3427e3353d530ab0d47b63fe2686dd4b.zip
top-level: Less indirection for lib in release*.nix
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/top-level/release-cross.nix3
-rw-r--r--pkgs/top-level/release-lib.nix5
-rw-r--r--pkgs/top-level/release-python.nix4
-rw-r--r--pkgs/top-level/release-small.nix2
-rw-r--r--pkgs/top-level/release.nix5
5 files changed, 8 insertions, 11 deletions
diff --git a/pkgs/top-level/release-cross.nix b/pkgs/top-level/release-cross.nix
index f97681a8801..2b6cdd04974 100644
--- a/pkgs/top-level/release-cross.nix
+++ b/pkgs/top-level/release-cross.nix
@@ -1,4 +1,3 @@
-
 { # The platforms for which we build Nixpkgs.
   supportedSystems ? [ builtins.currentSystem ]
 , # Strip most of attributes when evaluating to spare memory usage
@@ -8,8 +7,6 @@
 with import ./release-lib.nix { inherit supportedSystems scrubJobs; };
 
 let
-  inherit (pkgs) lib;
-
   nativePlatforms = linux;
 
   /* Basic list of packages to cross-build */
diff --git a/pkgs/top-level/release-lib.nix b/pkgs/top-level/release-lib.nix
index a6e574a7d11..a5fdb952206 100644
--- a/pkgs/top-level/release-lib.nix
+++ b/pkgs/top-level/release-lib.nix
@@ -3,7 +3,9 @@
 , scrubJobs ? true
 }:
 
-with import ../../lib;
+let
+  lib = import ../../lib;
+in with lib;
 
 rec {
 
@@ -14,6 +16,7 @@ rec {
   });
 
   pkgs = pkgsFor "x86_64-linux";
+  inherit lib;
 
 
   hydraJob' = if scrubJobs then hydraJob else id;
diff --git a/pkgs/top-level/release-python.nix b/pkgs/top-level/release-python.nix
index 0fbd5e50d12..3bc252e440f 100644
--- a/pkgs/top-level/release-python.nix
+++ b/pkgs/top-level/release-python.nix
@@ -3,14 +3,14 @@
    $ hydra-eval-jobs pkgs/top-level/release-python.nix
 */
 
-{ nixpkgs ? { outPath = (import ../.. {}).lib.cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
+{ nixpkgs ? { outPath = (import ../../lib).cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
 , officialRelease ? false
 , # The platforms for which we build Nixpkgs.
   supportedSystems ? [ "x86_64-linux" ]
 }:
 
-with import ../../lib;
 with import ./release-lib.nix {inherit supportedSystems; };
+with lib;
 
 let
   packagePython = mapAttrs (name: value:
diff --git a/pkgs/top-level/release-small.nix b/pkgs/top-level/release-small.nix
index b12eda6f150..f329f2460d7 100644
--- a/pkgs/top-level/release-small.nix
+++ b/pkgs/top-level/release-small.nix
@@ -1,7 +1,7 @@
 /* A small release file, with few packages to be built.  The aim is to reduce
    the load on Hydra when testing the `stdenv-updates' branch. */
 
-{ nixpkgs ? { outPath = (import ../.. {}).lib.cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
+{ nixpkgs ? { outPath = (import ../../lib).cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
 , supportedSystems ? [ "x86_64-linux" "i686-linux" "x86_64-darwin" ]
 }:
 
diff --git a/pkgs/top-level/release.nix b/pkgs/top-level/release.nix
index b5207879a5e..f2feb29f0cd 100644
--- a/pkgs/top-level/release.nix
+++ b/pkgs/top-level/release.nix
@@ -9,7 +9,7 @@
    $ nix-build pkgs/top-level/release.nix -A coreutils.x86_64-linux
 */
 
-{ nixpkgs ? { outPath = (import ../.. {}).lib.cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
+{ nixpkgs ? { outPath = (import ../../lib).cleanSource ../..; revCount = 1234; shortRev = "abcdef"; }
 , officialRelease ? false
 , # The platforms for which we build Nixpkgs.
   supportedSystems ? [ "x86_64-linux" "i686-linux" "x86_64-darwin" "aarch64-linux" ]
@@ -20,9 +20,6 @@
 with import ./release-lib.nix { inherit supportedSystems scrubJobs; };
 
 let
-
-  lib = pkgs.lib;
-
   jobs =
     { tarball = import ./make-tarball.nix { inherit pkgs nixpkgs officialRelease; };