Merge topic 'ctest-subdir-spaces'
1f8613e9
Fix CTest test file generation for spaces in subdirectory names385e6a27
cmLocalGenerator: Refactor test subdirectory generation loop
This commit is contained in:
commit
35e3836589
|
@ -175,15 +175,14 @@ void cmLocalGenerator::GenerateTestFiles()
|
||||||
(*gi)->Compute(this);
|
(*gi)->Compute(this);
|
||||||
(*gi)->Generate(fout, config, configurationTypes);
|
(*gi)->Generate(fout, config, configurationTypes);
|
||||||
}
|
}
|
||||||
size_t i;
|
typedef std::vector<cmState::Snapshot> vec_t;
|
||||||
std::vector<cmState::Snapshot> children =
|
vec_t const& children = this->Makefile->GetStateSnapshot().GetChildren();
|
||||||
this->Makefile->GetStateSnapshot().GetChildren();
|
for (vec_t::const_iterator i = children.begin(); i != children.end(); ++i) {
|
||||||
for (i = 0; i < children.size(); ++i) {
|
|
||||||
// TODO: Use add_subdirectory instead?
|
// TODO: Use add_subdirectory instead?
|
||||||
fout << "subdirs(";
|
std::string outP = i->GetDirectory().GetCurrentBinary();
|
||||||
std::string outP = children[i].GetDirectory().GetCurrentBinary();
|
outP = this->ConvertToRelativePath(outP, START_OUTPUT);
|
||||||
fout << this->ConvertToRelativePath(outP, START_OUTPUT);
|
outP = cmOutputConverter::EscapeForCMake(outP);
|
||||||
fout << ")" << std::endl;
|
fout << "subdirs(" << outP << ")" << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue