summaryrefslogtreecommitdiffstats
path: root/Source/cmNinjaTargetGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmNinjaTargetGenerator.cxx')
-rw-r--r--Source/cmNinjaTargetGenerator.cxx19
1 files changed, 5 insertions, 14 deletions
diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx
index 8eb9dbd..2bc5765 100644
--- a/Source/cmNinjaTargetGenerator.cxx
+++ b/Source/cmNinjaTargetGenerator.cxx
@@ -886,19 +886,12 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatements()
std::string const& language = langDDIFiles.first;
cmNinjaDeps const& ddiFiles = langDDIFiles.second;
- std::string const ddComment;
- std::string const ddRule = this->LanguageDyndepRule(language);
- cmNinjaDeps ddOutputs;
- cmNinjaDeps ddImplicitOuts;
- cmNinjaDeps const& ddExplicitDeps = ddiFiles;
- cmNinjaDeps ddImplicitDeps;
- cmNinjaDeps ddOrderOnlyDeps;
- cmNinjaVars ddVars;
+ cmNinjaBuild build(this->LanguageDyndepRule(language));
+ build.Outputs.push_back(this->GetDyndepFilePath(language));
+ build.ExplicitDeps = ddiFiles;
this->WriteTargetDependInfo(language);
- ddOutputs.push_back(this->GetDyndepFilePath(language));
-
// Make sure dyndep files for all our dependencies have already
// been generated so that the '<LANG>Modules.json' files they
// produced as side-effects are available for us to read.
@@ -908,11 +901,9 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatements()
// refactoring the Ninja generator to generate targets in
// dependency order so that we can collect the needed information.
this->GetLocalGenerator()->AppendTargetDepends(
- this->GeneratorTarget, ddOrderOnlyDeps, DependOnTargetArtifact);
+ this->GeneratorTarget, build.OrderOnlyDeps, DependOnTargetArtifact);
- this->GetGlobalGenerator()->WriteBuild(
- this->GetBuildFileStream(), ddComment, ddRule, ddOutputs, ddImplicitOuts,
- ddExplicitDeps, ddImplicitDeps, ddOrderOnlyDeps, ddVars);
+ this->GetGlobalGenerator()->WriteBuild(this->GetBuildFileStream(), build);
}
this->GetBuildFileStream() << "\n";