diff options
author | Johan Fänge <vastevaste@gmail.com> | 2011-09-13 09:24:55 (GMT) |
---|---|---|
committer | David Cole <david.cole@kitware.com> | 2011-12-14 01:06:27 (GMT) |
commit | 7ab1162eaa1490be745f2b2a24ba7b4a3ec69112 (patch) | |
tree | 3ecd4efd88e3b6214b0a928583afcbd911dae946 /Source/cmMakefileUtilityTargetGenerator.cxx | |
parent | 3c101429a4e563f4c711cae84317806284784eb6 (diff) | |
download | CMake-7ab1162eaa1490be745f2b2a24ba7b4a3ec69112.zip CMake-7ab1162eaa1490be745f2b2a24ba7b4a3ec69112.tar.gz CMake-7ab1162eaa1490be745f2b2a24ba7b4a3ec69112.tar.bz2 |
CMake: Fix progress reporting for custom targets (#12441)
Adds "include progress.make" to build.make, just like for
add_executable and add_library targets. The code was copied
from cmMakefileTargetGenerator::WriteCommonCodeRules().
Diffstat (limited to 'Source/cmMakefileUtilityTargetGenerator.cxx')
-rw-r--r-- | Source/cmMakefileUtilityTargetGenerator.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Source/cmMakefileUtilityTargetGenerator.cxx b/Source/cmMakefileUtilityTargetGenerator.cxx index f52f7ab..a82c503 100644 --- a/Source/cmMakefileUtilityTargetGenerator.cxx +++ b/Source/cmMakefileUtilityTargetGenerator.cxx @@ -34,6 +34,20 @@ void cmMakefileUtilityTargetGenerator::WriteRuleFiles() *this->BuildFileStream << "# Utility rule file for " << this->Target->GetName() << ".\n\n"; + if(!this->NoRuleMessages) + { + const char* root = (this->Makefile->IsOn("CMAKE_MAKE_INCLUDE_FROM_ROOT")? + "$(CMAKE_BINARY_DIR)/" : ""); + // Include the progress variables for the target. + *this->BuildFileStream + << "# Include the progress variables for this target.\n" + << this->LocalGenerator->IncludeDirective << " " << root + << this->Convert(this->ProgressFileNameFull.c_str(), + cmLocalGenerator::HOME_OUTPUT, + cmLocalGenerator::MAKEFILE) + << "\n\n"; + } + // write the custom commands for this target this->WriteTargetBuildRules(); |