|
|
@@ -1340,12 +1340,25 @@ bool cmQtAutoGenInitializer::InitAutogenTarget()
|
|
|
}
|
|
|
|
|
|
if (this->Uic.Enabled) {
|
|
|
- // Make all ui_*.h files byproducts of the ${target}_autogen/timestamp
|
|
|
- // custom command if the generation of depfile is enabled.
|
|
|
- auto& byProducts = useDepfile ? timestampByproducts : autogenByproducts;
|
|
|
- for (auto const& file : this->Uic.UiHeaders) {
|
|
|
- this->AddGeneratedSource(file.first, this->Uic);
|
|
|
- byProducts.push_back(file.second);
|
|
|
+ auto const useAdvancedUicGraph = [this]() -> bool {
|
|
|
+ if (this->MultiConfig && this->GlobalGen->IsNinja()) {
|
|
|
+ return this->UseBetterGraph;
|
|
|
+ }
|
|
|
+ return true;
|
|
|
+ }();
|
|
|
+ if (useAdvancedUicGraph) {
|
|
|
+ // Make all ui_*.h files byproducts of the ${target}_autogen/timestamp
|
|
|
+ // custom command if the generation of depfile is enabled.
|
|
|
+ auto& byProducts = useDepfile ? timestampByproducts : autogenByproducts;
|
|
|
+ for (auto const& file : this->Uic.UiHeaders) {
|
|
|
+ this->AddGeneratedSource(file.first, this->Uic);
|
|
|
+ byProducts.push_back(file.second);
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ for (auto const& file : this->Uic.UiHeaders) {
|
|
|
+ this->AddGeneratedSource(file.first, this->Uic);
|
|
|
+ autogenByproducts.push_back(file.second);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|