summaryrefslogtreecommitdiffstats
path: root/Source/cmGraphVizWriter.cxx
diff options
context:
space:
mode:
authorAlex Neundorf <neundorf@kde.org>2011-02-05 17:43:34 (GMT)
committerAlex Neundorf <neundorf@kde.org>2011-02-05 17:43:34 (GMT)
commit5698ad2047002529ff095fb9be2eb5c1d2f7a485 (patch)
tree804016afdc1d674b7da278165e4ea1d417d9ebdb /Source/cmGraphVizWriter.cxx
parent00e7ea76e83153db1f95289a4b101b3031c97b99 (diff)
downloadCMake-5698ad2047002529ff095fb9be2eb5c1d2f7a485.zip
CMake-5698ad2047002529ff095fb9be2eb5c1d2f7a485.tar.gz
CMake-5698ad2047002529ff095fb9be2eb5c1d2f7a485.tar.bz2
Make it possible to exlude external libs from dot files
Patch from Christian Ehrlicher. By setting GRAPHVIZ_EXTERNAL_LIBS to TRUE in CMakeGraphVizOptions.cmake you can now exclude external libraries from the produced dot file. I.e. then you see only the dependencies within your project. Alex
Diffstat (limited to 'Source/cmGraphVizWriter.cxx')
-rw-r--r--Source/cmGraphVizWriter.cxx9
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/cmGraphVizWriter.cxx b/Source/cmGraphVizWriter.cxx
index de95aa5..5a08ca6 100644
--- a/Source/cmGraphVizWriter.cxx
+++ b/Source/cmGraphVizWriter.cxx
@@ -54,6 +54,7 @@ cmGraphVizWriter::cmGraphVizWriter(const std::vector<cmLocalGenerator*>&
,GenerateForStaticLibs(true)
,GenerateForSharedLibs(true)
,GenerateForModuleLibs(true)
+,GenerateForExternals(true)
,LocalGenerators(localGenerators)
,HaveTargetsAndLibs(false)
{
@@ -115,7 +116,8 @@ void cmGraphVizWriter::ReadSettings(const char* settingsFileName,
__set_bool_if_set(this->GenerateForExecutables, "GRAPHVIZ_EXECUTABLES");
__set_bool_if_set(this->GenerateForStaticLibs, "GRAPHVIZ_STATIC_LIBS");
__set_bool_if_set(this->GenerateForSharedLibs, "GRAPHVIZ_SHARED_LIBS");
- __set_bool_if_set(this->GenerateForModuleLibs , "GRAPHVIZ_MODULE_LIBS");
+ __set_bool_if_set(this->GenerateForModuleLibs, "GRAPHVIZ_MODULE_LIBS");
+ __set_bool_if_set(this->GenerateForExternals, "GRAPHVIZ_EXTERNAL_LIBS");
cmStdString tmpRegexString;
__set_if_set(tmpRegexString, "GRAPHVIZ_TARGET_IGNORE_REGEX");
@@ -321,7 +323,10 @@ void cmGraphVizWriter::CollectTargetsAndLibs()
{
this->HaveTargetsAndLibs = true;
int cnt = this->CollectAllTargets();
- this->CollectAllExternalLibs(cnt);
+ if (this->GenerateForExternals)
+ {
+ this->CollectAllExternalLibs(cnt);
+ }
}
}