summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorPeter Kuemmel <syntheticpp@gmx.net>2012-08-14 13:48:45 (GMT)
committerBrad King <brad.king@kitware.com>2012-09-19 15:40:47 (GMT)
commit5598d9b2a06d4ec788b5e058435bb3bba99fd517 (patch)
tree6c832f3b905776fbce364bd243a24fcd655a0114 /Source
parent047749bfe8ff32158f1447ebd2e3a2eee64ad339 (diff)
downloadCMake-5598d9b2a06d4ec788b5e058435bb3bba99fd517.zip
CMake-5598d9b2a06d4ec788b5e058435bb3bba99fd517.tar.gz
CMake-5598d9b2a06d4ec788b5e058435bb3bba99fd517.tar.bz2
Ninja: don't expand any rsp files
Diffstat (limited to 'Source')
-rw-r--r--Source/cmake.cxx22
-rw-r--r--Source/cmake.h3
2 files changed, 17 insertions, 8 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx
index c6787b9..14f1566 100644
--- a/Source/cmake.cxx
+++ b/Source/cmake.cxx
@@ -1682,11 +1682,19 @@ int cmake::ExecuteCMakeCommand(std::vector<std::string>& args)
}
else if (args[1] == "vs_link_exe")
{
- return cmake::VisualStudioLink(args, 1);
+ return cmake::VisualStudioLink(args, 1, false);
}
else if (args[1] == "vs_link_dll")
{
- return cmake::VisualStudioLink(args, 2);
+ return cmake::VisualStudioLink(args, 2, false);
+ }
+ else if (args[1] == "vs_link_exe_no_rsp_expand")
+ {
+ return cmake::VisualStudioLink(args, 1, true);
+ }
+ else if (args[1] == "vs_link_dll_no_rsp_expand")
+ {
+ return cmake::VisualStudioLink(args, 2, true);
}
#ifdef CMAKE_BUILD_WITH_CMAKE
// Internal CMake color makefile support.
@@ -4009,7 +4017,8 @@ static bool cmakeCheckStampList(const char* stampList)
// For visual studio 2005 and newer manifest files need to be embeded into
// exe and dll's. This code does that in such a way that incremental linking
// still works.
-int cmake::VisualStudioLink(std::vector<std::string>& args, int type)
+int cmake::VisualStudioLink(std::vector<std::string>& args, int type,
+ bool no_rsp_expand)
{
if(args.size() < 2)
{
@@ -4024,13 +4033,12 @@ int cmake::VisualStudioLink(std::vector<std::string>& args, int type)
for(std::vector<std::string>::iterator i = args.begin();
i != args.end(); ++i)
{
- // check for nmake temporary files
- if((*i)[0] == '@' && i->find("@CMakeFiles") != 0 )
+ // check for nmake temporary files (there are two rsp files)
+ if(!no_rsp_expand && (*i)[0] == '@' && i->find("@CMakeFiles") != 0 )
{
std::ifstream fin(i->substr(1).c_str());
std::string line;
- while(cmSystemTools::GetLineFromStream(fin,
- line))
+ while(cmSystemTools::GetLineFromStream(fin, line))
{
cmSystemTools::ParseWindowsCommandLine(line.c_str(), expandedArgs);
}
diff --git a/Source/cmake.h b/Source/cmake.h
index 94c6f12..12e5edf 100644
--- a/Source/cmake.h
+++ b/Source/cmake.h
@@ -447,7 +447,8 @@ protected:
std::string const& link);
static int ExecuteEchoColor(std::vector<std::string>& args);
static int ExecuteLinkScript(std::vector<std::string>& args);
- static int VisualStudioLink(std::vector<std::string>& args, int type);
+ static int VisualStudioLink(std::vector<std::string>& args, int type,
+ bool no_rsp_expand);
static int VisualStudioLinkIncremental(std::vector<std::string>& args,
int type,
bool verbose);