[Cmake-commits] CMake branch, next, updated. v3.3.0-1446-gc8d4d22
Stephen Kelly
steveire at gmail.com
Mon Jul 27 15:56:45 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 c8d4d22f10318295eb55dbf65795d42c3443411d (commit)
via 4a085a641c97ef1d2d10e05ddf31cfd345d98ffd (commit)
via 80fbbfe0e72aedd7048bed84f9021e49bc2a5bae (commit)
via 8a100aff162116bac950e5265277937c5f1da109 (commit)
from d151f0063701e6788bd60bfc5faae9fc3f95fcb7 (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=c8d4d22f10318295eb55dbf65795d42c3443411d
commit c8d4d22f10318295eb55dbf65795d42c3443411d
Merge: d151f00 4a085a6
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Jul 27 15:56:44 2015 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Jul 27 15:56:44 2015 -0400
Merge topic 'use-generator-target' into next
4a085a64 fixup! cmGlobalGenerator: Add global targets at the end of Configure.
80fbbfe0 cmLocalGenerator: Remove unused AddCustomCommandToCreateObject method.
8a100aff cmLocalGenerator: Remove unused AddBuildTargetRule method.
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=4a085a641c97ef1d2d10e05ddf31cfd345d98ffd
commit 4a085a641c97ef1d2d10e05ddf31cfd345d98ffd
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Jul 27 21:49:25 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Jul 27 21:51:41 2015 +0200
fixup! cmGlobalGenerator: Add global targets at the end of Configure.
diff --git a/Source/cmGlobalGenerator.cxx b/Source/cmGlobalGenerator.cxx
index 99263c1..2b7c1b2 100644
--- a/Source/cmGlobalGenerator.cxx
+++ b/Source/cmGlobalGenerator.cxx
@@ -1392,6 +1392,10 @@ void cmGlobalGenerator::CreateQtAutoGeneratorsTargets(AutogensType &autogens)
for(cmTargets::iterator ti = targets.begin();
ti != targets.end(); ++ti)
{
+ if (ti->second.GetType() == cmTarget::GLOBAL_TARGET)
+ {
+ continue;
+ }
targetNames.push_back(ti->second.GetName());
}
for(std::vector<std::string>::iterator ti = targetNames.begin();
@@ -1441,6 +1445,10 @@ void cmGlobalGenerator::FinalizeTargetCompileInfo()
ti != targets.end(); ++ti)
{
cmTarget* t = &ti->second;
+ if (t->GetType() == cmTarget::GLOBAL_TARGET)
+ {
+ continue;
+ }
t->AppendBuildInterfaceIncludes();
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=80fbbfe0e72aedd7048bed84f9021e49bc2a5bae
commit 80fbbfe0e72aedd7048bed84f9021e49bc2a5bae
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Jul 27 20:58:28 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Jul 27 21:05:53 2015 +0200
cmLocalGenerator: Remove unused AddCustomCommandToCreateObject method.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 8f35a74..2e20ee2 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -448,84 +448,6 @@ cmState::Snapshot cmLocalGenerator::GetStateSnapshot() const
return this->StateSnapshot;
}
-void cmLocalGenerator::AddCustomCommandToCreateObject(const char* ofname,
- const std::string& lang,
- cmSourceFile& source,
- cmGeneratorTarget& target)
-{
- std::string objectDir = cmSystemTools::GetFilenamePath(std::string(ofname));
- objectDir = this->Convert(objectDir,START_OUTPUT,SHELL);
- std::string objectFile = this->Convert(ofname,START_OUTPUT,SHELL);
- std::string sourceFile =
- this->ConvertToOutputFormat(source.GetFullPath(), SHELL);
- std::string varString = "CMAKE_";
- varString += lang;
- varString += "_COMPILE_OBJECT";
- std::vector<std::string> rules;
- rules.push_back(this->Makefile->GetRequiredDefinition(varString));
- varString = "CMAKE_";
- varString += lang;
- varString += "_FLAGS";
- std::string flags;
- flags += this->Makefile->GetSafeDefinition(varString);
- flags += " ";
- {
- std::vector<std::string> includes;
- this->GetIncludeDirectories(includes, &target, lang);
- flags += this->GetIncludeFlags(includes, &target, lang);
- }
- flags += this->Makefile->GetDefineFlags();
-
- // Construct the command lines.
- cmCustomCommandLines commandLines;
- std::vector<std::string> commands;
- cmSystemTools::ExpandList(rules, commands);
- cmLocalGenerator::RuleVariables vars;
- vars.Language = lang.c_str();
- vars.Source = sourceFile.c_str();
- vars.Object = objectFile.c_str();
- vars.ObjectDir = objectDir.c_str();
- vars.Flags = flags.c_str();
- for(std::vector<std::string>::iterator i = commands.begin();
- i != commands.end(); ++i)
- {
- // Expand the full command line string.
- this->ExpandRuleVariables(*i, vars);
-
- // Parse the string to get the custom command line.
- cmCustomCommandLine commandLine;
- std::vector<std::string> cmd = cmSystemTools::ParseArguments(i->c_str());
- commandLine.insert(commandLine.end(), cmd.begin(), cmd.end());
-
- // Store this command line.
- commandLines.push_back(commandLine);
- }
-
- // Check for extra object-file dependencies.
- std::vector<std::string> depends;
- const char* additionalDeps = source.GetProperty("OBJECT_DEPENDS");
- if(additionalDeps)
- {
- cmSystemTools::ExpandListArgument(additionalDeps, depends);
- }
-
- // Generate a meaningful comment for the command.
- std::string comment = "Building ";
- comment += lang;
- comment += " object ";
- comment += this->Convert(ofname, START_OUTPUT);
-
- // Add the custom command to build the object file.
- this->Makefile->AddCustomCommandToOutput(
- ofname,
- depends,
- source.GetFullPath(),
- commandLines,
- comment.c_str(),
- this->StateSnapshot.GetDirectory().GetCurrentBinary()
- );
-}
-
// List of variables that are replaced when
// rules are expanced. These variables are
// replaced in the form <var> with GetSafeDefinition(var).
diff --git a/Source/cmLocalGenerator.h b/Source/cmLocalGenerator.h
index 429d5fc..2971574 100644
--- a/Source/cmLocalGenerator.h
+++ b/Source/cmLocalGenerator.h
@@ -328,12 +328,6 @@ protected:
void InsertRuleLauncher(std::string& s, cmTarget* target,
const std::string& prop);
- ///! add a custom command to build a .o file that is part of a target
- void AddCustomCommandToCreateObject(const char* ofname,
- const std::string& lang,
- cmSourceFile& source,
- cmGeneratorTarget& target);
-
// Handle old-style install rules stored in the targets.
void GenerateTargetInstallRules(
std::ostream& os, const std::string& config,
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=8a100aff162116bac950e5265277937c5f1da109
commit 8a100aff162116bac950e5265277937c5f1da109
Author: Stephen Kelly <steveire at gmail.com>
AuthorDate: Mon Jul 27 20:57:39 2015 +0200
Commit: Stephen Kelly <steveire at gmail.com>
CommitDate: Mon Jul 27 21:05:34 2015 +0200
cmLocalGenerator: Remove unused AddBuildTargetRule method.
diff --git a/Source/cmLocalGenerator.cxx b/Source/cmLocalGenerator.cxx
index 53d0778..8f35a74 100644
--- a/Source/cmLocalGenerator.cxx
+++ b/Source/cmLocalGenerator.cxx
@@ -526,106 +526,6 @@ void cmLocalGenerator::AddCustomCommandToCreateObject(const char* ofname,
);
}
-void cmLocalGenerator::AddBuildTargetRule(const std::string& llang,
- cmGeneratorTarget& target)
-{
- std::string objs;
- std::vector<std::string> objVector;
- std::string config = this->Makefile->GetSafeDefinition("CMAKE_BUILD_TYPE");
- // Add all the sources outputs to the depends of the target
- std::vector<cmSourceFile*> classes;
- target.GetSourceFiles(classes, config);
- for(std::vector<cmSourceFile*>::const_iterator i = classes.begin();
- i != classes.end(); ++i)
- {
- cmSourceFile* sf = *i;
- if(!sf->GetCustomCommand() &&
- !sf->GetPropertyAsBool("HEADER_FILE_ONLY") &&
- !sf->GetPropertyAsBool("EXTERNAL_OBJECT"))
- {
- std::string dir_max;
- dir_max += this->StateSnapshot.GetDirectory().GetCurrentBinary();
- dir_max += "/";
- std::string obj = this->GetObjectFileNameWithoutTarget(*sf, dir_max);
- if(!obj.empty())
- {
- std::string ofname =
- this->StateSnapshot.GetDirectory().GetCurrentBinary();
- ofname += "/";
- ofname += obj;
- objVector.push_back(ofname);
- this->AddCustomCommandToCreateObject(ofname.c_str(),
- llang, *(*i), target);
- objs += this->Convert(ofname,START_OUTPUT,SHELL);
- objs += " ";
- }
- }
- }
- std::string createRule = target.GetCreateRuleVariable(llang, config);
- bool useWatcomQuote = this->Makefile->IsOn(createRule+"_USE_WATCOM_QUOTE");
- std::string targetName = target.Target->GetFullName();
- // Executable :
- // Shared Library:
- // Static Library:
- // Shared Module:
- std::string linkLibs; // should be set
- std::string frameworkPath;
- std::string linkPath;
- std::string flags; // should be set
- std::string linkFlags; // should be set
- this->GetTargetFlags(linkLibs, frameworkPath, linkPath, flags, linkFlags,
- &target, useWatcomQuote);
- linkLibs = frameworkPath + linkPath + linkLibs;
- cmLocalGenerator::RuleVariables vars;
- vars.Language = llang.c_str();
- vars.Objects = objs.c_str();
- vars.ObjectDir = ".";
- vars.Target = targetName.c_str();
- vars.LinkLibraries = linkLibs.c_str();
- vars.Flags = flags.c_str();
- vars.LinkFlags = linkFlags.c_str();
-
- std::string langFlags;
- this->AddLanguageFlags(langFlags, llang, "");
- this->AddArchitectureFlags(langFlags, &target, llang, "");
- vars.LanguageCompileFlags = langFlags.c_str();
-
- cmCustomCommandLines commandLines;
- std::vector<std::string> rules;
- rules.push_back(this->Makefile->GetRequiredDefinition(createRule));
- std::vector<std::string> commands;
- cmSystemTools::ExpandList(rules, commands);
- for(std::vector<std::string>::iterator i = commands.begin();
- i != commands.end(); ++i)
- {
- // Expand the full command line string.
- this->ExpandRuleVariables(*i, vars);
- // Parse the string to get the custom command line.
- cmCustomCommandLine commandLine;
- std::vector<std::string> cmd = cmSystemTools::ParseArguments(i->c_str());
- commandLine.insert(commandLine.end(), cmd.begin(), cmd.end());
-
- // Store this command line.
- commandLines.push_back(commandLine);
- }
- std::string targetFullPath = target.GetFullPath();
- // Generate a meaningful comment for the command.
- std::string comment = "Linking ";
- comment += llang;
- comment += " target ";
- comment += this->Convert(targetFullPath, START_OUTPUT);
- this->Makefile->AddCustomCommandToOutput(
- targetFullPath,
- objVector,
- "",
- commandLines,
- comment.c_str(),
- this->StateSnapshot.GetDirectory().GetCurrentBinary()
- );
- this->Makefile->GetSource(targetFullPath);
- target.Target->AddSource(targetFullPath);
-}
-
// List of variables that are replaced when
// rules are expanced. These variables are
// replaced in the form <var> with GetSafeDefinition(var).
diff --git a/Source/cmLocalGenerator.h b/Source/cmLocalGenerator.h
index fee2420..429d5fc 100644
--- a/Source/cmLocalGenerator.h
+++ b/Source/cmLocalGenerator.h
@@ -328,11 +328,6 @@ protected:
void InsertRuleLauncher(std::string& s, cmTarget* target,
const std::string& prop);
-
- /** Convert a target to a utility target for unsupported
- * languages of a generator */
- void AddBuildTargetRule(const std::string& llang,
- cmGeneratorTarget& target);
///! add a custom command to build a .o file that is part of a target
void AddCustomCommandToCreateObject(const char* ofname,
const std::string& lang,
-----------------------------------------------------------------------
Summary of changes:
Source/cmGlobalGenerator.cxx | 8 ++
Source/cmLocalGenerator.cxx | 178 ------------------------------------------
Source/cmLocalGenerator.h | 11 ---
3 files changed, 8 insertions(+), 189 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list