diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2003-11-01T23·29+0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2003-11-01T23·29+0000 |
commit | c8268ca9917061466a3448028ea524d9842e1ac9 (patch) | |
tree | 98d6ed6dc65017cd36d39b58c3a0946035d971df /src | |
parent | 7de1b2a6980f71cfbf36f7250e247f6eafd763d9 (diff) |
* Fast builds.
Diffstat (limited to 'src')
-rw-r--r-- | src/libnix/normalise.cc | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/libnix/normalise.cc b/src/libnix/normalise.cc index 0ce38d68a88f..d3978ac2c159 100644 --- a/src/libnix/normalise.cc +++ b/src/libnix/normalise.cc @@ -127,24 +127,17 @@ Path normaliseNixExpr(const Path & _nePath, PathSet pending) i != ne.derivation.env.end(); i++) env[i->first] = i->second; - /* We can skip running the builder if we can expand all output - paths from their ids. */ - bool fastBuild = false; -#if 0 + /* We can skip running the builder if all output paths are already + valid. */ bool fastBuild = true; for (PathSet::iterator i = ne.derivation.outputs.begin(); i != ne.derivation.outputs.end(); i++) { - try { - expandId(i->second, i->first, "/", pending); - } catch (Error & e) { - debug(format("fast build failed for `%1%': %2%") - % i->first % e.what()); + if (!isValidPath(*i)) { fastBuild = false; break; } } -#endif if (!fastBuild) { |