fixup! fixup! fixup! Fix spurious rebuilds for phony targets with validations

This commit is contained in:
Neri Marschik
2026-02-16 13:59:34 +09:00
parent 43aa6e3a34
commit 03ec8c658e

View File

@@ -285,8 +285,8 @@ bool DependencyScan::RecomputeOutputDirty(const Edge* edge,
if (edge->is_phony()) {
// Phony edges don't write any output. Outputs are only dirty if
// there are no inputs or validations and we're missing the output.
// If a phony target has inputs or validations, they are used for dirty
// calculation instead of this fallback.
// If a phony target has inputs or validations, or the output exists,
// they are used for dirty calculation instead of this fallback.
if (edge->inputs_.empty() && edge->validations_.empty() &&
!output->exists()) {
explanations_.Record(