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

Unified Diff: build/config/android/config.gni

Issue 2123753005: Creating new gn arg: enable_all_proguard_optimizations. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased again Created 4 years, 5 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 | « BUILD.gn ('k') | build/config/android/rules.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/android/config.gni
diff --git a/build/config/android/config.gni b/build/config/android/config.gni
index 3590205c37b8057ede2f66c78cd6eb59b16b5093..3a62c216c18bd0d4fc94f645695b79da95e2bfb9 100644
--- a/build/config/android/config.gni
+++ b/build/config/android/config.gni
@@ -124,23 +124,35 @@ if (is_android) {
# Required for Android M+ due to SELinux policies (stronger sandboxing).
disable_incremental_isolated_processes = false
+ # Enables all ProGuard optimizations. These optimizations must not be
+ # enabled for instrumentation tests, since they cause code required by the
+ # tests to be removed.
+ # TODO(smaier): when buildbots get updated to set this flag, change the
+ # default to is_official_build
+ enable_all_proguard_optimizations = false
+
# Speed up incremental compiles by compiling only changed files.
enable_incremental_javac = false
# Speed up dexing using dx --incremental.
enable_incremental_dx = is_java_debug
- # Neither of these should ever be used for release builds since they are
- # somewhat experimental and dx --incremental is known to not produce
- # byte-for-byte identical output.
- assert(!(enable_incremental_dx && !is_java_debug))
- assert(!(enable_incremental_javac && !is_java_debug))
-
# Adds intrumentation to each function. Writes a file with the order that
# functions are called at startup.
use_order_profiling = false
}
+ # Ensuring we never have a situation where we are asking to have debug java
+ # on alongside all ProGuard optimizations turned on, as these are mutually
+ # exclusive.
+ assert(!(is_java_debug && enable_all_proguard_optimizations))
+
+ # Neither of these should ever be used for release builds since they are
+ # somewhat experimental and dx --incremental is known to not produce
+ # byte-for-byte identical output.
+ assert(!(enable_incremental_dx && !is_java_debug))
+ assert(!(enable_incremental_javac && !is_java_debug))
+
# Host stuff -----------------------------------------------------------------
# Defines the name the Android build gives to the current host CPU
« no previous file with comments | « BUILD.gn ('k') | build/config/android/rules.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698