summaryrefslogtreecommitdiffstats
path: root/Source/cmRulePlaceholderExpander.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2019-05-20 14:55:11 (GMT)
committerKitware Robot <kwrobot@kitware.com>2019-05-20 14:55:27 (GMT)
commita9fb9a8774a7b1dd411542d1d14fb537968e32f1 (patch)
tree2d74dc351b298a5317d05634170c91a8b43bc07e /Source/cmRulePlaceholderExpander.cxx
parent28ee31149030c75c32ebbf134502a9d020dbd54b (diff)
parenta9180ccf9a9e845658ba455e2dbc2447b18d2654 (diff)
downloadCMake-a9fb9a8774a7b1dd411542d1d14fb537968e32f1.zip
CMake-a9fb9a8774a7b1dd411542d1d14fb537968e32f1.tar.gz
CMake-a9fb9a8774a7b1dd411542d1d14fb537968e32f1.tar.bz2
Merge topic 'ninja-swift'
a9180ccf9a Tests: add a check for the Swift compiler d745551fb6 Help: add some initial documentation for Swift support 9a182c9e5b Auxiliary: update vim syntax highlighting e9b0063e8e Modules: add build rules for Swift Ninja support b6412e3e38 Ninja: add placeholders to support Swift build 7d7f31161d Ninja: add support for Swift's output-file-map.json d688c4c19d Swift: remove unnecessary unreleased Ninja infrastructure 0723582208 Swift: Detect compiler version ... Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !3297
Diffstat (limited to 'Source/cmRulePlaceholderExpander.cxx')
-rw-r--r--Source/cmRulePlaceholderExpander.cxx65
1 files changed, 25 insertions, 40 deletions
diff --git a/Source/cmRulePlaceholderExpander.cxx b/Source/cmRulePlaceholderExpander.cxx
index 309ee30..33389ca 100644
--- a/Source/cmRulePlaceholderExpander.cxx
+++ b/Source/cmRulePlaceholderExpander.cxx
@@ -91,6 +91,31 @@ std::string cmRulePlaceholderExpander::ExpandRuleVariable(
if (replaceValues.Includes && variable == "INCLUDES") {
return replaceValues.Includes;
}
+ if (replaceValues.SwiftLibraryName) {
+ if (variable == "SWIFT_LIBRARY_NAME") {
+ return replaceValues.SwiftLibraryName;
+ }
+ }
+ if (replaceValues.SwiftModule) {
+ if (variable == "SWIFT_MODULE") {
+ return replaceValues.SwiftModule;
+ }
+ }
+ if (replaceValues.SwiftModuleName) {
+ if (variable == "SWIFT_MODULE_NAME") {
+ return replaceValues.SwiftModuleName;
+ }
+ }
+ if (replaceValues.SwiftOutputFileMap) {
+ if (variable == "SWIFT_OUTPUT_FILE_MAP") {
+ return replaceValues.SwiftOutputFileMap;
+ }
+ }
+ if (replaceValues.SwiftSources) {
+ if (variable == "SWIFT_SOURCES") {
+ return replaceValues.SwiftSources;
+ }
+ }
if (replaceValues.TargetPDB) {
if (variable == "TARGET_PDB") {
return replaceValues.TargetPDB;
@@ -162,46 +187,6 @@ std::string cmRulePlaceholderExpander::ExpandRuleVariable(
}
}
}
- if (replaceValues.SwiftAuxiliarySources) {
- if (variable == "SWIFT_AUXILIARY_SOURCES") {
- return replaceValues.SwiftAuxiliarySources;
- }
- }
- if (replaceValues.SwiftModuleName) {
- if (variable == "SWIFT_MODULE_NAME") {
- return replaceValues.SwiftModuleName;
- }
- }
- if (replaceValues.SwiftLibraryName) {
- if (variable == "SWIFT_LIBRARY_NAME") {
- return replaceValues.SwiftLibraryName;
- }
- }
- if (replaceValues.SwiftPartialDoc) {
- if (variable == "SWIFT_PARTIAL_DOC") {
- return replaceValues.SwiftPartialDoc;
- }
- }
- if (replaceValues.SwiftPartialModule) {
- if (variable == "SWIFT_PARTIAL_MODULE") {
- return replaceValues.SwiftPartialModule;
- }
- }
- if (replaceValues.SwiftPartialModules) {
- if (variable == "SWIFT_PARTIAL_MODULES") {
- return replaceValues.SwiftPartialModules;
- }
- }
- if (replaceValues.TargetSwiftDoc) {
- if (variable == "TARGET_SWIFT_DOC") {
- return replaceValues.TargetSwiftDoc;
- }
- }
- if (replaceValues.TargetSwiftModule) {
- if (variable == "TARGET_SWIFT_MODULE") {
- return replaceValues.TargetSwiftModule;
- }
- }
if (variable == "TARGET_SONAME" || variable == "SONAME_FLAG" ||
variable == "TARGET_INSTALLNAME_DIR") {
// All these variables depend on TargetSOName