QtAutogen: Do not re-generate AUTORCC outputs on every build
Refactoring in commit v3.6.0-rc1~134^2~10 (Autogen: Split out moc file generation code to dedicated method, 2016-04-18) removed the unconditional creation of the `<target>_automoc.cpp` file. Now it is generated only when `AUTOMOC` is enabled. However, if this file is not created then our internal `GenerateAll` setting is enabled on every build, causing `AUTORCC` to re-generate its file(s) every time. Fix the `GenerateAll` setting to be used only for when autogen settings change. The old logic was left from when we had only automoc. Closes: #16413
This commit is contained in:
parent
adf5f253ec
commit
e4232b82e6
|
@ -455,8 +455,8 @@ static std::string ReadAll(const std::string& filename)
|
||||||
|
|
||||||
bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile)
|
bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile)
|
||||||
{
|
{
|
||||||
if (!cmsys::SystemTools::FileExists(this->OutMocCppFilenameAbs.c_str()) ||
|
// If settings changed everything needs to be re-generated.
|
||||||
(this->OldCompileSettingsStr != this->CurrentCompileSettingsStr)) {
|
if (this->OldCompileSettingsStr != this->CurrentCompileSettingsStr) {
|
||||||
this->GenerateAll = true;
|
this->GenerateAll = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue