summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/File_Generate/AdjacentInOut.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/File_Generate/AdjacentInOut.cmake')
-rw-r--r--Tests/RunCMake/File_Generate/AdjacentInOut.cmake6
1 files changed, 6 insertions, 0 deletions
diff --git a/Tests/RunCMake/File_Generate/AdjacentInOut.cmake b/Tests/RunCMake/File_Generate/AdjacentInOut.cmake
new file mode 100644
index 0000000..828c2ee
--- /dev/null
+++ b/Tests/RunCMake/File_Generate/AdjacentInOut.cmake
@@ -0,0 +1,6 @@
+cmake_policy(SET CMP0070 NEW)
+if(EXISTS "${CMAKE_CURRENT_BINARY_DIR}/AdjacentInOut.txt")
+ message(FATAL_ERROR "CMake should not re-run during the build!")
+endif()
+configure_file(AdjacentInOut.in ${CMAKE_CURRENT_BINARY_DIR}/AdjacentInOut.txt.tmp)
+file(GENERATE OUTPUT AdjacentInOut.txt INPUT ${CMAKE_CURRENT_BINARY_DIR}/AdjacentInOut.txt.tmp)