diff options
author | Brad King <brad.king@kitware.com> | 2009-06-25 13:58:51 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2009-06-25 13:58:51 (GMT) |
commit | cd83f1979da5c2ed39e5824de70f2d84b8b1a4cc (patch) | |
tree | 4a19dcf2aa834fd8bfe4629dce874c17c4e05dca /Source/cmMakefileTargetGenerator.cxx | |
parent | b9a98ef65b2c586d593219256a05a09c71216eee (diff) | |
download | CMake-cd83f1979da5c2ed39e5824de70f2d84b8b1a4cc.zip CMake-cd83f1979da5c2ed39e5824de70f2d84b8b1a4cc.tar.gz CMake-cd83f1979da5c2ed39e5824de70f2d84b8b1a4cc.tar.bz2 |
ENH: Cleanup make progress rule generation code
This cleans up the Makefile generator's progress rule code. Instead of
keeping every cmMakefileTargetGenerator instance alive to generate
progress, we keep only the information necessary in a single table.
This approach keeps most of the code in cmGlobalUnixMakefileGenerator3,
thus simplifying its public interface.
Diffstat (limited to 'Source/cmMakefileTargetGenerator.cxx')
-rw-r--r-- | Source/cmMakefileTargetGenerator.cxx | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx index 4b9c724..f38874d 100644 --- a/Source/cmMakefileTargetGenerator.cxx +++ b/Source/cmMakefileTargetGenerator.cxx @@ -96,8 +96,6 @@ void cmMakefileTargetGenerator::CreateRuleFile() this->BuildFileNameFull += "/build.make"; // Construct the rule file name. - this->ProgressFileName = this->TargetBuildDirectory; - this->ProgressFileName += "/progress.make"; this->ProgressFileNameFull = this->TargetBuildDirectoryFull; this->ProgressFileNameFull += "/progress.make"; @@ -1535,43 +1533,6 @@ void cmMakefileTargetGenerator::RemoveForbiddenFlags(const char* flagVar, } } -void cmMakefileTargetGenerator::WriteProgressVariables(unsigned long total, - unsigned long ¤t) -{ - cmGeneratedFileStream *progressFileStream = - new cmGeneratedFileStream(this->ProgressFileNameFull.c_str()); - if(!progressFileStream) - { - return; - } - - unsigned long num; - unsigned long i; - for (i = 1; i <= this->NumberOfProgressActions; ++i) - { - *progressFileStream - << "CMAKE_PROGRESS_" << i << " = "; - if (total <= 100) - { - num = i + current; - *progressFileStream << num; - this->LocalGenerator->ProgressFiles[this->Target->GetName()] - .push_back(num); - } - else if (((i+current)*100)/total > ((i-1+current)*100)/total) - { - num = ((i+current)*100)/total; - *progressFileStream << num; - this->LocalGenerator->ProgressFiles[this->Target->GetName()] - .push_back(num); - } - *progressFileStream << "\n"; - } - *progressFileStream << "\n"; - current += this->NumberOfProgressActions; - delete progressFileStream; -} - //---------------------------------------------------------------------------- void cmMakefileTargetGenerator |