diff options
author | Ken Martin <ken.martin@kitware.com> | 2005-06-01 17:37:49 (GMT) |
---|---|---|
committer | Ken Martin <ken.martin@kitware.com> | 2005-06-01 17:37:49 (GMT) |
commit | 46e5b9afe2e155aebc4eac0fed80ef98b23a0f7d (patch) | |
tree | 63712ca0454c157a123e475e95bc9eee57d8e343 /Source/cmLocalUnixMakefileGenerator3.cxx | |
parent | 0f8282fab1bd7a52d33914cdf73cb80113b49f7a (diff) | |
download | CMake-46e5b9afe2e155aebc4eac0fed80ef98b23a0f7d.zip CMake-46e5b9afe2e155aebc4eac0fed80ef98b23a0f7d.tar.gz CMake-46e5b9afe2e155aebc4eac0fed80ef98b23a0f7d.tar.bz2 |
ENH: minor perf improvement
Diffstat (limited to 'Source/cmLocalUnixMakefileGenerator3.cxx')
-rw-r--r-- | Source/cmLocalUnixMakefileGenerator3.cxx | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx index f6a4816..b6541bd 100644 --- a/Source/cmLocalUnixMakefileGenerator3.cxx +++ b/Source/cmLocalUnixMakefileGenerator3.cxx @@ -55,6 +55,13 @@ cmLocalUnixMakefileGenerator3::~cmLocalUnixMakefileGenerator3() } //---------------------------------------------------------------------------- +void cmLocalUnixMakefileGenerator3::Configure() +{ + this->ComputeHomeRelativeOutputPath(); + this->cmLocalGenerator::Configure(); +} + +//---------------------------------------------------------------------------- void cmLocalUnixMakefileGenerator3::Generate() { // Setup our configuration variables for this directory. @@ -259,17 +266,21 @@ void cmLocalUnixMakefileGenerator3::WriteDisclaimer(std::ostream& os) << cmMakefile::GetMinorVersion() << "\n\n"; } -std::string cmLocalUnixMakefileGenerator3::GetHomeRelativeOutputPath() +void cmLocalUnixMakefileGenerator3::ComputeHomeRelativeOutputPath() { // Include the rule file for each object. - std::string relPath = + m_HomeRelativeOutputPath = cmSystemTools::RelativePath(m_Makefile->GetHomeOutputDirectory(), m_Makefile->GetStartOutputDirectory()); - if (relPath.size()) + if (m_HomeRelativeOutputPath.size()) { - relPath += "/"; + m_HomeRelativeOutputPath += "/"; } - return relPath; +} + +const std::string &cmLocalUnixMakefileGenerator3::GetHomeRelativeOutputPath() +{ + return m_HomeRelativeOutputPath; } //---------------------------------------------------------------------------- |