[Cmake-commits] CMake branch, next, updated. v3.3.1-2395-g300f3e9
Stephen Kelly
steveire at gmail.com
Mon Aug 24 14:05:17 EDT 2015
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 300f3e937c0739efaaac7a3a1ddd1931cf0e6841 (commit)
via e3078aa15328439e239b2beb4085dc644ec465ec (commit)
via 7441fde34abf5a3eab58917b8bf4acb89d72c00c (commit)
via ad0b0089ab9f094192f6109067d79ef5e66c85b7 (commit)
via 314c9ae33bfd304c9622b89ec62bca052f6e0d39 (commit)
from 4c849cab1b87c33f6ae57962dc2150a8c61b7d39 (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=300f3e937c0739efaaac7a3a1ddd1931cf0e6841
commit 300f3e937c0739efaaac7a3a1ddd1931cf0e6841
Merge: 4c849ca e3078aa
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Aug 24 14:05:16 2015 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Aug 24 14:05:16 2015 -0400
Merge topic 'refactor-features' into next
e3078aa1 cmLocalGenerator: Implement GetFeature in terms of cmState.
7441fde3 cmLocalGenerator: Convert GetFeature recursion to loop.
ad0b0089 cmLocalGenerator: Simplify GetFeature implementation.
314c9ae3 cmLocalGenerator: Make GetFeature tail-recursive.
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e3078aa15328439e239b2beb4085dc644ec465ec
commit e3078aa15328439e239b2beb4085dc644ec465ec
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Sun Aug 2 09:18:37 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Aug 24 20:04:37 2015 +0200
cmLocalGenerator: Implement GetFeature in terms of cmState.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 8e12eb6..c2d1a7d 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2376,14 +2376,14 @@ const char* cmLocalGenerator::GetFeature(const std::string& feature,
featureName += "_";
featureName += cmSystemTools::UpperCase(config);
}
- cmLocalGenerator* lg = this;
- while(lg)
+ cmState::Snapshot snp = this->StateSnapshot;
+ while(snp.IsValid())
{
- if(const char* value = lg->GetMakefile()->GetProperty(featureName))
+ if(const char* value = snp.GetDirectory().GetProperty(featureName))
{
return value;
}
- lg = lg->GetParent();
+ snp = snp.GetBuildsystemDirectoryParent();
}
return 0;
}
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=7441fde34abf5a3eab58917b8bf4acb89d72c00c
commit 7441fde34abf5a3eab58917b8bf4acb89d72c00c
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Sun Aug 2 09:16:17 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Aug 24 20:04:37 2015 +0200
cmLocalGenerator: Convert GetFeature recursion to loop.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 2a88e3c..8e12eb6 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2376,16 +2376,16 @@ const char* cmLocalGenerator::GetFeature(const std::string& feature,
featureName += "_";
featureName += cmSystemTools::UpperCase(config);
}
- if(const char* value = this->Makefile->GetProperty(featureName))
+ cmLocalGenerator* lg = this;
+ while(lg)
{
- return value;
- }
- cmLocalGenerator* parent = this->GetParent();
- if(!parent)
- {
- return 0;
+ if(const char* value = lg->GetMakefile()->GetProperty(featureName))
+ {
+ return value;
+ }
+ lg = lg->GetParent();
}
- return parent->GetFeature(feature, config);
+ return 0;
}
//----------------------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ad0b0089ab9f094192f6109067d79ef5e66c85b7
commit ad0b0089ab9f094192f6109067d79ef5e66c85b7
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Sun Aug 2 09:14:28 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Aug 24 20:04:37 2015 +0200
cmLocalGenerator: Simplify GetFeature implementation.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 169cdf4..2a88e3c 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2368,19 +2368,15 @@ void cmLocalGenerator::AppendFeatureOptions(
const char* cmLocalGenerator::GetFeature(const std::string& feature,
const std::string& config)
{
+ std::string featureName = feature;
// TODO: Define accumulation policy for features (prepend, append, replace).
// Currently we always replace.
if(!config.empty())
{
- std::string featureConfig = feature;
- featureConfig += "_";
- featureConfig += cmSystemTools::UpperCase(config);
- if(const char* value = this->Makefile->GetProperty(featureConfig))
- {
- return value;
- }
+ featureName += "_";
+ featureName += cmSystemTools::UpperCase(config);
}
- if(const char* value = this->Makefile->GetProperty(feature))
+ if(const char* value = this->Makefile->GetProperty(featureName))
{
return value;
}
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=314c9ae33bfd304c9622b89ec62bca052f6e0d39
commit 314c9ae33bfd304c9622b89ec62bca052f6e0d39
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Sun Aug 2 09:11:55 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Aug 24 20:04:37 2015 +0200
cmLocalGenerator: Make GetFeature tail-recursive.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index edb644d..169cdf4 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -2384,11 +2384,12 @@ const char* cmLocalGenerator::GetFeature(const std::string& feature,
{
return value;
}
- if(cmLocalGenerator* parent = this->GetParent())
+ cmLocalGenerator* parent = this->GetParent();
+ if(!parent)
{
- return parent->GetFeature(feature, config);
+ return 0;
}
- return 0;
+ return parent->GetFeature(feature, config);
}
//----------------------------------------------------------------------------
-----------------------------------------------------------------------
Summary of changes:
Source/cmLocalGenerator.cxx | 21 +++++++++------------
1 file changed, 9 insertions(+), 12 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list