summaryrefslogtreecommitdiffstats
path: root/Source/cmNinjaNormalTargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-03-12 14:42:38 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-03-12 14:42:38 (GMT)
commitcb8f87f6229359790956a6640639bbe6b8c346f7 (patch)
tree3501cbf4a528b475b8da15b88e0b14879bddd4c2 /Source/cmNinjaNormalTargetGenerator.cxx
parent9defc45f78d4fe10928fd0a94ffa97fc80f5da56 (diff)
parent3be265b304da0879c79e2fcdfff6f25b1a4e87c1 (diff)
downloadCMake-cb8f87f6229359790956a6640639bbe6b8c346f7.zip
CMake-cb8f87f6229359790956a6640639bbe6b8c346f7.tar.gz
CMake-cb8f87f6229359790956a6640639bbe6b8c346f7.tar.bz2
Merge topic 'remove-c_str-calls'
3be265b3 Workaround Sun C++ 5.9 compiler crash af8a1643 Remove c_str calls when using stream APIs. 21c573f6 Remove some c_str() calls.
Diffstat (limited to 'Source/cmNinjaNormalTargetGenerator.cxx')
-rw-r--r--Source/cmNinjaNormalTargetGenerator.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx
index c24c5e0..34b2e63 100644
--- a/Source/cmNinjaNormalTargetGenerator.cxx
+++ b/Source/cmNinjaNormalTargetGenerator.cxx
@@ -175,7 +175,7 @@ cmNinjaNormalTargetGenerator
// build response file name
std::string cmakeLinkVar = cmakeVarLang + "_RESPONSE_FILE_LINK_FLAG";
- const char * flag = GetMakefile()->GetDefinition(cmakeLinkVar.c_str());
+ const char * flag = GetMakefile()->GetDefinition(cmakeLinkVar);
if(flag) {
responseFlag = flag;
} else {
@@ -189,7 +189,7 @@ cmNinjaNormalTargetGenerator
linkOptionVar += "_COMPILER_LINKER_OPTION_FLAG_";
linkOptionVar += cmTarget::GetTargetTypeName(targetType);
const std::string linkOption =
- GetMakefile()->GetSafeDefinition(linkOptionVar.c_str());
+ GetMakefile()->GetSafeDefinition(linkOptionVar);
rspcontent = "$in_newline "+linkOption+" $LINK_PATH $LINK_LIBRARIES";
vars.Objects = responseFlag.c_str();
vars.LinkLibraries = "";
@@ -321,7 +321,7 @@ cmNinjaNormalTargetGenerator
linkCmdVar += this->TargetLinkLanguage;
linkCmdVar += "_CREATE_STATIC_LIBRARY";
if (const char *linkCmd =
- this->GetMakefile()->GetDefinition(linkCmdVar.c_str()))
+ this->GetMakefile()->GetDefinition(linkCmdVar))
{
cmSystemTools::ExpandListArgument(linkCmd, linkCmds);
return linkCmds;
@@ -341,7 +341,7 @@ cmNinjaNormalTargetGenerator
linkCmdVar += this->TargetLinkLanguage;
linkCmdVar += "_ARCHIVE_CREATE";
const char *linkCmd =
- this->GetMakefile()->GetRequiredDefinition(linkCmdVar.c_str());
+ this->GetMakefile()->GetRequiredDefinition(linkCmdVar);
cmSystemTools::ExpandListArgument(linkCmd, linkCmds);
}
{
@@ -349,7 +349,7 @@ cmNinjaNormalTargetGenerator
linkCmdVar += this->TargetLinkLanguage;
linkCmdVar += "_ARCHIVE_FINISH";
const char *linkCmd =
- this->GetMakefile()->GetRequiredDefinition(linkCmdVar.c_str());
+ this->GetMakefile()->GetRequiredDefinition(linkCmdVar);
cmSystemTools::ExpandListArgument(linkCmd, linkCmds);
}
return linkCmds;
@@ -374,7 +374,7 @@ cmNinjaNormalTargetGenerator
}
const char *linkCmd =
- this->GetMakefile()->GetRequiredDefinition(linkCmdVar.c_str());
+ this->GetMakefile()->GetRequiredDefinition(linkCmdVar);
cmSystemTools::ExpandListArgument(linkCmd, linkCmds);
return linkCmds;
}
@@ -497,7 +497,7 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement()
if (!install_name_dir.empty()) {
vars["INSTALLNAME_DIR"] =
- this->GetLocalGenerator()->Convert(install_name_dir.c_str(),
+ this->GetLocalGenerator()->Convert(install_name_dir,
cmLocalGenerator::NONE,
cmLocalGenerator::SHELL, false);
}
@@ -506,7 +506,7 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement()
if (!this->TargetNameImport.empty()) {
const std::string impLibPath = this->GetLocalGenerator()
- ->ConvertToOutputFormat(targetOutputImplib.c_str(),
+ ->ConvertToOutputFormat(targetOutputImplib,
cmLocalGenerator::SHELL);
vars["TARGET_IMPLIB"] = impLibPath;
EnsureParentDirectoryExists(impLibPath);