diff options
author | Ben Boeckel <ben.boeckel@kitware.com> | 2017-04-18 19:12:32 (GMT) |
---|---|---|
committer | Ben Boeckel <ben.boeckel@kitware.com> | 2017-04-21 12:57:40 (GMT) |
commit | d96e5d9a19d613de108ab399663f76a8dd964172 (patch) | |
tree | 1bf851af8038a58af5df6c31291a9deecf765ddf /Tests/CustomCommandWorkingDirectory | |
parent | 664591ce59792f6508d6376aca916ab0f02d213f (diff) | |
download | CMake-d96e5d9a19d613de108ab399663f76a8dd964172.zip CMake-d96e5d9a19d613de108ab399663f76a8dd964172.tar.gz CMake-d96e5d9a19d613de108ab399663f76a8dd964172.tar.bz2 |
Tests: use BYPRODUCTS in the CustomCommandWorkingDirectory test
This was inadvertently testing the assumed sources behavior in Ninja (no
other test seems to exercise it). There is now a test explicitly testing
it in `RunCMake.Ninja`, so fix this test to work properly regardless of
the assumed sources behavior.
Diffstat (limited to 'Tests/CustomCommandWorkingDirectory')
-rw-r--r-- | Tests/CustomCommandWorkingDirectory/CMakeLists.txt | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Tests/CustomCommandWorkingDirectory/CMakeLists.txt b/Tests/CustomCommandWorkingDirectory/CMakeLists.txt index f917cd7..4975feb 100644 --- a/Tests/CustomCommandWorkingDirectory/CMakeLists.txt +++ b/Tests/CustomCommandWorkingDirectory/CMakeLists.txt @@ -19,6 +19,7 @@ add_executable(working "${TestWorkingDir_BINARY_DIR}/working.c" add_custom_target( Custom ALL COMMAND "${CMAKE_COMMAND}" -E copy_if_different ./customTarget.c "${TestWorkingDir_BINARY_DIR}/customTarget.c" + BYPRODUCTS "${TestWorkingDir_BINARY_DIR}/customTarget.c" WORKING_DIRECTORY "${TestWorkingDir_SOURCE_DIR}" ) @@ -36,6 +37,7 @@ add_executable(working2 working2.c ${TestWorkingDir_BINARY_DIR}/customTarget2.c) add_custom_target( Custom2 ALL COMMAND "${CMAKE_COMMAND}" -E copy_if_different ${TestWorkingDir_SOURCE_DIR}/customTarget.c ../customTarget2.c + BYPRODUCTS "${TestWorkingDir_BINARY_DIR}/customTarget2.c" WORKING_DIRECTORY work/ # Relative to build tree, trailing slash ) |