-make paths with spaces work in the CodeBlocks generator with MinGW (#10014)
Alex
This commit is contained in:
parent
0999bd7fb8
commit
5f540dcbf3
|
@ -545,7 +545,6 @@ void cmExtraCodeBlocksGenerator::AppendTarget(cmGeneratedFileStream& fout,
|
||||||
{
|
{
|
||||||
std::string makefileName = makefile->GetStartOutputDirectory();
|
std::string makefileName = makefile->GetStartOutputDirectory();
|
||||||
makefileName += "/Makefile";
|
makefileName += "/Makefile";
|
||||||
makefileName = cmSystemTools::ConvertToOutputPath(makefileName.c_str());
|
|
||||||
|
|
||||||
fout<<" <Target title=\"" << targetName << "\">\n";
|
fout<<" <Target title=\"" << targetName << "\">\n";
|
||||||
if (target!=0)
|
if (target!=0)
|
||||||
|
@ -696,22 +695,27 @@ std::string cmExtraCodeBlocksGenerator::BuildMakeCommand(
|
||||||
std::string command = make;
|
std::string command = make;
|
||||||
if (strcmp(this->GlobalGenerator->GetName(), "NMake Makefiles")==0)
|
if (strcmp(this->GlobalGenerator->GetName(), "NMake Makefiles")==0)
|
||||||
{
|
{
|
||||||
|
std::string makefileName = cmSystemTools::ConvertToOutputPath(makefile);
|
||||||
command += " /NOLOGO /f "";
|
command += " /NOLOGO /f "";
|
||||||
command += makefile;
|
command += makefileName;
|
||||||
command += "" ";
|
command += "" ";
|
||||||
command += target;
|
command += target;
|
||||||
}
|
}
|
||||||
else if (strcmp(this->GlobalGenerator->GetName(), "MinGW Makefiles")==0)
|
else if (strcmp(this->GlobalGenerator->GetName(), "MinGW Makefiles")==0)
|
||||||
{
|
{
|
||||||
command += " -f ";
|
// no escaping of spaces in this case, see
|
||||||
command += makefile;
|
// http://public.kitware.com/Bug/view.php?id=10014
|
||||||
command += " ";
|
std::string makefileName = makefile;
|
||||||
|
command += " -f "";
|
||||||
|
command += makefileName;
|
||||||
|
command += "" ";
|
||||||
command += target;
|
command += target;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
std::string makefileName = cmSystemTools::ConvertToOutputPath(makefile);
|
||||||
command += " -f "";
|
command += " -f "";
|
||||||
command += makefile;
|
command += makefileName;
|
||||||
command += "" ";
|
command += "" ";
|
||||||
command += target;
|
command += target;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue