summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorAndy Cedilnik <andy.cedilnik@kitware.com>2002-04-18 19:58:35 (GMT)
committerAndy Cedilnik <andy.cedilnik@kitware.com>2002-04-18 19:58:35 (GMT)
commitaa0ac1642be0ac93da35598728057b53df3c0c56 (patch)
treeceee4da71baf638a500e5ceae0c2b930396728b5 /Source
parent555a7f88aad91cf57599e0520b53a54f288e4afd (diff)
downloadCMake-aa0ac1642be0ac93da35598728057b53df3c0c56.zip
CMake-aa0ac1642be0ac93da35598728057b53df3c0c56.tar.gz
CMake-aa0ac1642be0ac93da35598728057b53df3c0c56.tar.bz2
Make quotes and echos to work on unix (hopefully)
Diffstat (limited to 'Source')
-rw-r--r--Source/cmUnixMakefileGenerator.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/cmUnixMakefileGenerator.cxx b/Source/cmUnixMakefileGenerator.cxx
index 301d945..c41af24 100644
--- a/Source/cmUnixMakefileGenerator.cxx
+++ b/Source/cmUnixMakefileGenerator.cxx
@@ -2082,15 +2082,18 @@ void cmUnixMakefileGenerator::OutputMakeRule(std::ostream& fout,
&& replace.find("$(MAKE)") != 0)
{
std::string echostring = replace;
- cmSystemTools::ReplaceString(echostring, "\n\t", "\n\techo ");
// for unix we want to quote the output of echo
// for nmake and borland, the echo should not be quoted
if(strcmp(this->GetName(), "Unix Makefiles") == 0)
{
+ cmSystemTools::ReplaceString(echostring, "\\\n", " ");
+ cmSystemTools::ReplaceString(echostring, " \t", " ");
+ cmSystemTools::ReplaceString(echostring, "\n\t", "\"\n\techo \"");
fout << "\techo \"" << echostring.c_str() << "\"\n";
}
else
{
+ cmSystemTools::ReplaceString(echostring, "\n\t", "\n\techo ");
fout << "\techo " << echostring.c_str() << "\n";
}
}