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

Unified Diff: tools/gn/ninja_binary_target_writer.cc

Issue 1904473002: Add arflags to GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 8 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
« no previous file with comments | « tools/gn/function_toolchain.cc ('k') | tools/gn/ninja_binary_target_writer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/gn/ninja_binary_target_writer.cc
diff --git a/tools/gn/ninja_binary_target_writer.cc b/tools/gn/ninja_binary_target_writer.cc
index 4a923c3bde018909c27a41ff26f9f5dd54679e82..cb486880fd521a4910d78bf29fde934038508644 100644
--- a/tools/gn/ninja_binary_target_writer.cc
+++ b/tools/gn/ninja_binary_target_writer.cc
@@ -785,6 +785,11 @@ void NinjaBinaryTargetWriter::WriteLinkerStuff(
target_->output_type() == Target::LOADABLE_MODULE) {
WriteLinkerFlags(optional_def_file);
WriteLibs();
+ } else if (target_->output_type() == Target::STATIC_LIBRARY) {
+ out_ << " arflags =";
+ RecursiveTargetConfigStringsToStream(target_, &ConfigValues::arflags,
+ GetFlagOptions(), out_);
+ out_ << std::endl;
}
WriteOutputSubstitutions();
WriteSolibs(solibs);
@@ -795,9 +800,8 @@ void NinjaBinaryTargetWriter::WriteLinkerFlags(
out_ << " ldflags =";
// First the ldflags from the target and its config.
- EscapeOptions flag_options = GetFlagOptions();
RecursiveTargetConfigStringsToStream(target_, &ConfigValues::ldflags,
- flag_options, out_);
+ GetFlagOptions(), out_);
// Followed by library search paths that have been recursively pushed
// through the dependency tree.
« no previous file with comments | « tools/gn/function_toolchain.cc ('k') | tools/gn/ninja_binary_target_writer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698