diff options
author | Stephen Kelly <steveire@gmail.com> | 2014-07-22 13:07:39 (GMT) |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-11-18 23:19:09 (GMT) |
commit | 26e98c34dc2a1414f79b6a12de3c4ca060af7578 (patch) | |
tree | 441fa2d5444ca8909a4c659952cf904c70799800 /Source/cmGeneratorExpressionEvaluationFile.cxx | |
parent | d526ebc603b0a83a7a1602ed4ddcf1b483077cf4 (diff) | |
download | CMake-26e98c34dc2a1414f79b6a12de3c4ca060af7578.zip CMake-26e98c34dc2a1414f79b6a12de3c4ca060af7578.tar.gz CMake-26e98c34dc2a1414f79b6a12de3c4ca060af7578.tar.bz2 |
file(GENERATE): Re-run cmake when appropriate.
Re-run if the input file changes or if the output file is removed.
This only works with the Makefile generators currently. The limitation
of the Ninja generator is tracked as issue #15256. The IDE
generators will need larger refactoring as they currently rely on
being able to determine the depends and output files at the start of
generate-time, which is too early for the file(GENERATE) case.
Diffstat (limited to 'Source/cmGeneratorExpressionEvaluationFile.cxx')
-rw-r--r-- | Source/cmGeneratorExpressionEvaluationFile.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Source/cmGeneratorExpressionEvaluationFile.cxx b/Source/cmGeneratorExpressionEvaluationFile.cxx index 1a101dd..03d0bc6 100644 --- a/Source/cmGeneratorExpressionEvaluationFile.cxx +++ b/Source/cmGeneratorExpressionEvaluationFile.cxx @@ -80,6 +80,7 @@ void cmGeneratorExpressionEvaluationFile::Generate(const std::string& config, return; } + this->Makefile->AddCMakeOutputFile(outputFileName.c_str()); this->Files.push_back(outputFileName); outputFiles[outputFileName] = outputContent; @@ -117,6 +118,7 @@ void cmGeneratorExpressionEvaluationFile::Generate() } else { + this->Makefile->AddCMakeDependFile(this->Input.c_str()); cmSystemTools::GetPermissions(this->Input.c_str(), perm); cmsys::ifstream fin(this->Input.c_str()); if(!fin) |