summaryrefslogtreecommitdiffstats
path: root/Source/cmComputeTargetDepends.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2010-08-25 14:14:31 (GMT)
committerBrad King <brad.king@kitware.com>2010-08-25 21:14:13 (GMT)
commitadb58d5e36e482e7cc2c0b1a37d94b21da9234df (patch)
treeb1d915bc894343ccba3e629ca9e790005b582072 /Source/cmComputeTargetDepends.h
parent681cf011dde81c08c0404569289110f9585c6daf (diff)
downloadCMake-adb58d5e36e482e7cc2c0b1a37d94b21da9234df.zip
CMake-adb58d5e36e482e7cc2c0b1a37d94b21da9234df.tar.gz
CMake-adb58d5e36e482e7cc2c0b1a37d94b21da9234df.tar.bz2
Honor strong intra-component target dependencies
Strong dependencies (created by add_dependencies) must be honored when linearizing a strongly-connected component of the target dependency graph. The initial graph edges have strong/weak labels and can contain cycles that do not consist exclusively of strong edges. The final graph never contains cycles so all edges can be strong.
Diffstat (limited to 'Source/cmComputeTargetDepends.h')
-rw-r--r--Source/cmComputeTargetDepends.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/Source/cmComputeTargetDepends.h b/Source/cmComputeTargetDepends.h
index b18a053..240de76 100644
--- a/Source/cmComputeTargetDepends.h
+++ b/Source/cmComputeTargetDepends.h
@@ -45,7 +45,7 @@ private:
void CollectTargetDepends(int depender_index);
void AddTargetDepend(int depender_index, const char* dependee_name,
bool linking);
- void ComputeFinalDepends(cmComputeComponentGraph const& ccg);
+ bool ComputeFinalDepends(cmComputeComponentGraph const& ccg);
cmGlobalGenerator* GlobalGenerator;
bool DebugMode;
@@ -68,7 +68,13 @@ private:
// Deal with connected components.
void DisplayComponents(cmComputeComponentGraph const& ccg);
bool CheckComponents(cmComputeComponentGraph const& ccg);
- void ComplainAboutBadComponent(cmComputeComponentGraph const& ccg, int c);
+ void ComplainAboutBadComponent(cmComputeComponentGraph const& ccg, int c,
+ bool strong = false);
+
+ std::vector<int> ComponentHead;
+ std::vector<int> ComponentTail;
+ bool IntraComponent(std::vector<int> const& cmap, int c, int i, int* head,
+ std::set<int>& emitted, std::set<int>& visited);
};
#endif