summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2014-05-28 20:02:57 (GMT)
committerStephen Kelly <steveire@gmail.com>2014-05-29 09:29:31 (GMT)
commitfb2fa4765611bbf94fdf63a50ff20c5905d34057 (patch)
tree71e35fb7339df206bf77b4b58dadeba92446f926 /Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake
parent5e9441cd39f9112acc052d465ebd9f21f29ad581 (diff)
downloadCMake-fb2fa4765611bbf94fdf63a50ff20c5905d34057.zip
CMake-fb2fa4765611bbf94fdf63a50ff20c5905d34057.tar.gz
CMake-fb2fa4765611bbf94fdf63a50ff20c5905d34057.tar.bz2
Genex: Clarify error message on use with non-binary targets (#14899).
Diffstat (limited to 'Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake')
-rw-r--r--Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake8
1 files changed, 8 insertions, 0 deletions
diff --git a/Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake b/Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake
new file mode 100644
index 0000000..1afb2b5
--- /dev/null
+++ b/Tests/RunCMake/GeneratorExpression/NonValidTarget-CXX_COMPILER_VERSION.cmake
@@ -0,0 +1,8 @@
+
+enable_language(CXX)
+
+add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/copied_file.cpp"
+ COMMAND "${CMAKE_COMMAND}" -E copy "${CMAKE_CURRENT_SOURCE_DIR}/empty.cpp" "${CMAKE_CURRENT_BINARY_DIR}/copied_file$<CXX_COMPILER_VERSION>.cpp"
+)
+
+add_library(empty "${CMAKE_CURRENT_BINARY_DIR}/copied_file.cpp")