diff options
author | Sebastian Holtermann <sebholt@xwmw.org> | 2019-05-30 10:19:00 (GMT) |
---|---|---|
committer | Sebastian Holtermann <sebholt@xwmw.org> | 2019-05-30 16:21:40 (GMT) |
commit | 0eed548d3f0387a3bcbdc42ad4456987a37b2934 (patch) | |
tree | 7747e0738bb6adfdf603e713a9fc0455a88129cb /Source | |
parent | b6dc977ff17b451b43d8a67584400c3b53c7eb8f (diff) | |
download | CMake-0eed548d3f0387a3bcbdc42ad4456987a37b2934.zip CMake-0eed548d3f0387a3bcbdc42ad4456987a37b2934.tar.gz CMake-0eed548d3f0387a3bcbdc42ad4456987a37b2934.tar.bz2 |
Ninja: Use cmNinjaBuild instead of WritePhonyBuild
Diffstat (limited to 'Source')
-rw-r--r-- | Source/cmNinjaTargetGenerator.cxx | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx index 140730b..e878adb 100644 --- a/Source/cmNinjaTargetGenerator.cxx +++ b/Source/cmNinjaTargetGenerator.cxx @@ -829,7 +829,11 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatements() } { - cmNinjaDeps orderOnlyDeps; + cmNinjaBuild build("phony"); + build.Comment = "Order-only phony target for " + this->GetTargetName(); + build.Outputs.push_back(this->OrderDependsTargetForTarget()); + + cmNinjaDeps& orderOnlyDeps = build.OrderOnlyDeps; this->GetLocalGenerator()->AppendTargetDepends( this->GeneratorTarget, orderOnlyDeps, DependOnTargetOrdering); @@ -867,14 +871,7 @@ void cmNinjaTargetGenerator::WriteObjectBuildStatements() orderOnlyDeps.push_back(this->ConvertToNinjaPath(tgtDir)); } - { - cmNinjaDeps orderOnlyTarget; - orderOnlyTarget.push_back(this->OrderDependsTargetForTarget()); - this->GetGlobalGenerator()->WritePhonyBuild( - this->GetBuildFileStream(), - "Order-only phony target for " + this->GetTargetName(), - orderOnlyTarget, cmNinjaDeps(), cmNinjaDeps(), orderOnlyDeps); - } + this->GetGlobalGenerator()->WriteBuild(this->GetBuildFileStream(), build); } { |