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

Side by Side Diff: build/java_apk.gypi

Issue 1408383002: Add flag to enable proguard for debug build. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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 unified diff | Download patch
« build/android/dex_action.gypi ('K') | « build/android/gyp/dex.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 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 # This file is meant to be included into a target to provide a rule 5 # This file is meant to be included into a target to provide a rule
6 # to build Android APKs in a consistent manner. 6 # to build Android APKs in a consistent manner.
7 # 7 #
8 # To use this, create a gyp target with the following form: 8 # To use this, create a gyp target with the following form:
9 # { 9 # {
10 # 'target_name': 'my_package_apk', 10 # 'target_name': 'my_package_apk',
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 'library_dexed_jars_paths': [], 86 'library_dexed_jars_paths': [],
87 'main_dex_list_path': '<(intermediate_dir)/main_dex_list.txt', 87 'main_dex_list_path': '<(intermediate_dir)/main_dex_list.txt',
88 'main_dex_list_paths': ['<(main_dex_list_path)'], 88 'main_dex_list_paths': ['<(main_dex_list_path)'],
89 'additional_src_dirs': [], 89 'additional_src_dirs': [],
90 'generated_src_dirs': [], 90 'generated_src_dirs': [],
91 'app_manifest_version_name%': '<(android_app_version_name)', 91 'app_manifest_version_name%': '<(android_app_version_name)',
92 'app_manifest_version_code%': '<(android_app_version_code)', 92 'app_manifest_version_code%': '<(android_app_version_code)',
93 # aapt generates this proguard.txt. 93 # aapt generates this proguard.txt.
94 'generated_proguard_file': '<(intermediate_dir)/proguard.txt', 94 'generated_proguard_file': '<(intermediate_dir)/proguard.txt',
95 'proguard_enabled%': 'false', 95 'proguard_enabled%': 'false',
96 'debug_build_proguard_enabled%': 'false',
jbudorick 2015/10/19 13:24:13 I really don't like doing this separately but can
96 'proguard_flags_paths': ['<(generated_proguard_file)'], 97 'proguard_flags_paths': ['<(generated_proguard_file)'],
97 'jar_name': 'chromium_apk_<(_target_name).jar', 98 'jar_name': 'chromium_apk_<(_target_name).jar',
98 'resource_dir%':'<(DEPTH)/build/android/ant/empty/res', 99 'resource_dir%':'<(DEPTH)/build/android/ant/empty/res',
99 'R_package%':'', 100 'R_package%':'',
100 'include_all_resources%': 0, 101 'include_all_resources%': 0,
101 'additional_R_text_files': [], 102 'additional_R_text_files': [],
102 'dependencies_locale_zip_alternative_paths%': [], 103 'dependencies_locale_zip_alternative_paths%': [],
103 'dependencies_locale_zip_paths': [], 104 'dependencies_locale_zip_paths': [],
104 'dependencies_res_zip_paths': [], 105 'dependencies_res_zip_paths': [],
105 'additional_res_packages': [], 106 'additional_res_packages': [],
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 # Pass the jar path to the apk's "fake" jar target. This would be better as 246 # Pass the jar path to the apk's "fake" jar target. This would be better as
246 # direct_dependent_settings, but a variable set by a direct_dependent_settings 247 # direct_dependent_settings, but a variable set by a direct_dependent_settings
247 # cannot be lifted in a dependent to all_dependent_settings. 248 # cannot be lifted in a dependent to all_dependent_settings.
248 'all_dependent_settings': { 249 'all_dependent_settings': {
249 'conditions': [ 250 'conditions': [
250 ['proguard_enabled == "true"', { 251 ['proguard_enabled == "true"', {
251 'variables': { 252 'variables': {
252 'proguard_enabled': 'true', 253 'proguard_enabled': 'true',
253 } 254 }
254 }], 255 }],
256 ['debug_build_proguard_enabled == "true"', {
257 'variables': {
258 'debug_build_proguard_enabled': 'true',
259 }
260 }],
255 ], 261 ],
256 'variables': { 262 'variables': {
257 'apk_output_jar_path': '<(jar_path)', 263 'apk_output_jar_path': '<(jar_path)',
258 'tested_apk_obfuscated_jar_path': '<(obfuscated_jar_path)', 264 'tested_apk_obfuscated_jar_path': '<(obfuscated_jar_path)',
259 'tested_apk_dex_path': '<(dex_path)', 265 'tested_apk_dex_path': '<(dex_path)',
260 'tested_apk_is_multidex': '<(enable_multidex)', 266 'tested_apk_is_multidex': '<(enable_multidex)',
261 }, 267 },
262 }, 268 },
263 'conditions': [ 269 'conditions': [
264 ['resource_dir!=""', { 270 ['resource_dir!=""', {
(...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after
993 ], 999 ],
994 'additional_obfuscate_input_paths': [ 1000 'additional_obfuscate_input_paths': [
995 '>(tested_apk_obfuscated_jar_path).info', 1001 '>(tested_apk_obfuscated_jar_path).info',
996 ], 1002 ],
997 }], 1003 }],
998 ['proguard_enabled == "true"', { 1004 ['proguard_enabled == "true"', {
999 'additional_obfuscate_options': [ 1005 'additional_obfuscate_options': [
1000 '--proguard-enabled', 1006 '--proguard-enabled',
1001 ], 1007 ],
1002 }], 1008 }],
1009 ['debug_build_proguard_enabled == "true"', {
1010 'additional_obfuscate_options': [
1011 '--debug-build-proguard-enabled',
1012 ],
1013 }],
1003 ], 1014 ],
1004 'obfuscate_input_jars_paths': [ 1015 'obfuscate_input_jars_paths': [
1005 '>@(input_jars_paths)', 1016 '>@(input_jars_paths)',
1006 '<(jar_path)', 1017 '<(jar_path)',
1007 ], 1018 ],
1008 }, 1019 },
1009 'conditions': [ 1020 'conditions': [
1010 ['is_test_apk == 1', { 1021 ['is_test_apk == 1', {
1011 'outputs': [ 1022 'outputs': [
1012 '<(test_jar_path)', 1023 '<(test_jar_path)',
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
1102 ['is_test_apk == 1 and tested_apk_dex_path != "/"', { 1113 ['is_test_apk == 1 and tested_apk_dex_path != "/"', {
1103 'variables': { 1114 'variables': {
1104 'dex_additional_options': [ 1115 'dex_additional_options': [
1105 '--excluded-paths', '@FileArg(>(tested_apk_dex_path).inputs)' 1116 '--excluded-paths', '@FileArg(>(tested_apk_dex_path).inputs)'
1106 ], 1117 ],
1107 }, 1118 },
1108 'inputs': [ 1119 'inputs': [
1109 '>(tested_apk_dex_path).inputs', 1120 '>(tested_apk_dex_path).inputs',
1110 ], 1121 ],
1111 }], 1122 }],
1112 ['proguard_enabled == "true"', { 1123 ['proguard_enabled == "true" or debug_build_proguard_enabled == "true"', {
1113 'inputs': [ '<(obfuscate_stamp)' ] 1124 'inputs': [ '<(obfuscate_stamp)' ]
1114 }, { 1125 }, {
1115 'inputs': [ '<(emma_instr_stamp)' ] 1126 'inputs': [ '<(emma_instr_stamp)' ]
1116 }], 1127 }],
1117 ], 1128 ],
1118 'includes': [ 'android/dex_action.gypi' ], 1129 'includes': [ 'android/dex_action.gypi' ],
1119 }, 1130 },
1120 { 1131 {
1121 'variables': { 1132 'variables': {
1122 'local_dependencies_res_zip_paths': ['>@(dependencies_res_zip_paths)'], 1133 'local_dependencies_res_zip_paths': ['>@(dependencies_res_zip_paths)'],
(...skipping 27 matching lines...) Expand all
1150 'native_libs_dir': '<(apk_package_native_libs_dir)', 1161 'native_libs_dir': '<(apk_package_native_libs_dir)',
1151 }, { 1162 }, {
1152 'native_libs_dir': '<(DEPTH)/build/android/ant/empty/res', 1163 'native_libs_dir': '<(DEPTH)/build/android/ant/empty/res',
1153 }], 1164 }],
1154 ], 1165 ],
1155 }, 1166 },
1156 'includes': ['android/apkbuilder_action.gypi'], 1167 'includes': ['android/apkbuilder_action.gypi'],
1157 }, 1168 },
1158 ], 1169 ],
1159 } 1170 }
OLDNEW
« build/android/dex_action.gypi ('K') | « build/android/gyp/dex.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698