[Cmake-commits] CMake branch, next, updated. v3.6.2-1881-g59edc3f
Daniel Pfeifer
daniel at pfeifer-mail.de
Thu Sep 8 17:55:07 EDT 2016
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 59edc3fb74ca1eb857601c63bb01c682c1a8466b (commit)
via cc6b948e5ea86996fe65014ce8f97bf92b46e4c0 (commit)
via 52052ef88b6f46a12c8430395ae8b419971fcb35 (commit)
via 3b3622305bb950f16f238f030c8f32786ad3511a (commit)
from 905f5f00754d5e3e632b829e4f4f2e4db6f64f52 (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 -----------------------------------------------------------------
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=59edc3fb74ca1eb857601c63bb01c682c1a8466b
commit 59edc3fb74ca1eb857601c63bb01c682c1a8466b
Merge: 905f5f0 cc6b948
Author: Daniel Pfeifer <daniel at pfeifer-mail.de>
AuthorDate: Thu Sep 8 17:55:06 2016 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Sep 8 17:55:06 2016 -0400
Merge topic 'cmGeneratorTarget-cleanup' into next
cc6b948e cmGeneratorTarget: factor out common part of AddSources commands
52052ef8 cmGeneratorTarget: use erase-unique instead of reinitialization
3b362230 cmGeneratorTarget: don't clear container in destructor
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=cc6b948e5ea86996fe65014ce8f97bf92b46e4c0
commit cc6b948e5ea86996fe65014ce8f97bf92b46e4c0
Author: Daniel Pfeifer <daniel at pfeifer-mail.de>
AuthorDate: Wed Sep 7 21:14:29 2016 +0200
Commit: Daniel Pfeifer <daniel at pfeifer-mail.de>
CommitDate: Thu Sep 8 23:47:16 2016 +0200
cmGeneratorTarget: factor out common part of AddSources commands
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index 4baec03..7dd8e7f 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -468,9 +468,8 @@ std::string cmGeneratorTarget::GetOutputName(const std::string& config,
return i->second;
}
-void cmGeneratorTarget::AddSource(const std::string& src)
+void cmGeneratorTarget::AddSourceCommon(const std::string& src)
{
- this->Target->AddSource(src);
cmListFileBacktrace lfbt = this->Makefile->GetBacktrace();
cmGeneratorExpression ge(lfbt);
CM_AUTO_PTR<cmCompiledGeneratorExpression> cge = ge.Parse(src);
@@ -480,19 +479,17 @@ void cmGeneratorTarget::AddSource(const std::string& src)
this->LinkImplementationLanguageIsContextDependent = true;
}
+void cmGeneratorTarget::AddSource(const std::string& src)
+{
+ this->Target->AddSource(src);
+ this->AddSourceCommon(src);
+}
+
void cmGeneratorTarget::AddTracedSources(std::vector<std::string> const& srcs)
{
this->Target->AddTracedSources(srcs);
if (!srcs.empty()) {
- std::string srcFiles = cmJoin(srcs, ";");
- this->SourceFilesMap.clear();
- this->LinkImplementationLanguageIsContextDependent = true;
- cmListFileBacktrace lfbt = this->Makefile->GetBacktrace();
- cmGeneratorExpression ge(lfbt);
- CM_AUTO_PTR<cmCompiledGeneratorExpression> cge = ge.Parse(srcFiles);
- cge->SetEvaluateForBuildsystem(true);
- this->SourceEntries.push_back(
- new cmGeneratorTarget::TargetPropertyEntry(cge));
+ this->AddSourceCommon(cmJoin(srcs, ";"));
}
}
diff --git a/Source/cmGeneratorTarget.h b/Source/cmGeneratorTarget.h
index 173f15d..715220e 100644
--- a/Source/cmGeneratorTarget.h
+++ b/Source/cmGeneratorTarget.h
@@ -540,6 +540,8 @@ public:
std::string GetFortranModuleDirectory() const;
private:
+ void AddSourceCommon(const std::string& src);
+
std::string CreateFortranModuleDirectory() const;
mutable bool FortranModuleDirectoryCreated;
mutable std::string FortranModuleDirectory;
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=52052ef88b6f46a12c8430395ae8b419971fcb35
commit 52052ef88b6f46a12c8430395ae8b419971fcb35
Author: Daniel Pfeifer <daniel at pfeifer-mail.de>
AuthorDate: Wed Sep 7 21:03:18 2016 +0200
Commit: Daniel Pfeifer <daniel at pfeifer-mail.de>
CommitDate: Thu Sep 8 23:46:45 2016 +0200
cmGeneratorTarget: use erase-unique instead of reinitialization
Just to make it easier to find places where containers are cleared in
order to be recomputed.
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index 25917f8..4baec03 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -839,14 +839,10 @@ bool cmGeneratorTarget::IsSystemIncludeDirectory(
&dagChecker, result, excludeImported);
}
- std::set<std::string> unique;
- for (std::vector<std::string>::iterator li = result.begin();
- li != result.end(); ++li) {
- cmSystemTools::ConvertToUnixSlashes(*li);
- unique.insert(*li);
- }
- result.clear();
- result.insert(result.end(), unique.begin(), unique.end());
+ std::for_each(result.begin(), result.end(),
+ cmSystemTools::ConvertToUnixSlashes);
+ std::sort(result.begin(), result.end());
+ result.erase(std::unique(result.begin(), result.end()), result.end());
IncludeCacheType::value_type entry(config_upper, result);
iter = this->SystemIncludesCache.insert(entry).first;
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=3b3622305bb950f16f238f030c8f32786ad3511a
commit 3b3622305bb950f16f238f030c8f32786ad3511a
Author: Daniel Pfeifer <daniel at pfeifer-mail.de>
AuthorDate: Wed Sep 7 20:40:18 2016 +0200
Commit: Daniel Pfeifer <daniel at pfeifer-mail.de>
CommitDate: Thu Sep 8 23:46:18 2016 +0200
cmGeneratorTarget: don't clear container in destructor
It will be destroyed anyway. This also makes it easier to search for
places where containers are atually cleared in order to be recomputed.
diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx
index ee2907c..25917f8 100644
--- a/Source/cmGeneratorTarget.cxx
+++ b/Source/cmGeneratorTarget.cxx
@@ -327,7 +327,6 @@ cmGeneratorTarget::~cmGeneratorTarget()
cmDeleteAll(this->CompileDefinitionsEntries);
cmDeleteAll(this->SourceEntries);
cmDeleteAll(this->LinkInformation);
- this->LinkInformation.clear();
}
cmLocalGenerator* cmGeneratorTarget::GetLocalGenerator() const
-----------------------------------------------------------------------
Summary of changes:
Source/cmGeneratorTarget.cxx | 32 ++++++++++++--------------------
Source/cmGeneratorTarget.h | 2 ++
2 files changed, 14 insertions(+), 20 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list