[Cmake-commits] CMake branch, next, updated. v2.8.11-2475-g075a0ec
Stephen Kelly
steveire at gmail.com
Tue Jun 4 05:03:30 EDT 2013
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".
The branch, next has been updated
via 075a0ec362f3c24721db0be33964ae8ce50d8c43 (commit)
via c6181fb6376481dd59423b84d08db571cf989661 (commit)
from 0e4620d1ceea0528a1d1b019c576c55bbe5d5520 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=075a0ec362f3c24721db0be33964ae8ce50d8c43
commit 075a0ec362f3c24721db0be33964ae8ce50d8c43
Merge: 0e4620d c6181fb
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Tue Jun 4 05:03:29 2013 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Jun 4 05:03:29 2013 -0400
Merge topic 'fix-genex-HEAD-target' into next
c6181fb Genex: Fix the HEAD target used for evaluated expressions.
diff --cc Source/cmGeneratorExpressionEvaluator.cxx
index 28f749d,a01a0f8..da3b311
--- a/Source/cmGeneratorExpressionEvaluator.cxx
+++ b/Source/cmGeneratorExpressionEvaluator.cxx
@@@ -724,14 -538,9 +724,16 @@@ static const struct TargetPropertyNode
{
interfacePropertyName = "INTERFACE_COMPILE_DEFINITIONS";
}
+ else if (propertyName == "INTERFACE_COMPILE_OPTIONS"
+ || propertyName == "COMPILE_OPTIONS")
+ {
+ interfacePropertyName = "INTERFACE_COMPILE_OPTIONS";
+ }
+
+ cmTarget *headTarget = context->HeadTarget ? context->HeadTarget : target;
+ cmTarget *headTarget = context->HeadTarget ? context->HeadTarget : target;
+
const char **transBegin = targetPropertyTransitiveWhitelist;
const char **transEnd = targetPropertyTransitiveWhitelist
+ (sizeof(targetPropertyTransitiveWhitelist) /
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c6181fb6376481dd59423b84d08db571cf989661
commit c6181fb6376481dd59423b84d08db571cf989661
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Jun 3 23:53:29 2013 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Tue Jun 4 11:03:15 2013 +0200
Genex: Fix the HEAD target used for evaluated expressions.
If the expression $<TARGET_PROPERTY:prop> appears in the content
of a target property, the target that prop is read from is
the 'head target' of the expression. In contexts such as evaluating
the content of a target property during generation, such
as INCLUDE_DIRECTORIES, the 'head target' is the one on which the
initial request was made.
If evaluating a generator expression which is not a target property
content, the target must be explicitly specified. Such contexts
include add_custom_command and file(GENERATE). The content might
then look like
$<TARGET_PROPERTY:tgt,prop>
However, as there is no HeadTarget set, any generator expressions
evaluated as part of reading prop from tgt which do not specify
the tgt directly report an error.
Modify the logic of the TARGET_PROPERTY generator expression so
that in such contexts, the 'head target' is set to the appropriate
target which was first encountered.
diff --git a/Source/cmGeneratorExpressionEvaluator.cxx b/Source/cmGeneratorExpressionEvaluator.cxx
index de6371a..a01a0f8 100644
--- a/Source/cmGeneratorExpressionEvaluator.cxx
+++ b/Source/cmGeneratorExpressionEvaluator.cxx
@@ -315,6 +315,7 @@ static const char* targetPropertyTransitiveWhitelist[] = {
std::string getLinkedTargetsContent(const std::vector<std::string> &libraries,
cmTarget *target,
+ cmTarget *headTarget,
cmGeneratorExpressionContext *context,
cmGeneratorExpressionDAGChecker *dagChecker,
const std::string &interfacePropertyName)
@@ -345,7 +346,7 @@ std::string getLinkedTargetsContent(const std::vector<std::string> &libraries,
std::string linkedTargetsContent = cge->Evaluate(context->Makefile,
context->Config,
context->Quiet,
- context->HeadTarget,
+ headTarget,
target,
dagChecker);
if (cge->GetHadContextSensitiveCondition())
@@ -538,6 +539,8 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
interfacePropertyName = "INTERFACE_COMPILE_DEFINITIONS";
}
+ cmTarget *headTarget = context->HeadTarget ? context->HeadTarget : target;
+
const char **transBegin = targetPropertyTransitiveWhitelist;
const char **transEnd = targetPropertyTransitiveWhitelist
+ (sizeof(targetPropertyTransitiveWhitelist) /
@@ -547,11 +550,12 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
{
const cmTarget::LinkInterface *iface = target->GetLinkInterface(
context->Config,
- context->HeadTarget);
+ headTarget);
if(iface)
{
linkedTargetsContent =
getLinkedTargetsContent(iface->Libraries, target,
+ headTarget,
context, &dagChecker,
interfacePropertyName);
}
@@ -561,11 +565,12 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
{
const cmTarget::LinkImplementation *impl = target->GetLinkImplementation(
context->Config,
- context->HeadTarget);
+ headTarget);
if(impl)
{
linkedTargetsContent =
getLinkedTargetsContent(impl->Libraries, target,
+ headTarget,
context, &dagChecker,
interfacePropertyName);
}
@@ -614,7 +619,7 @@ static const struct TargetPropertyNode : public cmGeneratorExpressionNode
std::string result = cge->Evaluate(context->Makefile,
context->Config,
context->Quiet,
- context->HeadTarget,
+ headTarget,
target,
&dagChecker);
-----------------------------------------------------------------------
Summary of changes:
Source/cmGeneratorExpressionEvaluator.cxx | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list