about summary refs log tree commit diff
diff options
context:
space:
mode:
authorShea Levy <shea@shealevy.com>2011-11-06T06·54+0000
committerShea Levy <shea@shealevy.com>2011-11-06T06·54+0000
commitca0d47a70c37999f8cc9c2e82c76661826cfd50a (patch)
tree3ee69e2f8db1bb3ba97b5c214febeb706d9eabc4
parent24b65937e103c5cb1232c3cbcbffc12322cb8ae3 (diff)
Respect all outputs passed to the derivation, not just the last one
-rw-r--r--src/libexpr/primops.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc
index 9c217b373f9e..70560302ea4c 100644
--- a/src/libexpr/primops.cc
+++ b/src/libexpr/primops.cc
@@ -388,8 +388,10 @@ static void prim_derivationStrict(EvalState & state, Value * * args, Value & v)
         if (!useDrvAsSrc && isDerivation(path))
             if (explicitlyPassed)
                 drv.inputDrvs[path] = store -> queryDerivationOutputNames(path);
-            else
+            else if (drv.inputDrvs.find(path) == drv.inputDrvs.end())
                 drv.inputDrvs[path] = singleton<StringSet>(output);
+            else
+                drv.inputDrvs[path].insert(output);
         else
             drv.inputSrcs.insert(path);
     }