|
@@ -275,6 +275,9 @@ std::string cmOutputConverter::EscapeForShell(cm::string_view str,
|
|
|
if (this->GetState()->UseNMake()) {
|
|
if (this->GetState()->UseNMake()) {
|
|
|
flags |= Shell_Flag_NMake;
|
|
flags |= Shell_Flag_NMake;
|
|
|
}
|
|
}
|
|
|
|
|
+ if (this->GetState()->UseNinja()) {
|
|
|
|
|
+ flags |= Shell_Flag_Ninja;
|
|
|
|
|
+ }
|
|
|
if (!this->GetState()->UseWindowsShell()) {
|
|
if (!this->GetState()->UseWindowsShell()) {
|
|
|
flags |= Shell_Flag_IsUnix;
|
|
flags |= Shell_Flag_IsUnix;
|
|
|
}
|
|
}
|
|
@@ -677,6 +680,12 @@ std::string cmOutputConverter::Shell_GetArgument(cm::string_view in, int flags)
|
|
|
/* Otherwise a semicolon is written just ;. */
|
|
/* Otherwise a semicolon is written just ;. */
|
|
|
out += ';';
|
|
out += ';';
|
|
|
}
|
|
}
|
|
|
|
|
+ } else if (*cit == '\n') {
|
|
|
|
|
+ if (flags & Shell_Flag_Ninja) {
|
|
|
|
|
+ out += "$\n";
|
|
|
|
|
+ } else {
|
|
|
|
|
+ out += '\n';
|
|
|
|
|
+ }
|
|
|
} else {
|
|
} else {
|
|
|
/* Store this character. */
|
|
/* Store this character. */
|
|
|
out += *cit;
|
|
out += *cit;
|