OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//base/android/linker/config.gni") | 5 import("//base/android/linker/config.gni") |
6 import("//build/config/android/rules.gni") | 6 import("//build/config/android/rules.gni") |
| 7 import("//build/config/locales.gni") |
7 import("//chrome/common/features.gni") | 8 import("//chrome/common/features.gni") |
8 import("//third_party/leakcanary/config.gni") | 9 import("//third_party/leakcanary/config.gni") |
9 import("channel.gni") | 10 import("channel.gni") |
10 | 11 |
11 declare_args() { | 12 declare_args() { |
12 # Whether chrome_public_apk should use the crazy linker. | 13 # Whether chrome_public_apk should use the crazy linker. |
13 chrome_public_apk_use_chromium_linker = chromium_linker_supported | 14 chrome_public_apk_use_chromium_linker = chromium_linker_supported |
14 | 15 |
15 # Whether chrome_public_apk should use the relocation packer. | 16 # Whether chrome_public_apk should use the relocation packer. |
16 chrome_public_apk_use_relocation_packer = chromium_linker_supported | 17 chrome_public_apk_use_relocation_packer = chromium_linker_supported |
(...skipping 17 matching lines...) Expand all Loading... |
34 "enable_webvr=$enable_webvr", | 35 "enable_webvr=$enable_webvr", |
35 ] | 36 ] |
36 | 37 |
37 template("chrome_public_apk_tmpl") { | 38 template("chrome_public_apk_tmpl") { |
38 android_apk(target_name) { | 39 android_apk(target_name) { |
39 forward_variables_from(invoker, "*") | 40 forward_variables_from(invoker, "*") |
40 _native_lib_file = | 41 _native_lib_file = |
41 rebase_path("$root_gen_dir/CHROME_VERSION.json", root_out_dir) | 42 rebase_path("$root_gen_dir/CHROME_VERSION.json", root_out_dir) |
42 native_lib_version_arg = "@FileArg($_native_lib_file:full-quoted)" | 43 native_lib_version_arg = "@FileArg($_native_lib_file:full-quoted)" |
43 native_lib_version_rule = "//build/util:chrome_version_json" | 44 native_lib_version_rule = "//build/util:chrome_version_json" |
| 45 if (!defined(aapt_locale_whitelist)) { |
| 46 aapt_locale_whitelist = locales - android_chrome_omitted_locales |
| 47 } |
44 | 48 |
45 if (is_java_debug) { | 49 if (is_java_debug) { |
46 enable_multidex = true | 50 enable_multidex = true |
47 } else { | 51 } else { |
48 proguard_enabled = true | 52 proguard_enabled = true |
49 if (!defined(proguard_configs)) { | 53 if (!defined(proguard_configs)) { |
50 proguard_configs = [] | 54 proguard_configs = [] |
51 } | 55 } |
52 proguard_configs += [ | 56 proguard_configs += [ |
53 "//chrome/android/java/proguard.flags", | 57 "//chrome/android/java/proguard.flags", |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 [ "//chrome/android:monochrome_secondary_abi_lib" ] | 96 [ "//chrome/android:monochrome_secondary_abi_lib" ] |
93 } | 97 } |
94 | 98 |
95 alternative_android_sdk_jar = webview_framework_jar | 99 alternative_android_sdk_jar = webview_framework_jar |
96 app_as_shared_lib = true | 100 app_as_shared_lib = true |
97 use_chromium_linker = false | 101 use_chromium_linker = false |
98 requires_sdk_api_level_23 = true | 102 requires_sdk_api_level_23 = true |
99 enable_relocation_packing = true | 103 enable_relocation_packing = true |
100 extensions_to_not_compress = ".lpak,.pak,.bin,.dat" | 104 extensions_to_not_compress = ".lpak,.pak,.bin,.dat" |
101 | 105 |
| 106 # Webview supports all locales (has no omitted ones). |
| 107 aapt_locale_whitelist = locales |
| 108 |
102 # Incremental install doesn't work for monochrome. See crbug.com/663492. | 109 # Incremental install doesn't work for monochrome. See crbug.com/663492. |
103 never_incremental = true | 110 never_incremental = true |
104 | 111 |
105 # Configrations to make android load shared library from APK. | 112 # Configrations to make android load shared library from APK. |
106 uncompress_shared_libraries = true | 113 uncompress_shared_libraries = true |
107 page_align_shared_libraries = true | 114 page_align_shared_libraries = true |
108 | 115 |
109 forward_variables_from(invoker, "*") | 116 forward_variables_from(invoker, "*") |
110 | 117 |
111 if (!defined(deps)) { | 118 if (!defined(deps)) { |
112 deps = [] | 119 deps = [] |
113 } | 120 } |
114 deps += [ | 121 deps += [ |
115 "//android_webview:monochrome_webview_assets", | 122 "//android_webview:monochrome_webview_assets", |
116 "//android_webview/glue", | 123 "//android_webview/glue", |
117 "//chrome/android:chrome_public_non_pak_assets", | 124 "//chrome/android:chrome_public_non_pak_assets", |
118 "//chrome/android:monochrome_pak_assets", | 125 "//chrome/android:monochrome_pak_assets", |
119 ] | 126 ] |
120 | 127 |
121 if (!is_java_debug) { | 128 if (!is_java_debug) { |
122 if (!defined(proguard_configs)) { | 129 if (!defined(proguard_configs)) { |
123 proguard_configs = [] | 130 proguard_configs = [] |
124 } | 131 } |
125 proguard_configs += [ "//android_webview/apk/java/proguard.flags" ] | 132 proguard_configs += [ "//android_webview/apk/java/proguard.flags" ] |
126 } | 133 } |
127 } | 134 } |
128 } | 135 } |
OLD | NEW |