summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefile.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2000-09-21 17:45:08 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2000-09-21 17:45:08 (GMT)
commit1e3ba0f1d72873233193ce69614fd4bd880e8fc5 (patch)
treeda0313b2bf9af52e9b17f639d78a940788c30a2a /Source/cmMakefile.cxx
parent749b7ff7a3556934f4a7d6ead0f9a4d3ade7fad0 (diff)
downloadCMake-1e3ba0f1d72873233193ce69614fd4bd880e8fc5.zip
CMake-1e3ba0f1d72873233193ce69614fd4bd880e8fc5.tar.gz
CMake-1e3ba0f1d72873233193ce69614fd4bd880e8fc5.tar.bz2
ENH: clean up code, and varible names
Diffstat (limited to 'Source/cmMakefile.cxx')
-rw-r--r--Source/cmMakefile.cxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 3fa59a9..1b6538c 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -24,13 +24,13 @@ void cmMakefile::Print()
}
// Parse the given CMakeLists.txt file into a list of classes.
-
bool cmMakefile::ReadMakefile(const char* filename)
{
m_BuildFlags.SetSourceHomeDirectory(this->GetHomeDirectory());
m_BuildFlags.SetStartDirectory(this->GetCurrentDirectory());
m_BuildFlags.ParseDirectories();
-
+ m_BuildFlags.ExpandVaribles(this);
+
std::ifstream fin(filename);
if(!fin)
{
@@ -188,11 +188,12 @@ void cmMakefile::ReadTemplateInstanceDirectory(std::string& line)
std::string::size_type start = line.find("=");
if(start != std::string::npos)
{
- std::string dirname = line.substr(start+1, line.size());
- dirname = cmSystemTools::CleanUpName(dirname.c_str());
+ std::string templateDirectory = line.substr(start+1, line.size());
+ templateDirectory = cmSystemTools::CleanUpName(templateDirectory.c_str());
+ m_TemplateDirectories.push_back(templateDirectory);
std::string tdir = this->GetCurrentDirectory();
tdir += "/";
- tdir += dirname;
+ tdir += templateDirectory;
// Load all the files in the directory
cmDirectory dir;
if(dir.Load(tdir.c_str()))
@@ -207,7 +208,7 @@ void cmMakefile::ReadTemplateInstanceDirectory(std::string& line)
// Remove the extension
std::string::size_type dotpos = file.rfind(".");
file = file.substr(0, dotpos);
- std::string fullname = dirname;
+ std::string fullname = templateDirectory;
fullname += "/";
fullname += file;
// add the file as a class file so
@@ -221,8 +222,8 @@ void cmMakefile::ReadTemplateInstanceDirectory(std::string& line)
}
else
{
- std::cerr << "Error can not open template instance directory "
- << dirname.c_str() << std::endl;
+ std::cerr << "Warning can not open template instance directory "
+ << templateDirectory.c_str() << std::endl;
}
}
}