summaryrefslogtreecommitdiffstats
path: root/Source/cmGeneratorExpressionNode.cxx
diff options
context:
space:
mode:
authorDeniz Bahadir <dbahadir@benocs.com>2020-09-22 12:04:26 (GMT)
committerBrad King <brad.king@kitware.com>2020-09-23 14:05:55 (GMT)
commit2f76e7429b96ae05e5f63d6458555a06b19c62e5 (patch)
tree8496837a64a4165fa340017e45d6fc43bcaa780b /Source/cmGeneratorExpressionNode.cxx
parentd575ecc9dedd214ebd941913b81124a674be5008 (diff)
downloadCMake-2f76e7429b96ae05e5f63d6458555a06b19c62e5.zip
CMake-2f76e7429b96ae05e5f63d6458555a06b19c62e5.tar.gz
CMake-2f76e7429b96ae05e5f63d6458555a06b19c62e5.tar.bz2
OBJECT libraries: Properly recognize if sources depend on configuration
Fixes: #21198
Diffstat (limited to 'Source/cmGeneratorExpressionNode.cxx')
-rw-r--r--Source/cmGeneratorExpressionNode.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/cmGeneratorExpressionNode.cxx b/Source/cmGeneratorExpressionNode.cxx
index d3308e2..4ca7405 100644
--- a/Source/cmGeneratorExpressionNode.cxx
+++ b/Source/cmGeneratorExpressionNode.cxx
@@ -1664,9 +1664,8 @@ static const struct TargetObjectsNode : public cmGeneratorExpressionNode
if (context->EvaluateForBuildsystem) {
// Use object file directory with buildsystem placeholder.
obj_dir = gt->ObjectDirectory;
- // Here we assume that the set of object files produced
- // by an object library does not vary with configuration
- // and do not set HadContextSensitiveCondition to true.
+ context->HadContextSensitiveCondition =
+ gt->HasContextDependentSources();
} else {
// Use object file directory with per-config location.
obj_dir = gt->GetObjectDirectory(context->Config);