diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2018-11-22 12:24:38 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2018-11-22 12:24:38 +0200 |
commit | 5f9dcd5364993f32e6841ffdfefce1cc87017b22 (patch) | |
tree | 82d44aefe90d98337d1b5324d55d6bcacc41416a /build2/cc/compile-rule.cxx | |
parent | 04c2bf359f9065300808ff389c06aa0811e7376b (diff) |
Make backwards modification time check permanent, add another experiment
Diffstat (limited to 'build2/cc/compile-rule.cxx')
-rw-r--r-- | build2/cc/compile-rule.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/build2/cc/compile-rule.cxx b/build2/cc/compile-rule.cxx index e361e9d..9326193 100644 --- a/build2/cc/compile-rule.cxx +++ b/build2/cc/compile-rule.cxx @@ -4249,7 +4249,8 @@ namespace build2 return *pr.first; } - // Make sure depdb is no older than any of our prerequisites. + // Make sure depdb is no older than any of our prerequisites (see md.mt + // logic description above for details). // touch (md.dd, false, verb_never); @@ -4668,11 +4669,14 @@ namespace build2 rm.cancel (); } + timestamp now (system_clock::now ()); + depdb::verify (timestamp_unknown, md.dd, tp, now); + // Should we go to the filesystem and get the new mtime? We know the // file has been modified, so instead just use the current clock time. // It has the advantage of having the subseconds precision. // - t.mtime (system_clock::now ()); + t.mtime (now); return target_state::changed; } |