diff options
author | Sebastian Holtermann <sebholt@xwmw.org> | 2017-08-31 22:36:23 (GMT) |
---|---|---|
committer | Sebastian Holtermann <sebholt@xwmw.org> | 2017-09-07 15:53:19 (GMT) |
commit | ed216b32a507611a3f2f634ac8d3fc0f8e810ea7 (patch) | |
tree | c3f44a5a5af72860a435ba7e46606c406ff15456 | |
parent | f23a24c2878ffc0b6f769d5a61509b254d082c03 (diff) | |
download | CMake-ed216b32a507611a3f2f634ac8d3fc0f8e810ea7.zip CMake-ed216b32a507611a3f2f634ac8d3fc0f8e810ea7.tar.gz CMake-ed216b32a507611a3f2f634ac8d3fc0f8e810ea7.tar.bz2 |
Autogen: Touch moc_predefs.h when it's content didn't change
-rw-r--r-- | Source/cmQtAutoGenerators.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/cmQtAutoGenerators.cxx b/Source/cmQtAutoGenerators.cxx index 71e51bd..d89c121 100644 --- a/Source/cmQtAutoGenerators.cxx +++ b/Source/cmQtAutoGenerators.cxx @@ -1227,6 +1227,7 @@ bool cmQtAutoGenerators::MocGenerateAll( return false; } } + // (Re)write predefs file only on demand if (this->FileDiffers(this->MocPredefsFileAbs, output)) { if (this->FileWrite(cmQtAutoGen::MOC, this->MocPredefsFileAbs, @@ -1235,6 +1236,12 @@ bool cmQtAutoGenerators::MocGenerateAll( } else { return false; } + } else { + // Touch to update the time stamp + if (this->Verbose) { + this->LogInfo("Touching MOC predefs " + this->MocPredefsFileRel); + } + cmSystemTools::Touch(this->MocPredefsFileAbs, false); } } } |