[Cmake-commits] CMake branch, next, updated. v2.8.3-832-ga3f94a4
Brad King
brad.king at kitware.com
Mon Dec 13 13:03:42 EST 2010
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 a3f94a43b4b3db9a294801a3f810fcb6a4b59307 (commit)
via 8e82773eb4e2bb8d135479410393532021d3b85b (commit)
via 0621362668af7b5ec73689c75f6c9318425500f9 (commit)
from 37929fe34bdd226e05c78aa00a0f90a8d360fe4b (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=a3f94a43b4b3db9a294801a3f810fcb6a4b59307
commit a3f94a43b4b3db9a294801a3f810fcb6a4b59307
Merge: 37929fe 8e82773
Author: Brad King <brad.king at kitware.com>
AuthorDate: Mon Dec 13 13:03:39 2010 -0500
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Dec 13 13:03:39 2010 -0500
Merge topic 'fix-INSTALL-and-PACKAGE-depend-tracing' into next
8e82773 Remove unused GLOBAL_TARGET generation code
0621362 Fix dependency tracing of INSTALL and PACKAGE (#11598)
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=8e82773eb4e2bb8d135479410393532021d3b85b
commit 8e82773eb4e2bb8d135479410393532021d3b85b
Author: Brad King <brad.king at kitware.com>
AuthorDate: Mon Dec 13 11:23:38 2010 -0500
Commit: Brad King <brad.king at kitware.com>
CommitDate: Mon Dec 13 12:59:26 2010 -0500
Remove unused GLOBAL_TARGET generation code
Remove a boolean parameter of cmGlobalGenerator::CreateGlobalTarget that
is never set to true anymore. Remove global target "consolidation" loop
because no global targets exist before it runs anymore.
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index 15abd02..ea091f9 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -814,24 +814,11 @@ void cmGlobalGenerator::Generate()
// For each existing cmLocalGenerator
unsigned int i;
- // Consolidate global targets
+ // Put a copy of each global target in every directory.
cmTargets globalTargets;
this->CreateDefaultGlobalTargets(&globalTargets);
for (i = 0; i < this->LocalGenerators.size(); ++i)
{
- cmTargets* targets =
- &(this->LocalGenerators[i]->GetMakefile()->GetTargets());
- cmTargets::iterator tarIt;
- for ( tarIt = targets->begin(); tarIt != targets->end(); ++ tarIt )
- {
- if ( tarIt->second.GetType() == cmTarget::GLOBAL_TARGET )
- {
- globalTargets[tarIt->first] = tarIt->second;
- }
- }
- }
- for (i = 0; i < this->LocalGenerators.size(); ++i)
- {
cmMakefile* mf = this->LocalGenerators[i]->GetMakefile();
cmTargets* targets = &(mf->GetTargets());
cmTargets::iterator tit;
@@ -1881,8 +1868,7 @@ cmTarget cmGlobalGenerator::CreateGlobalTarget(
const char* name, const char* message,
const cmCustomCommandLines* commandLines,
std::vector<std::string> depends,
- const char* workingDirectory,
- bool depends_on_all /* = false */)
+ const char* workingDirectory)
{
// Package
cmTarget target;
@@ -1897,10 +1883,6 @@ cmTarget cmGlobalGenerator::CreateGlobalTarget(
workingDirectory);
target.GetPostBuildCommands().push_back(cc);
target.SetProperty("EchoString", message);
- if ( depends_on_all )
- {
- target.AddUtility("all");
- }
std::vector<std::string>::iterator dit;
for ( dit = depends.begin(); dit != depends.end(); ++ dit )
{
diff --git a/Source/cmGlobalGenerator.h b/Source/cmGlobalGenerator.h
index 7e43124..6a1aa53 100644
--- a/Source/cmGlobalGenerator.h
+++ b/Source/cmGlobalGenerator.h
@@ -291,8 +291,7 @@ protected:
void CreateDefaultGlobalTargets(cmTargets* targets);
cmTarget CreateGlobalTarget(const char* name, const char* message,
const cmCustomCommandLines* commandLines,
- std::vector<std::string> depends, const char* workingDir,
- bool depends_on_all = false);
+ std::vector<std::string> depends, const char* workingDir);
bool NeedSymbolicMark;
bool UseLinkScript;
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=0621362668af7b5ec73689c75f6c9318425500f9
commit 0621362668af7b5ec73689c75f6c9318425500f9
Author: Brad King <brad.king at kitware.com>
AuthorDate: Mon Dec 13 11:26:53 2010 -0500
Commit: Brad King <brad.king at kitware.com>
CommitDate: Mon Dec 13 12:56:47 2010 -0500
Fix dependency tracing of INSTALL and PACKAGE (#11598)
Commit e01cce28 (Allow add_dependencies() on imported targets,
2010-11-19) started using cmMakefile::FindTargetToUse to follow
dependencies, including those of GLOBAL_TARGETs like INSTALL and
PACKAGE. Since global targets exist in every directory, dependencies
between them must be traced within each directory too.
Teach FindTargetToUse to check the current directory before checking
globally. For global targets this will find the local copy. For for
normal targets this will be a no-op because they are globally unique.
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 56e0ed9..9983e5d 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -3590,6 +3590,12 @@ cmTarget* cmMakefile::FindTargetToUse(const char* name)
return imported->second;
}
+ // Look for a target built in this directory.
+ if(cmTarget* t = this->FindTarget(name))
+ {
+ return t;
+ }
+
// Look for a target built in this project.
return this->LocalGenerator->GetGlobalGenerator()->FindTarget(0, name);
}
-----------------------------------------------------------------------
Summary of changes:
Source/cmGlobalGenerator.cxx | 22 ++--------------------
Source/cmGlobalGenerator.h | 3 +--
Source/cmMakefile.cxx | 6 ++++++
3 files changed, 9 insertions(+), 22 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list