summaryrefslogtreecommitdiffstats
path: root/Source/cmLocalUnixMakefileGenerator3.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmLocalUnixMakefileGenerator3.cxx')
-rw-r--r--Source/cmLocalUnixMakefileGenerator3.cxx30
1 files changed, 27 insertions, 3 deletions
diff --git a/Source/cmLocalUnixMakefileGenerator3.cxx b/Source/cmLocalUnixMakefileGenerator3.cxx
index 8fa14d2..ff173f5 100644
--- a/Source/cmLocalUnixMakefileGenerator3.cxx
+++ b/Source/cmLocalUnixMakefileGenerator3.cxx
@@ -2181,14 +2181,27 @@ cmLocalUnixMakefileGenerator3
//----------------------------------------------------------------------------
std::string
-cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p)
+cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p,
+ bool useWatcomQuote)
{
// Split the path into its components.
std::vector<std::string> components;
cmSystemTools::SplitPath(p, components);
// Open the quoted result.
- std::string result = "\"";
+ std::string result;
+ if(useWatcomQuote)
+ {
+#if defined(_WIN32) && !defined(__CYGWIN__)
+ result = "'";
+#else
+ result = "\"'";
+#endif
+ }
+ else
+ {
+ result = "\"";
+ }
// Return an empty path if there are no components.
if(!components.empty())
@@ -2232,7 +2245,18 @@ cmLocalUnixMakefileGenerator3::ConvertToQuotedOutputPath(const char* p)
}
// Close the quoted result.
- result += "\"";
+ if(useWatcomQuote)
+ {
+#if defined(_WIN32) && !defined(__CYGWIN__)
+ result += "'";
+#else
+ result += "'\"";
+#endif
+ }
+ else
+ {
+ result += "\"";
+ }
return result;
}