diff options
Diffstat (limited to 'Tests/CustomCommand')
-rw-r--r-- | Tests/CustomCommand/GeneratedHeader/CMakeLists.txt | 10 | ||||
-rw-r--r-- | Tests/CustomCommand/GeneratedHeader/generated.h.in | 1 | ||||
-rw-r--r-- | Tests/CustomCommand/GeneratedHeader/main.cpp | 5 |
3 files changed, 16 insertions, 0 deletions
diff --git a/Tests/CustomCommand/GeneratedHeader/CMakeLists.txt b/Tests/CustomCommand/GeneratedHeader/CMakeLists.txt new file mode 100644 index 0000000..0ab333b --- /dev/null +++ b/Tests/CustomCommand/GeneratedHeader/CMakeLists.txt @@ -0,0 +1,10 @@ +ADD_CUSTOM_COMMAND(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/generated.h + COMMAND + ${CMAKE_COMMAND} ARGS -E + copy ${CMAKE_CURRENT_SOURCE_DIR}/generated.h.in + ${CMAKE_CURRENT_BINARY_DIR}/generated.h +) + +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_BINARY_DIR}) +ADD_LIBRARY(GeneratedHeader main.cpp) + diff --git a/Tests/CustomCommand/GeneratedHeader/generated.h.in b/Tests/CustomCommand/GeneratedHeader/generated.h.in new file mode 100644 index 0000000..ae6f64c --- /dev/null +++ b/Tests/CustomCommand/GeneratedHeader/generated.h.in @@ -0,0 +1 @@ +//hello diff --git a/Tests/CustomCommand/GeneratedHeader/main.cpp b/Tests/CustomCommand/GeneratedHeader/main.cpp new file mode 100644 index 0000000..254ecf5 --- /dev/null +++ b/Tests/CustomCommand/GeneratedHeader/main.cpp @@ -0,0 +1,5 @@ +#include "generated.h" +main() +{ + +} |