summaryrefslogtreecommitdiffstats
path: root/src/graph.cc
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2015-03-17 01:21:15 (GMT)
committerNico Weber <nicolasweber@gmx.de>2015-03-17 01:21:15 (GMT)
commit717619a260633ca0e7c9eb2366130fc06ebacfff (patch)
tree98394c40861c61c7c2ff9d535728c72b35e1b7e0 /src/graph.cc
parentd5746fdd1754cbd539ab3ca7a58c7b75502ed4c4 (diff)
parent157a71f39b19d4fac43c814211c2093de205adab (diff)
downloadNinja-717619a260633ca0e7c9eb2366130fc06ebacfff.zip
Ninja-717619a260633ca0e7c9eb2366130fc06ebacfff.tar.gz
Ninja-717619a260633ca0e7c9eb2366130fc06ebacfff.tar.bz2
Merge pull request #930 from nico/depcolon
On unexpected output in a .d file, rebuild instead erroring.
Diffstat (limited to 'src/graph.cc')
-rw-r--r--src/graph.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/graph.cc b/src/graph.cc
index cbf7921..76c4e9a 100644
--- a/src/graph.cc
+++ b/src/graph.cc
@@ -390,12 +390,13 @@ bool ImplicitDepLoader::LoadDepFile(Edge* edge, const string& path,
&depfile.out_.len_, &unused, err))
return false;
- // Check that this depfile matches the edge's output.
+ // Check that this depfile matches the edge's output, if not return false to
+ // mark the edge as dirty.
Node* first_output = edge->outputs_[0];
StringPiece opath = StringPiece(first_output->path());
if (opath != depfile.out_) {
- *err = "expected depfile '" + path + "' to mention '" +
- first_output->path() + "', got '" + depfile.out_.AsString() + "'";
+ EXPLAIN("expected depfile '%s' to mention '%s', got '%s'", path.c_str(),
+ first_output->path().c_str(), depfile.out_.AsString().c_str());
return false;
}