diff options
author | Stephen Kelly <steveire@gmail.com> | 2014-07-22 15:07:39 +0200 |
---|---|---|
committer | Stephen Kelly <steveire@gmail.com> | 2014-11-19 00:19:09 +0100 |
commit | 26e98c34dc2a1414f79b6a12de3c4ca060af7578 (patch) | |
tree | 441fa2d5444ca8909a4c659952cf904c70799800 /Tests/RunCMake/File_Generate/ReRunCMake.cmake | |
parent | d526ebc603b0a83a7a1602ed4ddcf1b483077cf4 (diff) | |
download | cmake-26e98c34dc2a1414f79b6a12de3c4ca060af7578.tar.gz |
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 'Tests/RunCMake/File_Generate/ReRunCMake.cmake')
-rw-r--r-- | Tests/RunCMake/File_Generate/ReRunCMake.cmake | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Tests/RunCMake/File_Generate/ReRunCMake.cmake b/Tests/RunCMake/File_Generate/ReRunCMake.cmake new file mode 100644 index 0000000000..109d60e6fe --- /dev/null +++ b/Tests/RunCMake/File_Generate/ReRunCMake.cmake @@ -0,0 +1,5 @@ + +file(GENERATE + OUTPUT output_file.txt + INPUT "${CMAKE_CURRENT_BINARY_DIR}/input_file.txt" +) |