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

Side by Side Diff: build/android/gyp/write_build_config.py

Issue 1471393002: GN Incremental Install: Don't use proguarded dex when is_debug = false (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add warning Created 5 years 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
« no previous file with comments | « no previous file | build/android/incremental_install/create_install_script.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright 2014 The Chromium Authors. All rights reserved. 3 # Copyright 2014 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Writes a build_config file. 7 """Writes a build_config file.
8 8
9 The build_config file for a target is a json file containing information about 9 The build_config file for a target is a json file containing information about
10 how to build that target based on the target's dependencies. This includes 10 how to build that target based on the target's dependencies. This includes
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 assert proguard_enabled, ('proguard must be enabled for instrumentation' 388 assert proguard_enabled, ('proguard must be enabled for instrumentation'
389 ' apks if it\'s enabled for the tested apk') 389 ' apks if it\'s enabled for the tested apk')
390 proguard_config['tested_apk_info'] = tested_apk_config['proguard_info'] 390 proguard_config['tested_apk_info'] = tested_apk_config['proguard_info']
391 391
392 deps_info['tested_apk_path'] = tested_apk_config['apk_path'] 392 deps_info['tested_apk_path'] = tested_apk_config['apk_path']
393 393
394 # Dependencies for the final dex file of an apk or a 'deps_dex'. 394 # Dependencies for the final dex file of an apk or a 'deps_dex'.
395 if options.type in ['android_apk', 'deps_dex']: 395 if options.type in ['android_apk', 'deps_dex']:
396 config['final_dex'] = {} 396 config['final_dex'] = {}
397 dex_config = config['final_dex'] 397 dex_config = config['final_dex']
398 if proguard_enabled:
399 # When proguard is enabled, the proguarded jar contains the code for all
400 # of the dependencies.
401 deps_dex_files = []
402 dex_config['dependency_dex_files'] = deps_dex_files 398 dex_config['dependency_dex_files'] = deps_dex_files
403 399
404 if options.type == 'android_apk': 400 if options.type == 'android_apk':
405 config['dist_jar'] = { 401 config['dist_jar'] = {
406 'dependency_jars': [ 402 'dependency_jars': [
407 c['jar_path'] for c in all_library_deps 403 c['jar_path'] for c in all_library_deps
408 ] 404 ]
409 } 405 }
410 manifest = AndroidManifest(options.android_manifest) 406 manifest = AndroidManifest(options.android_manifest)
411 deps_info['package_name'] = manifest.GetPackageName() 407 deps_info['package_name'] = manifest.GetPackageName()
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
454 build_utils.WriteJson(config, options.build_config, only_if_changed=True) 450 build_utils.WriteJson(config, options.build_config, only_if_changed=True)
455 451
456 if options.depfile: 452 if options.depfile:
457 build_utils.WriteDepfile( 453 build_utils.WriteDepfile(
458 options.depfile, 454 options.depfile,
459 deps.AllConfigPaths() + build_utils.GetPythonDependencies()) 455 deps.AllConfigPaths() + build_utils.GetPythonDependencies())
460 456
461 457
462 if __name__ == '__main__': 458 if __name__ == '__main__':
463 sys.exit(main(sys.argv[1:])) 459 sys.exit(main(sys.argv[1:]))
OLDNEW
« no previous file with comments | « no previous file | build/android/incremental_install/create_install_script.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698