summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake')
-rw-r--r--Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake18
1 files changed, 18 insertions, 0 deletions
diff --git a/Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake b/Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake
new file mode 100644
index 0000000..76151cc
--- /dev/null
+++ b/Tests/RunCMake/Codegen/implicit-depends-append-codegen.cmake
@@ -0,0 +1,18 @@
+add_custom_command(
+ OUTPUT
+ ${CMAKE_CURRENT_BINARY_DIR}/main.cpp
+
+ # ERROR out if IMPLICIT_DEPENDS is used with CODEGEN
+ IMPLICIT_DEPENDS C main.c
+)
+
+add_custom_command(
+ OUTPUT
+ ${CMAKE_CURRENT_BINARY_DIR}/main.cpp
+ COMMAND
+ ${CMAKE_COMMAND} -E
+ copy ${CMAKE_CURRENT_SOURCE_DIR}/error.c
+ ${CMAKE_CURRENT_BINARY_DIR}/main.cpp
+ CODEGEN
+ APPEND
+)