summaryrefslogtreecommitdiffstats
path: root/Source/cmComputeTargetDepends.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2017-05-17 17:19:15 (GMT)
committerBrad King <brad.king@kitware.com>2017-05-18 14:18:53 (GMT)
commit5a913794d2931c3de00464cf261215a173f5ab8b (patch)
tree3aef7e5921504fee6aa37d97b3a90163110bcb38 /Source/cmComputeTargetDepends.cxx
parent70c6557285793d9944f4177d3bee3f1570ace308 (diff)
downloadCMake-5a913794d2931c3de00464cf261215a173f5ab8b.zip
CMake-5a913794d2931c3de00464cf261215a173f5ab8b.tar.gz
CMake-5a913794d2931c3de00464cf261215a173f5ab8b.tar.bz2
cmComputeTargetDepends: Avoid computing with empty configuration
Fix `AddInterfaceDepends` to combine all configurations using the same approach that `CollectTargetDepends` does. Fixes: #16896
Diffstat (limited to 'Source/cmComputeTargetDepends.cxx')
-rw-r--r--Source/cmComputeTargetDepends.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/cmComputeTargetDepends.cxx b/Source/cmComputeTargetDepends.cxx
index cfebda2..8ca8763 100644
--- a/Source/cmComputeTargetDepends.cxx
+++ b/Source/cmComputeTargetDepends.cxx
@@ -294,9 +294,11 @@ void cmComputeTargetDepends::AddInterfaceDepends(
}
if (dependee) {
- this->AddInterfaceDepends(depender_index, dependee, "", emitted);
std::vector<std::string> configs;
depender->Makefile->GetConfigurations(configs);
+ if (configs.empty()) {
+ configs.push_back("");
+ }
for (std::vector<std::string>::const_iterator it = configs.begin();
it != configs.end(); ++it) {
// A target should not depend on itself.