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

Side by Side Diff: build/java_apk.gypi

Issue 13861023: [Android][Reland] Extract signing+zipaligning to python (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix clobber build Created 7 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « build/android/gyp/finalize_apk.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 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 'classes_dir': '<(intermediate_dir)/classes', 94 'classes_dir': '<(intermediate_dir)/classes',
95 'javac_includes': [], 95 'javac_includes': [],
96 'jar_excluded_classes': [], 96 'jar_excluded_classes': [],
97 'jar_path': '<(PRODUCT_DIR)/lib.java/<(jar_name)', 97 'jar_path': '<(PRODUCT_DIR)/lib.java/<(jar_name)',
98 'obfuscated_jar_path': '<(intermediate_dir)/obfuscated.jar', 98 'obfuscated_jar_path': '<(intermediate_dir)/obfuscated.jar',
99 'dex_path': '<(intermediate_dir)/classes.dex', 99 'dex_path': '<(intermediate_dir)/classes.dex',
100 'android_manifest_path%': '<(java_in_dir)/AndroidManifest.xml', 100 'android_manifest_path%': '<(java_in_dir)/AndroidManifest.xml',
101 'push_stamp': '<(intermediate_dir)/push.stamp', 101 'push_stamp': '<(intermediate_dir)/push.stamp',
102 'link_stamp': '<(intermediate_dir)/link.stamp', 102 'link_stamp': '<(intermediate_dir)/link.stamp',
103 'codegen_input_paths': [], 103 'codegen_input_paths': [],
104 'keystore_path': '<(DEPTH)/build/android/ant/chromium-debug.keystore',
105 'unsigned_apk_path': '<(intermediate_dir)/<(apk_name)-unsigned.apk',
104 'final_apk_path%': '<(PRODUCT_DIR)/apks/<(apk_name).apk', 106 'final_apk_path%': '<(PRODUCT_DIR)/apks/<(apk_name).apk',
105 'source_dir': '<(java_in_dir)/src', 107 'source_dir': '<(java_in_dir)/src',
106 'apk_install_stamp': '<(intermediate_dir)/apk_install.stamp', 108 'apk_install_stamp': '<(intermediate_dir)/apk_install.stamp',
107 'apk_package_native_libs_dir': '<(intermediate_dir)/libs', 109 'apk_package_native_libs_dir': '<(intermediate_dir)/libs',
108 }, 110 },
109 # Pass the jar path to the apk's "fake" jar target. This would be better as 111 # Pass the jar path to the apk's "fake" jar target. This would be better as
110 # direct_dependent_settings, but a variable set by a direct_dependent_settings 112 # direct_dependent_settings, but a variable set by a direct_dependent_settings
111 # cannot be lifted in a dependent to all_dependent_settings. 113 # cannot be lifted in a dependent to all_dependent_settings.
112 'all_dependent_settings': { 114 'all_dependent_settings': {
113 'variables': { 115 'variables': {
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
534 ], 536 ],
535 'conditions': [ 537 'conditions': [
536 ['is_test_apk == 1', { 538 ['is_test_apk == 1', {
537 'variables': { 539 'variables': {
538 'additional_res_dirs=': [], 540 'additional_res_dirs=': [],
539 'additional_res_packages=': [], 541 'additional_res_packages=': [],
540 } 542 }
541 }], 543 }],
542 ], 544 ],
543 'outputs': [ 545 'outputs': [
544 '<(final_apk_path)', 546 '<(unsigned_apk_path)',
545 ], 547 ],
546 'action': [ 548 'action': [
547 'python', '<(DEPTH)/build/android/gyp/ant.py', 549 'python', '<(DEPTH)/build/android/gyp/ant.py',
548 '-quiet', 550 '-quiet',
549 '-DADDITIONAL_RES_DIRS=>(additional_res_dirs)', 551 '-DADDITIONAL_RES_DIRS=>(additional_res_dirs)',
550 '-DADDITIONAL_RES_PACKAGES=>(additional_res_packages)', 552 '-DADDITIONAL_RES_PACKAGES=>(additional_res_packages)',
551 '-DADDITIONAL_R_TEXT_FILES=>(additional_R_text_files)', 553 '-DADDITIONAL_R_TEXT_FILES=>(additional_R_text_files)',
552 '-DANDROID_SDK_JAR=<(android_sdk_jar)', 554 '-DANDROID_SDK_JAR=<(android_sdk_jar)',
553 '-DANDROID_SDK_ROOT=<(android_sdk_root)', 555 '-DANDROID_SDK_ROOT=<(android_sdk_root)',
554 '-DANDROID_SDK_VERSION=<(android_sdk_version)', 556 '-DANDROID_SDK_VERSION=<(android_sdk_version)',
555 '-DAPK_NAME=<(apk_name)', 557 '-DAPK_NAME=<(apk_name)',
556 '-DAPP_MANIFEST_VERSION_CODE=<(app_manifest_version_code)', 558 '-DAPP_MANIFEST_VERSION_CODE=<(app_manifest_version_code)',
557 '-DAPP_MANIFEST_VERSION_NAME=<(app_manifest_version_name)', 559 '-DAPP_MANIFEST_VERSION_NAME=<(app_manifest_version_name)',
558 '-DASSET_DIR=<(asset_location)', 560 '-DASSET_DIR=<(asset_location)',
559 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', 561 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)',
560 '-DFINAL_APK_PATH=<(final_apk_path)',
561 '-DKEYSTORE_PATH=<(DEPTH)/build/android/ant/chromium-debug.keystore',
562 '-DNATIVE_LIBS_DIR=<(apk_package_native_libs_dir)', 562 '-DNATIVE_LIBS_DIR=<(apk_package_native_libs_dir)',
563 '-DOUT_DIR=<(intermediate_dir)', 563 '-DOUT_DIR=<(intermediate_dir)',
564 '-DRESOURCE_DIR=<(resource_dir)', 564 '-DRESOURCE_DIR=<(resource_dir)',
565 '-DSOURCE_DIR=<(source_dir)', 565 '-DSOURCE_DIR=<(source_dir)',
566 '-DUNSIGNED_APK_PATH=<(unsigned_apk_path)',
566 567
567 '-Dbasedir=.', 568 '-Dbasedir=.',
568 '-buildfile', 569 '-buildfile',
569 '<(DEPTH)/build/android/ant/apk-package.xml', 570 '<(DEPTH)/build/android/ant/apk-package.xml',
570 571
571 # Add list of inputs to the command line, so if inputs change 572 # Add list of inputs to the command line, so if inputs change
572 # (e.g. if a Java file is removed), the command will be re-run. 573 # (e.g. if a Java file is removed), the command will be re-run.
573 # TODO(newt): remove this once crbug.com/177552 is fixed in ninja. 574 # TODO(newt): remove this once crbug.com/177552 is fixed in ninja.
574 '-DTHIS_IS_IGNORED=>!(echo \'>(_inputs)\' | md5sum)', 575 '-DTHIS_IS_IGNORED=>!(echo \'>(_inputs)\' | md5sum)',
575 ] 576 ]
576 }, 577 },
578 {
579 'action_name': 'finalize_apk',
580 'message': 'Signing/aligning <(_target_name) APK.',
581 'inputs': [
582 '<(DEPTH)/build/android/gyp/util/build_utils.py',
583 '<(DEPTH)/build/android/gyp/finalize_apk.py',
584 '<(unsigned_apk_path)',
585 ],
586 'outputs': [
587 '<(final_apk_path)',
588 ],
589 'action': [
590 'python', '<(DEPTH)/build/android/gyp/finalize_apk.py',
591 '--android-sdk-root=<(android_sdk_root)',
592 '--unsigned-apk-path=<(unsigned_apk_path)',
593 '--final-apk-path=<(final_apk_path)',
594 '--keystore-path=<(keystore_path)',
595
596 # TODO(newt): remove this once crbug.com/177552 is fixed in ninja.
597 '--ignore=>!(echo \'>(_inputs)\' | md5sum)',
598 ],
599 },
577 ], 600 ],
578 } 601 }
OLDNEW
« no previous file with comments | « build/android/gyp/finalize_apk.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698