aboutsummaryrefslogtreecommitdiff
path: root/src/nix/build.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/nix/build.cc')
-rw-r--r--src/nix/build.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nix/build.cc b/src/nix/build.cc
index 75a42ac55..4605eb13e 100644
--- a/src/nix/build.cc
+++ b/src/nix/build.cc
@@ -74,7 +74,8 @@ struct CmdBuild : InstallablesCommand, MixDryRun, MixProfile
store2->addPermRoot(bo.path, absPath(symlink));
},
[&](BuildableFromDrv bfd) {
- for (auto & output : bfd.outputs) {
+ auto builtOutputs = store->queryDerivationOutputMap(bfd.drvPath);
+ for (auto & output : builtOutputs) {
std::string symlink = outLink;
if (i) symlink += fmt("-%d", i);
if (output.first != "out") symlink += fmt("-%s", output.first);