summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-11-01 14:14:47 (GMT)
committerBrad King <brad.king@kitware.com>2013-11-01 14:17:01 (GMT)
commitd9605897788d800e892de0d201a305046510d089 (patch)
tree751cd077c6c7a5e919638300d6d17c40a8871ee9 /Source
parentc515dc574879448d66e2c5a27b9807d95a27fefd (diff)
downloadCMake-d9605897788d800e892de0d201a305046510d089.zip
CMake-d9605897788d800e892de0d201a305046510d089.tar.gz
CMake-d9605897788d800e892de0d201a305046510d089.tar.bz2
Genex: Reject $<TARGET_FILE:...> for object libraries (#14532)
Teach the cmGeneratorExpressionEvaluator filesystem artifact logic to reject OBJECT_LIBRARY targets since they have no main artifact. Without the explicit rejection evaluation falls through to an internal CMake error message in cmTarget::GetOutputInfo. Extend the RunCMake.GeneratorExpression test to cover these cases.
Diffstat (limited to 'Source')
-rw-r--r--Source/cmGeneratorExpressionEvaluator.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmGeneratorExpressionEvaluator.cxx b/Source/cmGeneratorExpressionEvaluator.cxx
index abe4e70..8b31354 100644
--- a/Source/cmGeneratorExpressionEvaluator.cxx
+++ b/Source/cmGeneratorExpressionEvaluator.cxx
@@ -1277,7 +1277,7 @@ struct TargetFilesystemArtifact : public cmGeneratorExpressionNode
"No target \"" + name + "\"");
return std::string();
}
- if(target->GetType() >= cmTarget::UTILITY &&
+ if(target->GetType() >= cmTarget::OBJECT_LIBRARY &&
target->GetType() != cmTarget::UNKNOWN_LIBRARY)
{
::reportError(context, content->GetOriginalExpression(),