Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Unified Diff: tools/gn/ninja_toolchain_writer.cc

Issue 2006923004: Add support for user defined "pool" to GN. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/gn/ninja_toolchain_writer.cc
diff --git a/tools/gn/ninja_toolchain_writer.cc b/tools/gn/ninja_toolchain_writer.cc
index e7459ebb3cfa2ede1e0d5303aedfdf0b36e134b2..1deff58eb2c28cb7efcd576f2c304c757038a6b5 100644
--- a/tools/gn/ninja_toolchain_writer.cc
+++ b/tools/gn/ninja_toolchain_writer.cc
@@ -11,6 +11,7 @@
#include "tools/gn/build_settings.h"
#include "tools/gn/filesystem_utils.h"
#include "tools/gn/ninja_utils.h"
+#include "tools/gn/pool.h"
#include "tools/gn/settings.h"
#include "tools/gn/substitution_writer.h"
#include "tools/gn/target.h"
@@ -113,6 +114,10 @@ void NinjaToolchainWriter::WriteToolRule(const Toolchain::ToolType type,
type == Toolchain::TYPE_SOLINK_MODULE ||
type == Toolchain::TYPE_LINK) {
out_ << kIndent << "pool = link_pool\n";
+ } else if (tool->pool().ptr) {
+ std::string pool_name =
+ tool->pool().ptr->GetNinjaName(settings_->default_toolchain_label());
+ out_ << kIndent << "pool = " << pool_name << std::endl;
}
if (tool->restat())

Powered by Google App Engine
This is Rietveld 408576698