summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalUnixMakefileGenerator3.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2007-12-23 03:41:42 (GMT)
committerBrad King <brad.king@kitware.com>2007-12-23 03:41:42 (GMT)
commit4d360f7ac56939ede629e368fb282d4022f69d6c (patch)
treec4ba214154fa085fe06dfbf17d080e41661ee48d /Source/cmLocalUnixMakefileGenerator3.cxx
parenta7245e47925f51b8b648b1eb075f3ecec2b5ce76 (diff)
downloadCMake-4d360f7ac56939ede629e368fb282d4022f69d6c.zip
CMake-4d360f7ac56939ede629e368fb282d4022f69d6c.tar.gz
CMake-4d360f7ac56939ede629e368fb282d4022f69d6c.tar.bz2
ENH: Convert cmDepends object interface to scan an entire target at once.
Diffstat (limited to 'Source/cmLocalUnixMakefileGenerator3.cxx')
-rw-r--r--Source/cmLocalUnixMakefileGenerator3.cxx22
1 files changed, 4 insertions, 18 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx
index 550165b..49a068c 100644
--- a/Source/cmLocalUnixMakefileGenerator3.cxx
+++ b/Source/cmLocalUnixMakefileGenerator3.cxx
@@ -1412,7 +1412,7 @@ cmLocalUnixMakefileGenerator3
#ifdef CMAKE_BUILD_WITH_CMAKE
else if(lang == "Fortran")
{
- scanner = new cmDependsFortran(includes, dir);
+ scanner = new cmDependsFortran(includes);
}
else if(lang == "Java")
{
@@ -1425,23 +1425,9 @@ cmLocalUnixMakefileGenerator3
scanner->SetLocalGenerator(this);
scanner->SetFileComparison
(this->GlobalGenerator->GetCMakeInstance()->GetFileComparison());
- // for each file we need to scan
- std::string srcLang = "CMAKE_DEPENDS_CHECK_";
- srcLang += lang;
- const char *srcStr = mf->GetSafeDefinition(srcLang.c_str());
- std::vector<std::string> srcs;
- cmSystemTools::ExpandListArgument(srcStr, srcs);
- for (std::vector<std::string>::iterator si =
- srcs.begin(); si != srcs.end(); ++si)
- {
- std::string &src = *si;
- ++si;
- // make sure the object file is relative to home output
- std::string obj = *si;
- obj = this->Convert(obj.c_str(),HOME_OUTPUT,MAKEFILE);
- scanner->Write(src.c_str(),obj.c_str(),
- ruleFileStream, internalRuleFileStream);
- }
+ scanner->SetLanguage(lang.c_str());
+ scanner->SetTargetDirectory(dir.c_str());
+ scanner->Write(ruleFileStream, internalRuleFileStream);
// free the scanner for this language
delete scanner;