Skip to content

Commit f15152d

Browse files
committed
don't include derivation name in temporary build directories
With the migration to /nix/var/nix/builds we now have failing builds when the derivation name is too long. This change removes the derivation name from the temporary build to have a predictable prefix length: Also see: NixOS/infra#764 for context.
1 parent 8ee7479 commit f15152d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/libstore/unix/build/derivation-builder.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -706,7 +706,7 @@ void DerivationBuilderImpl::startBuilder()
706706

707707
/* Create a temporary directory where the build will take
708708
place. */
709-
topTmpDir = createTempDir(buildDir, "nix-build-" + std::string(drvPath.name()), 0700);
709+
topTmpDir = createTempDir(buildDir, "nix", 0700);
710710
setBuildTmpDir();
711711
assert(!tmpDir.empty());
712712

0 commit comments

Comments
 (0)