summaryrefslogtreecommitdiffstats
path: root/Source/cmNinjaNormalTargetGenerator.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2014-02-04 02:20:56 (GMT)
committerBrad King <brad.king@kitware.com>2014-03-08 18:05:30 (GMT)
commitce5114354c357df973e54872ab7abebbff36793b (patch)
tree472c096db98ba5b36c7c32910a334a044ecafd80 /Source/cmNinjaNormalTargetGenerator.cxx
parent83a5e453f8c0dc0fc9b6bdee9723478aafefd0da (diff)
downloadCMake-ce5114354c357df973e54872ab7abebbff36793b.zip
CMake-ce5114354c357df973e54872ab7abebbff36793b.tar.gz
CMake-ce5114354c357df973e54872ab7abebbff36793b.tar.bz2
stringapi: Use strings for the languages
Diffstat (limited to 'Source/cmNinjaNormalTargetGenerator.cxx')
-rw-r--r--Source/cmNinjaNormalTargetGenerator.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx
index 73ba815..b81fbeb 100644
--- a/Source/cmNinjaNormalTargetGenerator.cxx
+++ b/Source/cmNinjaNormalTargetGenerator.cxx
@@ -35,7 +35,7 @@ cmNinjaNormalTargetGenerator(cmGeneratorTarget* target)
, TargetNameReal()
, TargetNameImport()
, TargetNamePDB()
- , TargetLinkLanguage(0)
+ , TargetLinkLanguage("")
{
this->TargetLinkLanguage = target->Target
->GetLinkerLanguage(this->GetConfigName());
@@ -72,7 +72,7 @@ cmNinjaNormalTargetGenerator::~cmNinjaNormalTargetGenerator()
void cmNinjaNormalTargetGenerator::Generate()
{
- if (!this->TargetLinkLanguage) {
+ if (this->TargetLinkLanguage.empty()) {
cmSystemTools::Error("CMake can not determine linker language for "
"target: ",
this->GetTarget()->GetName());
@@ -140,7 +140,7 @@ std::string
cmNinjaNormalTargetGenerator
::LanguageLinkerRule() const
{
- return std::string(this->TargetLinkLanguage)
+ return this->TargetLinkLanguage
+ "_"
+ cmTarget::GetTargetTypeName(this->GetTarget()->GetType())
+ "_LINKER";
@@ -163,7 +163,7 @@ cmNinjaNormalTargetGenerator
cmLocalGenerator::RuleVariables vars;
vars.RuleLauncher = "RULE_LAUNCH_LINK";
vars.CMTarget = this->GetTarget();
- vars.Language = this->TargetLinkLanguage;
+ vars.Language = this->TargetLinkLanguage.c_str();
std::string responseFlag;
if (!useResponseFile) {