summaryrefslogtreecommitdiffstats
path: root/Tests
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-10-29 13:45:45 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2013-10-29 13:45:45 (GMT)
commit8f80eaf98175f9a60089f8146d4c9281e72d72f4 (patch)
tree080f0832163b1ae3cdca86cb9596df4e7086e7b0 /Tests
parentafe6adfabaabab8808ff441172319cf357b30886 (diff)
parentf037b9b72644f150c136540b990774a3b32d39cf (diff)
downloadCMake-8f80eaf98175f9a60089f8146d4c9281e72d72f4.zip
CMake-8f80eaf98175f9a60089f8146d4c9281e72d72f4.tar.gz
CMake-8f80eaf98175f9a60089f8146d4c9281e72d72f4.tar.bz2
Merge topic 'fix-custom-source-with-flags-crash'
f037b9b Generators: don't append sources from utility targets to objectSources
Diffstat (limited to 'Tests')
-rw-r--r--Tests/CustomCommand/CMakeLists.txt7
-rw-r--r--Tests/CustomCommand/source_in_custom_target.cpp0
2 files changed, 7 insertions, 0 deletions
diff --git a/Tests/CustomCommand/CMakeLists.txt b/Tests/CustomCommand/CMakeLists.txt
index 30daa7d..ff96add 100644
--- a/Tests/CustomCommand/CMakeLists.txt
+++ b/Tests/CustomCommand/CMakeLists.txt
@@ -449,3 +449,10 @@ set_property(SOURCE perconfig.out PROPERTY SYMBOLIC 1)
add_custom_target(perconfig_target ALL
COMMAND ${CMAKE_COMMAND} -E echo "perconfig=$<TARGET_FILE:perconfig>" "config=$<CONFIGURATION>"
DEPENDS perconfig.out)
+
+# Test SOURCES in add_custom_target() with COMPILE_DEFINITIONS
+# which previously caused a crash in the makefile generators.
+add_custom_target(source_in_custom_target SOURCES source_in_custom_target.cpp)
+set_property(SOURCE source_in_custom_target
+ PROPERTY COMPILE_DEFINITIONS "TEST"
+)
diff --git a/Tests/CustomCommand/source_in_custom_target.cpp b/Tests/CustomCommand/source_in_custom_target.cpp
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/Tests/CustomCommand/source_in_custom_target.cpp