diff options
Diffstat (limited to 'Source/cmSystemTools.cxx')
-rw-r--r-- | Source/cmSystemTools.cxx | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx index 69ce0af..9574624 100644 --- a/Source/cmSystemTools.cxx +++ b/Source/cmSystemTools.cxx @@ -48,6 +48,7 @@ bool cmSystemTools::s_DisableRunCommandOutput = false; bool cmSystemTools::s_ErrorOccured = false; bool cmSystemTools::s_FatalErrorOccured = false; bool cmSystemTools::s_DisableMessages = false; +bool cmSystemTools::s_ForceUnixPaths = false; std::string cmSystemTools::s_Windows9xComspecSubstitute = "command.com"; void cmSystemTools::SetWindows9xComspecSubstitute(const char* str) @@ -1032,3 +1033,17 @@ bool cmSystemTools::Split(const char* s, std::vector<cmStdString>& l) } return true; } + +std::string cmSystemTools::ConvertToOutputPath(const char* path) +{ +#if defined(_WIN32) && !defined(__CYGWIN__) + if(s_ForceUnixPaths) + { + return cmSystemTools::ConvertToUnixOutputPath(path); + } + return cmSystemTools::ConvertToWindowsOutputPath(path); +#else + return cmSystemTools::ConvertToUnixOutputPath(path); +#endif +} + |