summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileTargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-01-25 13:36:21 (GMT)
committerKitware Robot <kwrobot@kitware.com>2018-01-25 13:36:47 (GMT)
commitd1d8daf15adfc6fc23cabbf37e230d0445b70405 (patch)
treecdfd36e55ab7fceb17ad5887af61fea9befb18cb /Source/cmMakefileTargetGenerator.cxx
parent499e36d932910186e1c1db1cc0d18fe93e47ee55 (diff)
parentc4dc6485eb3bd51fdc88eee03218b9755c373282 (diff)
downloadCMake-d1d8daf15adfc6fc23cabbf37e230d0445b70405.zip
CMake-d1d8daf15adfc6fc23cabbf37e230d0445b70405.tar.gz
CMake-d1d8daf15adfc6fc23cabbf37e230d0445b70405.tar.bz2
Merge topic 'xl-qoptfile'
c4dc6485 XL: Enable use of response files for includes and objects e342e410 Makefile,Ninja: Use tool-specific response file flag for include dirs Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !1691
Diffstat (limited to 'Source/cmMakefileTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileTargetGenerator.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/Source/cmMakefileTargetGenerator.cxx b/Source/cmMakefileTargetGenerator.cxx
index 1543536..5d80e77 100644
--- a/Source/cmMakefileTargetGenerator.cxx
+++ b/Source/cmMakefileTargetGenerator.cxx
@@ -1653,10 +1653,17 @@ void cmMakefileTargetGenerator::AddIncludeFlags(std::string& flags,
}
if (useResponseFile) {
+ std::string const responseFlagVar =
+ "CMAKE_" + lang + "_RESPONSE_FILE_FLAG";
+ std::string responseFlag =
+ this->Makefile->GetSafeDefinition(responseFlagVar);
+ if (responseFlag.empty()) {
+ responseFlag = "@";
+ }
std::string name = "includes_";
name += lang;
name += ".rsp";
- std::string arg = "@" +
+ std::string arg = std::move(responseFlag) +
this->CreateResponseFile(name.c_str(), includeFlags,
this->FlagFileDepends[lang]);
this->LocalGenerator->AppendFlags(flags, arg);