[Cmake-commits] CMake branch, next, updated. v3.2.1-1207-gd59d361
Brad King
brad.king at kitware.com
Tue Mar 24 13:56:53 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 d59d361480e18cb70e9ca64faa57833bae023806 (commit)
via dbc9f8c6ad7d1d9e5e2a2715efceddbb87e2ce95 (commit)
via 54828b82c6c757794439533dda781cd12d0de1f2 (commit)
via a4427fa9d03ba251b3f0168a471d6f818ae69a95 (commit)
from 0437c473420f10b06488bf3d786c4c48b312d0f3 (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=d59d361480e18cb70e9ca64faa57833bae023806
commit d59d361480e18cb70e9ca64faa57833bae023806
Merge: 0437c47 dbc9f8c
Author: Brad King <brad.king at kitware.com>
AuthorDate: Tue Mar 24 13:56:51 2015 -0400
Commit: CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Mar 24 13:56:51 2015 -0400
Merge topic 'add-GreenHills-MULTI-generator' into next
dbc9f8c6 GHS: Do not use string::back() that is missing on VS 7.1
54828b82 GHS: Use !foo.empty() instead of foo.size() > 0
a4427fa9 GHS: Do not use C++11 enum name scope
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=dbc9f8c6ad7d1d9e5e2a2715efceddbb87e2ce95
commit dbc9f8c6ad7d1d9e5e2a2715efceddbb87e2ce95
Author: Brad King <brad.king at kitware.com>
AuthorDate: Tue Mar 24 13:56:02 2015 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Mar 24 13:56:02 2015 -0400
GHS: Do not use string::back() that is missing on VS 7.1
Use cmHasLiteralSuffix instead.
diff --git a/Source/cmGhsMultiTargetGenerator.cxx b/Source/cmGhsMultiTargetGenerator.cxx
index 70cfd8d..282eb53 100644
--- a/Source/cmGhsMultiTargetGenerator.cxx
+++ b/Source/cmGhsMultiTargetGenerator.cxx
@@ -32,7 +32,7 @@ cmGhsMultiTargetGenerator::cmGhsMultiTargetGenerator(cmTarget const *target)
char const *folderProp = this->Target->GetProperty("FOLDER");
RelBuildFilePath = NULL == folderProp ? "" : folderProp;
- if (!RelBuildFilePath.empty() && '/' != RelBuildFilePath.back()) {
+ if (!cmHasLiteralSuffix(RelBuildFilePath, "/")) {
RelBuildFilePath += "/";
}
RelBuildFilePath += Target->GetName() + "/";
@@ -40,13 +40,13 @@ cmGhsMultiTargetGenerator::cmGhsMultiTargetGenerator(cmTarget const *target)
RelOutputFileName = RelBuildFilePath + Target->GetName() + ".a";
RelBuildFileName = RelBuildFilePath;
- if (!RelBuildFileName.empty() && '/' != RelBuildFileName.back()) {
+ if (!cmHasLiteralSuffix(RelBuildFileName, "/")) {
RelBuildFileName += "/";
}
RelBuildFileName += BuildFileName;
std::string absPathToRoot(this->Makefile->GetHomeOutputDirectory());
- if (!absPathToRoot.empty() && '/' != absPathToRoot.back()) {
+ if (!cmHasLiteralSuffix(absPathToRoot, "/")) {
absPathToRoot += "/";
}
AbsBuildFilePath = absPathToRoot + RelBuildFilePath;
@@ -346,7 +346,7 @@ void cmGhsMultiTargetGenerator::WriteObjectLangOverride(
void cmGhsMultiTargetGenerator::WriteObjectDir(
cmGeneratedFileStream *fileStream, std::string const &dir) {
std::string workingDir(dir);
- if (!workingDir.empty() && '/' != workingDir.back()) {
+ if (!cmHasLiteralSuffix(workingDir, "/")) {
workingDir += "/";
}
workingDir += "Objs";
diff --git a/Source/cmGlobalGhsMultiGenerator.cxx b/Source/cmGlobalGhsMultiGenerator.cxx
index b955cac..cec0f8d 100644
--- a/Source/cmGlobalGhsMultiGenerator.cxx
+++ b/Source/cmGlobalGhsMultiGenerator.cxx
@@ -322,7 +322,7 @@ void cmGlobalGhsMultiGenerator::AddFilesUpToPath(
std::vector<cmsys::String> splitPath =
cmSystemTools::SplitString(workingPath);
std::string workingRelPath(relPath);
- if (!relPath.empty() && '/' != relPath.back()) {
+ if (!cmHasLiteralSuffix(relPath, "/")) {
workingRelPath += "/";
}
std::string pathUpTo;
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=54828b82c6c757794439533dda781cd12d0de1f2
commit 54828b82c6c757794439533dda781cd12d0de1f2
Author: Brad King <brad.king at kitware.com>
AuthorDate: Tue Mar 24 13:51:48 2015 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Mar 24 13:51:48 2015 -0400
GHS: Use !foo.empty() instead of foo.size() > 0
diff --git a/Source/cmGhsMultiTargetGenerator.cxx b/Source/cmGhsMultiTargetGenerator.cxx
index a352a0d..70cfd8d 100644
--- a/Source/cmGhsMultiTargetGenerator.cxx
+++ b/Source/cmGhsMultiTargetGenerator.cxx
@@ -32,7 +32,7 @@ cmGhsMultiTargetGenerator::cmGhsMultiTargetGenerator(cmTarget const *target)
char const *folderProp = this->Target->GetProperty("FOLDER");
RelBuildFilePath = NULL == folderProp ? "" : folderProp;
- if (RelBuildFilePath.size() > 0 && '/' != RelBuildFilePath.back()) {
+ if (!RelBuildFilePath.empty() && '/' != RelBuildFilePath.back()) {
RelBuildFilePath += "/";
}
RelBuildFilePath += Target->GetName() + "/";
@@ -40,13 +40,13 @@ cmGhsMultiTargetGenerator::cmGhsMultiTargetGenerator(cmTarget const *target)
RelOutputFileName = RelBuildFilePath + Target->GetName() + ".a";
RelBuildFileName = RelBuildFilePath;
- if (RelBuildFileName.size() > 0 && '/' != RelBuildFileName.back()) {
+ if (!RelBuildFileName.empty() && '/' != RelBuildFileName.back()) {
RelBuildFileName += "/";
}
RelBuildFileName += BuildFileName;
std::string absPathToRoot(this->Makefile->GetHomeOutputDirectory());
- if (absPathToRoot.size() > 0 && '/' != absPathToRoot.back()) {
+ if (!absPathToRoot.empty() && '/' != absPathToRoot.back()) {
absPathToRoot += "/";
}
AbsBuildFilePath = absPathToRoot + RelBuildFilePath;
@@ -61,7 +61,7 @@ cmGhsMultiTargetGenerator::~cmGhsMultiTargetGenerator()
void cmGhsMultiTargetGenerator::Generate() {
std::vector<cmSourceFile *> objectSources = GetSources();
- if (objectSources.size() > 0 && IncludeThisTarget()) {
+ if (!objectSources.empty() && IncludeThisTarget()) {
if (!cmSystemTools::FileExists(AbsBuildFilePath.c_str())) {
cmSystemTools::MakeDirectory(AbsBuildFilePath.c_str());
}
@@ -286,13 +286,13 @@ void cmGhsMultiTargetGenerator::WriteCustomCommandsHelper(
cmCustomCommandLine const &command = *commandI;
for (cmCustomCommandLine::const_iterator commandLineI = command.begin();
commandLineI != command.end(); ++commandLineI) {
- if (command.size() > 0) {
+ if (!command.empty()) {
*GetFolderBuildStreams()
<< (command.begin() == commandLineI ? "'" : " ");
}
*GetFolderBuildStreams() << *commandLineI;
}
- if (command.size() > 0) {
+ if (!command.empty()) {
*GetFolderBuildStreams() << "'" << std::endl;
}
}
@@ -346,7 +346,7 @@ void cmGhsMultiTargetGenerator::WriteObjectLangOverride(
void cmGhsMultiTargetGenerator::WriteObjectDir(
cmGeneratedFileStream *fileStream, std::string const &dir) {
std::string workingDir(dir);
- if (workingDir.size() > 0 && '/' != workingDir.back()) {
+ if (!workingDir.empty() && '/' != workingDir.back()) {
workingDir += "/";
}
workingDir += "Objs";
diff --git a/Source/cmGlobalGhsMultiGenerator.cxx b/Source/cmGlobalGhsMultiGenerator.cxx
index 3be33db..b955cac 100644
--- a/Source/cmGlobalGhsMultiGenerator.cxx
+++ b/Source/cmGlobalGhsMultiGenerator.cxx
@@ -236,7 +236,7 @@ void cmGlobalGhsMultiGenerator::CloseBuildFileStream(
void cmGlobalGhsMultiGenerator::Generate() {
this->cmGlobalGenerator::Generate();
- if (this->LocalGenerators.size() > 0) {
+ if (!this->LocalGenerators.empty()) {
this->OpenBuildFileStream();
// Build all the folder build files
@@ -322,7 +322,7 @@ void cmGlobalGhsMultiGenerator::AddFilesUpToPath(
std::vector<cmsys::String> splitPath =
cmSystemTools::SplitString(workingPath);
std::string workingRelPath(relPath);
- if (relPath.size() > 0 && '/' != relPath.back()) {
+ if (!relPath.empty() && '/' != relPath.back()) {
workingRelPath += "/";
}
std::string pathUpTo;
@@ -417,7 +417,7 @@ void cmGlobalGhsMultiGenerator::UpdateBuildFiles(
for (cmGeneratorTargetsType::const_iterator tgtsI = tgts.begin();
tgtsI != tgts.end(); ++tgtsI) {
cmGhsMultiTargetGenerator gmtg(tgtsI->first);
- if (gmtg.GetSources().size() > 0 && gmtg.IncludeThisTarget()) {
+ if (!gmtg.GetSources().empty() && gmtg.IncludeThisTarget()) {
char const *rawFolderName = tgtsI->first->GetProperty("FOLDER");
if (NULL == rawFolderName) {
rawFolderName = "";
diff --git a/Source/cmLocalGhsMultiGenerator.cxx b/Source/cmLocalGhsMultiGenerator.cxx
index b700143..b60463f 100644
--- a/Source/cmLocalGhsMultiGenerator.cxx
+++ b/Source/cmLocalGhsMultiGenerator.cxx
@@ -22,7 +22,7 @@ cmLocalGhsMultiGenerator::~cmLocalGhsMultiGenerator() {}
void cmLocalGhsMultiGenerator::Generate() {
cmGeneratorTargetsType tgts = this->GetMakefile()->GetGeneratorTargets();
- if (tgts.size() > 0) {
+ if (!tgts.empty()) {
for (cmGeneratorTargetsType::iterator l = tgts.begin(); l != tgts.end();
++l) {
cmGhsMultiTargetGenerator tg(l->second->Target);
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a4427fa9d03ba251b3f0168a471d6f818ae69a95
commit a4427fa9d03ba251b3f0168a471d6f818ae69a95
Author: Brad King <brad.king at kitware.com>
AuthorDate: Tue Mar 24 13:47:52 2015 -0400
Commit: Brad King <brad.king at kitware.com>
CommitDate: Tue Mar 24 13:47:52 2015 -0400
GHS: Do not use C++11 enum name scope
diff --git a/Source/cmGhsMultiTargetGenerator.cxx b/Source/cmGhsMultiTargetGenerator.cxx
index 648751f..a352a0d 100644
--- a/Source/cmGhsMultiTargetGenerator.cxx
+++ b/Source/cmGhsMultiTargetGenerator.cxx
@@ -119,9 +119,9 @@ std::vector<cmSourceFile *> cmGhsMultiTargetGenerator::GetSources() const {
GhsMultiGpj::Types cmGhsMultiTargetGenerator::GetGpjTag() const {
GhsMultiGpj::Types output;
if (IsTargetGroup()) {
- output = GhsMultiGpj::Types::INTERGRITY_APPLICATION;
+ output = GhsMultiGpj::INTERGRITY_APPLICATION;
} else {
- output = GhsMultiGpj::Types::PROGRAM;
+ output = GhsMultiGpj::PROGRAM;
}
return output;
}
@@ -137,12 +137,12 @@ void cmGhsMultiTargetGenerator::WriteTypeSpecifics(const std::string &config,
std::string outputDir(GetOutputDirectory(config));
std::string outputFilename(GetOutputFilename(config));
- if (Target->GetType() == cmTarget::TargetType::STATIC_LIBRARY) {
+ if (Target->GetType() == cmTarget::STATIC_LIBRARY) {
*GetFolderBuildStreams() << " -relobj" << std::endl;
*GetFolderBuildStreams() << " {optgroup=GhsCommonOptions} -o \""
<< outputDir << outputFilename << ".a\""
<< std::endl;
- } else if (Target->GetType() == cmTarget::TargetType::EXECUTABLE) {
+ } else if (Target->GetType() == cmTarget::EXECUTABLE) {
if (notKernel && !IsTargetGroup()) {
*GetFolderBuildStreams() << " -relprog" << std::endl;
}
@@ -259,9 +259,9 @@ void cmGhsMultiTargetGenerator::WriteTargetLinkLibraries() {
void cmGhsMultiTargetGenerator::WriteCustomCommands() {
WriteCustomCommandsHelper(this->Target->GetPreBuildCommands(),
- cmTarget::CustomCommandType::PRE_BUILD);
+ cmTarget::PRE_BUILD);
WriteCustomCommandsHelper(this->Target->GetPostBuildCommands(),
- cmTarget::CustomCommandType::POST_BUILD);
+ cmTarget::POST_BUILD);
}
void cmGhsMultiTargetGenerator::WriteCustomCommandsHelper(
@@ -274,10 +274,10 @@ void cmGhsMultiTargetGenerator::WriteCustomCommandsHelper(
for (cmCustomCommandLines::const_iterator commandI = commands.begin();
commandI != commands.end(); ++commandI) {
switch (commandType) {
- case cmTarget::CustomCommandType::PRE_BUILD:
+ case cmTarget::PRE_BUILD:
*GetFolderBuildStreams() << " :preexecShellSafe=";
break;
- case cmTarget::CustomCommandType::POST_BUILD:
+ case cmTarget::POST_BUILD:
*GetFolderBuildStreams() << " :postexecShellSafe=";
break;
default:
@@ -312,7 +312,7 @@ void cmGhsMultiTargetGenerator::WriteSources(
cmGlobalGhsMultiGenerator::AddFilesUpToPath(
GetFolderBuildStreams(), &FolderBuildStreams,
this->Makefile->GetHomeOutputDirectory(), sgPath,
- GhsMultiGpj::Types::SUBPROJECT, RelBuildFilePath);
+ GhsMultiGpj::SUBPROJECT, RelBuildFilePath);
if ((*si)->GetExtension() == ".int") {
*this->FolderBuildStreams[sgPath] << "\"" << (*si)->GetFullPath() << "\""
diff --git a/Source/cmGlobalGhsMultiGenerator.cxx b/Source/cmGlobalGhsMultiGenerator.cxx
index 042339a..3be33db 100644
--- a/Source/cmGlobalGhsMultiGenerator.cxx
+++ b/Source/cmGlobalGhsMultiGenerator.cxx
@@ -214,7 +214,7 @@ void cmGlobalGhsMultiGenerator::OpenBuildFileStream() {
WriteMacros();
WriteHighLevelDirectives();
- GhsMultiGpj::WriteGpjTag(GhsMultiGpj::Types::PROJECT, GetBuildFileStream());
+ GhsMultiGpj::WriteGpjTag(GhsMultiGpj::PROJECT, GetBuildFileStream());
WriteDisclaimer(GetBuildFileStream());
*GetBuildFileStream() << "# Top Level Project File" << std::endl;
if (fBspName.length() > 0) {
@@ -427,7 +427,7 @@ void cmGlobalGhsMultiGenerator::UpdateBuildFiles(
TargetFolderBuildStreams.find(folderName)) {
AddFilesUpToPath(GetBuildFileStream(), &TargetFolderBuildStreams,
this->GetCMakeInstance()->GetHomeOutputDirectory(),
- folderName, GhsMultiGpj::Types::PROJECT);
+ folderName, GhsMultiGpj::PROJECT);
}
std::vector<cmsys::String> splitPath =
cmSystemTools::SplitString(gmtg.GetRelBuildFileName());
-----------------------------------------------------------------------
Summary of changes:
Source/cmGhsMultiTargetGenerator.cxx | 32 ++++++++++++++++----------------
Source/cmGlobalGhsMultiGenerator.cxx | 10 +++++-----
Source/cmLocalGhsMultiGenerator.cxx | 2 +-
3 files changed, 22 insertions(+), 22 deletions(-)
hooks/post-receive
--
CMake
More information about the Cmake-commits
mailing list