summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-05-23 12:53:24 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-05-23 12:55:16 (GMT)
commit79c6a573f4c6690914511e4e1894221a94f1b3e3 (patch)
tree519c0af1d2b0936ab223255d7d8a976eadcec23e /Source
parentd1a570f18c47bb840fc19a9979d3970fbaa7e58a (diff)
parent02c14b7fcd29a7dcedb930fe5d9138cb185493e1 (diff)
downloadCMake-79c6a573f4c6690914511e4e1894221a94f1b3e3.zip
CMake-79c6a573f4c6690914511e4e1894221a94f1b3e3.tar.gz
CMake-79c6a573f4c6690914511e4e1894221a94f1b3e3.tar.bz2
Merge topic 'swift-flags'
02c14b7fcd Ninja,Swift: pass along DEFINES/FLAGS/INCLUDES Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3355
Diffstat (limited to 'Source')
-rw-r--r--Source/cmNinjaNormalTargetGenerator.cxx11
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx
index 1221a3f..1e4d2ed 100644
--- a/Source/cmNinjaNormalTargetGenerator.cxx
+++ b/Source/cmNinjaNormalTargetGenerator.cxx
@@ -289,6 +289,10 @@ void cmNinjaNormalTargetGenerator::WriteLinkRule(bool useResponseFile)
vars.SwiftModuleName = "$SWIFT_MODULE_NAME";
vars.SwiftOutputFileMap = "$SWIFT_OUTPUT_FILE_MAP";
vars.SwiftSources = "$SWIFT_SOURCES";
+
+ vars.Defines = "$DEFINES";
+ vars.Flags = "$FLAGS";
+ vars.Includes = "$INCLUDES";
}
std::string responseFlag;
@@ -840,6 +844,13 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement()
}
return oss.str();
}();
+
+ // Since we do not perform object builds, compute the
+ // defines/flags/includes here so that they can be passed along
+ // appropriately.
+ vars["DEFINES"] = this->GetDefines("Swift");
+ vars["FLAGS"] = this->GetFlags("Swift");
+ vars["INCLUDES"] = this->GetIncludes("Swift");
}
// Compute specific libraries to link with.