diff options
author | Ken Martin <ken.martin@kitware.com> | 2003-08-01 13:11:04 (GMT) |
---|---|---|
committer | Ken Martin <ken.martin@kitware.com> | 2003-08-01 13:11:04 (GMT) |
commit | 847bda527000f6adc41f86d7c9ecc3ffb0ae1d50 (patch) | |
tree | 1ca57af0edadc0ca1a32d72984c8f5d582ea45ec /Source/cmExportLibraryDependencies.cxx | |
parent | ad4dc3e0ef07b7dd38509b22a5742d737486730d (diff) | |
download | CMake-847bda527000f6adc41f86d7c9ecc3ffb0ae1d50.zip CMake-847bda527000f6adc41f86d7c9ecc3ffb0ae1d50.tar.gz CMake-847bda527000f6adc41f86d7c9ecc3ffb0ae1d50.tar.bz2 |
fix for bug # 101
Diffstat (limited to 'Source/cmExportLibraryDependencies.cxx')
-rw-r--r-- | Source/cmExportLibraryDependencies.cxx | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Source/cmExportLibraryDependencies.cxx b/Source/cmExportLibraryDependencies.cxx index 2e85967..e73280f 100644 --- a/Source/cmExportLibraryDependencies.cxx +++ b/Source/cmExportLibraryDependencies.cxx @@ -84,6 +84,8 @@ void cmExportLibraryDependenciesCommand::FinalPass() { cmLocalGenerator* gen = *i; cmTargets &tgts = gen->GetMakefile()->GetTargets(); + std::vector<std::string> depends; + const char *defType; for(cmTargets::const_iterator l = tgts.begin(); l != tgts.end(); ++l) { @@ -96,6 +98,20 @@ void cmExportLibraryDependenciesCommand::FinalPass() if(def) { fout << "SET(" << libDepName << " \"" << def << "\")\n"; + // now for each dependency, check for link type + cmSystemTools::ExpandListArgument(def, depends); + for(std::vector<std::string>::const_iterator d = depends.begin(); + d != depends.end(); ++d) + { + libDepName = *d; + libDepName += "_LINK_TYPE"; + defType = m_Makefile->GetDefinition(libDepName.c_str()); + libDepName = cmSystemTools::EscapeSpaces(libDepName.c_str()); + if(defType) + { + fout << "SET(" << libDepName << " \"" << defType << "\")\n"; + } + } } } } |