daemon: Build in /tmp/guix-build-*.
* nix/libstore/build.cc (DerivationGoal::startBuilder): Use "guix-build" instead of "nix-build" for TMPDIR. * doc/guix.texi (Build Environment Setup): Adjust accordingly.
This commit is contained in:
parent
f95dad899b
commit
7a57c96a10
|
@ -604,7 +604,7 @@ a writable @file{/tmp} directory.
|
||||||
|
|
||||||
You can influence the directory where the daemon stores build trees
|
You can influence the directory where the daemon stores build trees
|
||||||
@i{via} the @code{TMPDIR} environment variable. However, the build tree
|
@i{via} the @code{TMPDIR} environment variable. However, the build tree
|
||||||
within the chroot is always @file{/tmp/nix-build-@var{name}.drv-0},
|
within the chroot is always @file{/tmp/guix-build-@var{name}.drv-0},
|
||||||
where @var{name} is the derivation name---e.g., @code{coreutils-8.24}.
|
where @var{name} is the derivation name---e.g., @code{coreutils-8.24}.
|
||||||
This way, the value of @code{TMPDIR} does not leak inside build
|
This way, the value of @code{TMPDIR} does not leak inside build
|
||||||
environments, which avoids discrepancies in cases where build processes
|
environments, which avoids discrepancies in cases where build processes
|
||||||
|
|
|
@ -1713,11 +1713,11 @@ void DerivationGoal::startBuilder()
|
||||||
/* Create a temporary directory where the build will take
|
/* Create a temporary directory where the build will take
|
||||||
place. */
|
place. */
|
||||||
auto drvName = storePathToName(drvPath);
|
auto drvName = storePathToName(drvPath);
|
||||||
tmpDir = createTempDir("", "nix-build-" + drvName, false, false, 0700);
|
tmpDir = createTempDir("", "guix-build-" + drvName, false, false, 0700);
|
||||||
|
|
||||||
/* In a sandbox, for determinism, always use the same temporary
|
/* In a sandbox, for determinism, always use the same temporary
|
||||||
directory. */
|
directory. */
|
||||||
tmpDirInSandbox = useChroot ? "/tmp/nix-build-" + drvName + "-0" : tmpDir;
|
tmpDirInSandbox = useChroot ? "/tmp/guix-build-" + drvName + "-0" : tmpDir;
|
||||||
|
|
||||||
/* For convenience, set an environment pointing to the top build
|
/* For convenience, set an environment pointing to the top build
|
||||||
directory. */
|
directory. */
|
||||||
|
|
Loading…
Reference in New Issue