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

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

Issue 485833003: Pull new GN, update toolchain definitions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix Android Created 6 years, 4 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: build/toolchain/android/BUILD.gn
diff --git a/build/toolchain/android/BUILD.gn b/build/toolchain/android/BUILD.gn
index c927b37f0c91c18bbcb085de77dd1d79533157ee..2d1b69a8667b92c2d0383b4aba415b09dccf0536 100644
--- a/build/toolchain/android/BUILD.gn
+++ b/build/toolchain/android/BUILD.gn
@@ -49,10 +49,17 @@ template("android_gcc_toolchain") {
toolchain_os = "android"
toolchain_cpu_arch = invoker.toolchain_cpu_arch
+ # We make the assumption that the gcc_toolchain will produce a soname with
+ # the following definition.
+ soname = "{{target_output_name}}{{output_extension}}"
+
+ stripped_soname = "lib.stripped/${soname}.tmp"
+ temp_stripped_soname = "${stripped_soname}.tmp"
+
android_strip = "${tool_prefix}strip"
mkdir_command = "mkdir -p lib.stripped"
- strip_command = "$android_strip --strip-unneeded -o lib.stripped/\$soname.tmp \$lib"
- replace_command = "if ! cmp -s lib.stripped/\${soname}.tmp lib.stripped/\${soname}; then mv lib.stripped/\${soname}.tmp lib.stripped/\${soname}; fi"
+ strip_command = "$android_strip --strip-unneeded -o $temp_stripped_soname $soname"
+ replace_command = "if ! cmp -s $temp_stripped_soname $stripped_soname; then mv $temp_stripped_soname $stripped_soname; fi"
postsolink = "$mkdir_command && $strip_command && $replace_command"
}
}

Powered by Google App Engine
This is Rietveld 408576698