cmLocalGenerator: Add Home directory accessors.

Reduce reasons for cmLocalGenerator to have a cmMakefile.
This commit is contained in:
Stephen Kelly
2015-10-07 01:17:48 +02:00
parent 72efa15dc2
commit 12cb3bdce4
23 changed files with 94 additions and 82 deletions

View File

@@ -68,7 +68,9 @@ cmGhsMultiTargetGenerator::GetRelBuildFilePath(const cmTarget *target)
std::string
cmGhsMultiTargetGenerator::GetAbsPathToRoot(const cmTarget *target)
{
return target->GetMakefile()->GetHomeOutputDirectory();
cmGeneratorTarget* gt = target->GetMakefile()->GetGlobalGenerator()
->GetGeneratorTarget(target);
return gt->GetLocalGenerator()->GetBinaryDirectory();
}
std::string
@@ -450,7 +452,7 @@ void cmGhsMultiTargetGenerator::WriteSources(
cmSystemTools::ConvertToUnixSlashes(sgPath);
cmGlobalGhsMultiGenerator::AddFilesUpToPath(
this->GetFolderBuildStreams(), &this->FolderBuildStreams,
this->Makefile->GetHomeOutputDirectory(), sgPath,
this->LocalGenerator->GetBinaryDirectory(), sgPath,
GhsMultiGpj::SUBPROJECT, this->RelBuildFilePath);
std::string fullSourcePath((*si)->GetFullPath());