summaryrefslogtreecommitdiffstats
path: root/Tests/ExternalOBJ/Sub
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2012-03-19 21:14:52 (GMT)
committerBrad King <brad.king@kitware.com>2012-03-20 13:01:02 (GMT)
commitb291d9e756b76ce85ebcc314c14de532e8ad477f (patch)
tree1fa7e300567e215b929003dc913cea4a10225bc9 /Tests/ExternalOBJ/Sub
parent328c0f65c2a273c6adcdb11f96ee057d80014de2 (diff)
downloadCMake-b291d9e756b76ce85ebcc314c14de532e8ad477f.zip
CMake-b291d9e756b76ce85ebcc314c14de532e8ad477f.tar.gz
CMake-b291d9e756b76ce85ebcc314c14de532e8ad477f.tar.bz2
VS10: Fix external objects generated outside target (#13047)
Commit 9a6ff950 (Fix for bug where VS2010 did not use .obj files, 2011-04-01) assumed that if an external object is GENERATED that it is the output of a custom command in the current target. If it is generated by another target then VS will not automatically include the external object in the current target. This bug was preserved by the refactoring in the parent commit. Instead use <None> for external objects generated by a custom command in the current target and <Object> for all other external objects. Update the ExternalOBJ test to cover this case.
Diffstat (limited to 'Tests/ExternalOBJ/Sub')
-rw-r--r--Tests/ExternalOBJ/Sub/CMakeLists.txt3
1 files changed, 3 insertions, 0 deletions
diff --git a/Tests/ExternalOBJ/Sub/CMakeLists.txt b/Tests/ExternalOBJ/Sub/CMakeLists.txt
new file mode 100644
index 0000000..35cd30c
--- /dev/null
+++ b/Tests/ExternalOBJ/Sub/CMakeLists.txt
@@ -0,0 +1,3 @@
+set_property(SOURCE ${CUSTOM_OBJECT} PROPERTY GENERATED 1)
+add_executable(ExternalOBJSub ../executable.cxx ${CUSTOM_OBJECT})
+add_dependencies(ExternalOBJSub ExternalOBJ) # depend on generating target