about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorNeil Mayhew <neil@neil.mayhew.name>2017-04-09T00·31-0600
committerNeil Mayhew <neil@neil.mayhew.name>2017-04-09T14·21-0600
commitf12a048a0595ea75453c6b67a3b72da8106fc6ad (patch)
tree34942031e136f02b45e8cf11f6beeb65358485b2 /src
parentd8ff3aaae7167e22d0c0f4f55ac9da8fb6655f1f (diff)
Propagate NIX_BUILD_CORES to nix-shell environments
Diffstat (limited to 'src')
-rwxr-xr-xsrc/nix-build/nix-build.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nix-build/nix-build.cc b/src/nix-build/nix-build.cc
index b4206033cf5f..065447684aaf 100755
--- a/src/nix-build/nix-build.cc
+++ b/src/nix-build/nix-build.cc
@@ -406,6 +406,7 @@ int main(int argc, char ** argv)
 
                 env["NIX_BUILD_TOP"] = env["TMPDIR"] = env["TEMPDIR"] = env["TMP"] = env["TEMP"] = tmp;
                 env["NIX_STORE"] = store->storeDir;
+                env["NIX_BUILD_CORES"] = settings.buildCores;
 
                 for (auto & var : drv.env)
                     env[var.first] = var.second;