summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorDavid Cole <david.cole@kitware.com>2012-06-14 17:39:39 (GMT)
committerDavid Cole <david.cole@kitware.com>2012-06-14 17:39:39 (GMT)
commit555bda4e436435c37690aa5f31f4d254793d5b4e (patch)
tree7d71558e604fc0e198b50dbfff225caba97bf005 /Source
parent69bc5131b2e5590e94048933b37019c0773a0cf7 (diff)
downloadCMake-555bda4e436435c37690aa5f31f4d254793d5b4e.zip
CMake-555bda4e436435c37690aa5f31f4d254793d5b4e.tar.gz
CMake-555bda4e436435c37690aa5f31f4d254793d5b4e.tar.bz2
Ninja: Restructure code to work with the Borland compilers
Should fix the Borland dashboard errors.
Diffstat (limited to 'Source')
-rw-r--r--Source/cmNinjaNormalTargetGenerator.cxx10
1 files changed, 8 insertions, 2 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx
index 22f77f0..2dcfcb3 100644
--- a/Source/cmNinjaNormalTargetGenerator.cxx
+++ b/Source/cmNinjaNormalTargetGenerator.cxx
@@ -391,12 +391,18 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement()
// Compute architecture specific link flags. Yes, these go into a different
// variable for executables, probably due to a mistake made when duplicating
// code between the Makefile executable and library generators.
- locGtor->AddArchitectureFlags(targetType == cmTarget::EXECUTABLE
+ std::string flags = (targetType == cmTarget::EXECUTABLE
? vars["FLAGS"]
- : vars["ARCH_FLAGS"],
+ : vars["ARCH_FLAGS"]);
+ locGtor->AddArchitectureFlags(flags,
this->GetTarget(),
this->TargetLinkLanguage,
this->GetConfigName());
+ if (targetType == cmTarget::EXECUTABLE) {
+ vars["FLAGS"] = flags;
+ } else {
+ vars["ARCH_FLAGS"] = flags;
+ }
if (this->GetTarget()->HasSOName(this->GetConfigName())) {
vars["SONAME_FLAG"] =
this->GetMakefile()->GetSONameFlag(this->TargetLinkLanguage);