diff options
author | Brad King <brad.king@kitware.com> | 2020-09-03 12:46:35 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2020-09-03 12:47:33 (GMT) |
commit | fff360c60c7e428054306fc0f02126ac7fd34410 (patch) | |
tree | 8be18eee803f6cf425bd1262db68916e083e5d25 /Source | |
parent | be66f2e24f1997e38c17f1db55d2d78e1d8f3c28 (diff) | |
parent | a9fd3a107dc4bc34b8d2822b9153ee0ab9e02ea8 (diff) | |
download | CMake-fff360c60c7e428054306fc0f02126ac7fd34410.zip CMake-fff360c60c7e428054306fc0f02126ac7fd34410.tar.gz CMake-fff360c60c7e428054306fc0f02126ac7fd34410.tar.bz2 |
Merge topic 'ninja-multi-automoc-regression' into release-3.18
a9fd3a107d Ninja Multi-Config: Fix dependencies of utility targets
f1199bdc96 Ninja Multi-Config: Fix cleaning of utility targets with commands
657047cd24 Ninja Multi-Config: Fix clean:all target
c35d1927a5 Tests: Pass additional Qt information to Ninja and NMC tests
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5177
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmGlobalNinjaGenerator.cxx | 4 | ||||
-rw-r--r-- | Source/cmNinjaUtilityTargetGenerator.cxx | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/Source/cmGlobalNinjaGenerator.cxx b/Source/cmGlobalNinjaGenerator.cxx index 843b0f4..f11cd50 100644 --- a/Source/cmGlobalNinjaGenerator.cxx +++ b/Source/cmGlobalNinjaGenerator.cxx @@ -1170,7 +1170,8 @@ void cmGlobalNinjaGenerator::AppendTargetDependsClosure( for (auto const& dep_target : this->GetTargetDirectDepends(target)) { if (dep_target->GetType() == cmStateEnums::INTERFACE_LIBRARY || - (this->EnableCrossConfigBuild() && !dep_target.IsCross())) { + (target->GetType() != cmStateEnums::UTILITY && + this->EnableCrossConfigBuild() && !dep_target.IsCross())) { continue; } @@ -1863,6 +1864,7 @@ void cmGlobalNinjaGenerator::WriteTargetClean(std::ostream& os) byproducts.push_back( this->BuildAlias(GetByproductsForCleanTargetName(), config)); } + byproducts.emplace_back(GetByproductsForCleanTargetName()); build.Variables["TARGETS"] = cmJoin(byproducts, " "); for (auto const& fileConfig : configs) { diff --git a/Source/cmNinjaUtilityTargetGenerator.cxx b/Source/cmNinjaUtilityTargetGenerator.cxx index 8d863c3..c964bc1 100644 --- a/Source/cmNinjaUtilityTargetGenerator.cxx +++ b/Source/cmNinjaUtilityTargetGenerator.cxx @@ -100,6 +100,8 @@ void cmNinjaUtilityTargetGenerator::Generate(const std::string& config) if (genTarget->Target->GetType() != cmStateEnums::GLOBAL_TARGET) { lg->AppendTargetOutputs(genTarget, gg->GetByproductsForCleanTarget(), config); + std::copy(util_outputs.begin(), util_outputs.end(), + std::back_inserter(gg->GetByproductsForCleanTarget())); } lg->AppendTargetDepends(genTarget, deps, config, config); |