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

Unified Diff: build/toolchain/nacl/BUILD.gn

Issue 1432603003: GN: Avoid nontrivial shell commands in gcc_toolchain tool("link") (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gn set-but-unused nit Created 5 years, 1 month 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 | « build/toolchain/gcc_toolchain.gni ('k') | build/toolchain/nacl_toolchain.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/toolchain/nacl/BUILD.gn
diff --git a/build/toolchain/nacl/BUILD.gn b/build/toolchain/nacl/BUILD.gn
index bf31e846a97452b0558d00fc7fcd5f317460f1c4..23f1027fbb4acc8290661bd946291987b2fb3a6a 100644
--- a/build/toolchain/nacl/BUILD.gn
+++ b/build/toolchain/nacl/BUILD.gn
@@ -32,19 +32,22 @@ nacl_toolchain("newlib_pnacl") {
rebase_path("${nacl_toolchain_dir}/${toolchain_package}/bin/pnacl-",
root_build_dir)
+ executable_extension = ".pexe"
+
is_clang = true
cc = toolprefix + "clang"
cxx = toolprefix + "clang++"
ar = toolprefix + "ar"
ld = cxx
- executable_extension = ".pexe.debug"
-
- finalize = toolprefix + "finalize"
- nonfinal_file =
- "{{root_out_dir}}/{{target_output_name}}${executable_extension}"
- finalized_file = "{{root_out_dir}}/{{target_output_name}}.pexe"
- postlink = "$finalize $nonfinal_file -o $finalized_file"
- link_outputs = [ finalized_file ]
+
+ # The pnacl-finalize tool turns a .pexe.debug file into a .pexe file.
+ # It's very similar in purpose to the traditional "strip" utility: it
+ # turns what comes out of the linker into what you actually want to
+ # distribute and run. PNaCl doesn't have a "strip"-like utility that
+ # you ever actually want to use other than pnacl-finalize, so just
+ # make pnacl-finalize the strip tool rather than adding an additional
+ # step like "postlink" to run pnacl-finalize.
+ strip = toolprefix + "finalize"
}
nacl_toolchain("newlib_pnacl_nonsfi") {
« no previous file with comments | « build/toolchain/gcc_toolchain.gni ('k') | build/toolchain/nacl_toolchain.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698