summaryrefslogtreecommitdiffstats
path: root/Source/cmGlobalUnixMakefileGenerator3.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmGlobalUnixMakefileGenerator3.cxx')
-rw-r--r--Source/cmGlobalUnixMakefileGenerator3.cxx43
1 files changed, 11 insertions, 32 deletions
diff --git a/Source/cmGlobalUnixMakefileGenerator3.cxx b/Source/cmGlobalUnixMakefileGenerator3.cxx
index 96d1b33..8fc5fc2 100644
--- a/Source/cmGlobalUnixMakefileGenerator3.cxx
+++ b/Source/cmGlobalUnixMakefileGenerator3.cxx
@@ -903,24 +903,21 @@ cmGlobalUnixMakefileGenerator3
// A target should not depend on itself.
emitted.insert(target.GetName());
-
- // Loop over all library dependencies but not for static libs
- if (target.GetType() != cmTarget::STATIC_LIBRARY)
+
+ // Loop over all library dependencies.
+ const cmTarget::LinkLibraryVectorType& tlibs = target.GetLinkLibraries();
+ for(cmTarget::LinkLibraryVectorType::const_iterator lib = tlibs.begin();
+ lib != tlibs.end(); ++lib)
{
- const cmTarget::LinkLibraryVectorType& tlibs = target.GetLinkLibraries();
- for(cmTarget::LinkLibraryVectorType::const_iterator lib = tlibs.begin();
- lib != tlibs.end(); ++lib)
+ // Don't emit the same library twice for this target.
+ if(emitted.insert(lib->first).second)
{
- // Don't emit the same library twice for this target.
- if(emitted.insert(lib->first).second)
- {
- // Add this dependency.
- this->AppendAnyGlobalDepend(depends, lib->first.c_str(),
- emitted, target);
- }
+ // Add this dependency.
+ this->AppendAnyGlobalDepend(depends, lib->first.c_str(),
+ emitted, target);
}
}
-
+
// Loop over all utility dependencies.
const std::set<cmStdString>& tutils = target.GetUtilities();
for(std::set<cmStdString>::const_iterator util = tutils.begin();
@@ -967,24 +964,6 @@ cmGlobalUnixMakefileGenerator3
std::string tgtName = lg3->GetRelativeTargetDirectory(*result);
tgtName += "/all";
depends.push_back(tgtName);
- if(result->GetType() == cmTarget::STATIC_LIBRARY)
- {
- // Since the static library itself does not list dependencies we
- // need to chain its dependencies here.
- const cmTarget::LinkLibraryVectorType& tlibs
- = result->GetLinkLibraries();
- for(cmTarget::LinkLibraryVectorType::const_iterator lib = tlibs.begin();
- lib != tlibs.end(); ++lib)
- {
- // Don't emit the same library twice for this target.
- if(emitted.insert(lib->first).second)
- {
- // Add this dependency.
- this->AppendAnyGlobalDepend(depends, lib->first.c_str(),
- emitted, *result);
- }
- }
- }
return;
}
}