OLD | NEW |
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 591 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
602 ] | 602 ] |
603 }, | 603 }, |
604 { | 604 { |
605 'action_name': 'ant_obfuscate_<(_target_name)', | 605 'action_name': 'ant_obfuscate_<(_target_name)', |
606 'message': 'Obfuscating <(_target_name)', | 606 'message': 'Obfuscating <(_target_name)', |
607 'inputs': [ | 607 'inputs': [ |
608 '<(DEPTH)/build/android/ant/apk-obfuscate.xml', | 608 '<(DEPTH)/build/android/ant/apk-obfuscate.xml', |
609 '<(DEPTH)/build/android/ant/create-test-jar.js', | 609 '<(DEPTH)/build/android/ant/create-test-jar.js', |
610 '<(DEPTH)/build/android/gyp/util/build_utils.py', | 610 '<(DEPTH)/build/android/gyp/util/build_utils.py', |
611 '<(DEPTH)/build/android/gyp/ant.py', | 611 '<(DEPTH)/build/android/gyp/ant.py', |
| 612 '<(android_manifest_path)', |
612 '>@(proguard_flags_paths)', | 613 '>@(proguard_flags_paths)', |
613 '<(instr_stamp)', | 614 '<(instr_stamp)', |
614 ], | 615 ], |
615 'outputs': [ | 616 'outputs': [ |
616 # This lists obfuscate_stamp instead of obfuscated_jar_path because | 617 # This lists obfuscate_stamp instead of obfuscated_jar_path because |
617 # ant only writes the latter if the md5 of the inputs changes. | 618 # ant only writes the latter if the md5 of the inputs changes. |
618 '<(obfuscate_stamp)', | 619 '<(obfuscate_stamp)', |
619 ], | 620 ], |
620 'action': [ | 621 'action': [ |
621 'python', '<(DEPTH)/build/android/gyp/ant.py', | 622 'python', '<(DEPTH)/build/android/gyp/ant.py', |
622 '-quiet', | 623 '-quiet', |
623 '-DADDITIONAL_SRC_DIRS=>(additional_src_dirs)', | 624 '-DADDITIONAL_SRC_DIRS=>(additional_src_dirs)', |
| 625 '-DANDROID_MANIFEST=<(android_manifest_path)', |
624 '-DANDROID_SDK_JAR=<(android_sdk_jar)', | 626 '-DANDROID_SDK_JAR=<(android_sdk_jar)', |
625 '-DANDROID_SDK_ROOT=<(android_sdk_root)', | 627 '-DANDROID_SDK_ROOT=<(android_sdk_root)', |
626 '-DANDROID_SDK_VERSION=<(android_sdk_version)', | 628 '-DANDROID_SDK_VERSION=<(android_sdk_version)', |
627 '-DANDROID_SDK_TOOLS=<(android_sdk_tools)', | 629 '-DANDROID_SDK_TOOLS=<(android_sdk_tools)', |
628 '-DAPK_NAME=<(apk_name)', | 630 '-DAPK_NAME=<(apk_name)', |
629 '-DCREATE_TEST_JAR_PATH=<(DEPTH)/build/android/ant/create-test-jar.js', | 631 '-DCREATE_TEST_JAR_PATH=<(DEPTH)/build/android/ant/create-test-jar.js', |
630 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', | 632 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', |
631 '-DGENERATED_SRC_DIRS=>(generated_src_dirs)', | 633 '-DGENERATED_SRC_DIRS=>(generated_src_dirs)', |
632 '-DINPUT_JARS_PATHS=>(input_jars_paths)', | 634 '-DINPUT_JARS_PATHS=>(input_jars_paths)', |
633 '-DIS_TEST_APK=<(is_test_apk)', | 635 '-DIS_TEST_APK=<(is_test_apk)', |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
688 ], | 690 ], |
689 'outputs': [ | 691 'outputs': [ |
690 '<(package_resources_stamp)', | 692 '<(package_resources_stamp)', |
691 ], | 693 ], |
692 'action': [ | 694 'action': [ |
693 'python', '<(DEPTH)/build/android/gyp/ant.py', | 695 'python', '<(DEPTH)/build/android/gyp/ant.py', |
694 '-quiet', | 696 '-quiet', |
695 '-DADDITIONAL_RES_DIRS=>(additional_res_dirs)', | 697 '-DADDITIONAL_RES_DIRS=>(additional_res_dirs)', |
696 '-DADDITIONAL_RES_PACKAGES=>(additional_res_packages)', | 698 '-DADDITIONAL_RES_PACKAGES=>(additional_res_packages)', |
697 '-DADDITIONAL_R_TEXT_FILES=>(additional_R_text_files)', | 699 '-DADDITIONAL_R_TEXT_FILES=>(additional_R_text_files)', |
| 700 '-DANDROID_MANIFEST=<(android_manifest_path)', |
698 '-DANDROID_SDK_JAR=<(android_sdk_jar)', | 701 '-DANDROID_SDK_JAR=<(android_sdk_jar)', |
699 '-DANDROID_SDK_ROOT=<(android_sdk_root)', | 702 '-DANDROID_SDK_ROOT=<(android_sdk_root)', |
700 '-DANDROID_SDK_TOOLS=<(android_sdk_tools)', | 703 '-DANDROID_SDK_TOOLS=<(android_sdk_tools)', |
701 '-DAPK_NAME=<(apk_name)', | 704 '-DAPK_NAME=<(apk_name)', |
702 '-DAPP_MANIFEST_VERSION_CODE=<(app_manifest_version_code)', | 705 '-DAPP_MANIFEST_VERSION_CODE=<(app_manifest_version_code)', |
703 '-DAPP_MANIFEST_VERSION_NAME=<(app_manifest_version_name)', | 706 '-DAPP_MANIFEST_VERSION_NAME=<(app_manifest_version_name)', |
704 '-DASSET_DIR=<(asset_location)', | 707 '-DASSET_DIR=<(asset_location)', |
705 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', | 708 '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', |
706 '-DOUT_DIR=<(intermediate_dir)', | 709 '-DOUT_DIR=<(intermediate_dir)', |
707 '-DRESOURCE_DIR=<(resource_dir)', | 710 '-DRESOURCE_DIR=<(resource_dir)', |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
753 '<(DEPTH)/build/android/ant/apk-package.xml', | 756 '<(DEPTH)/build/android/ant/apk-package.xml', |
754 | 757 |
755 # Add list of inputs to the command line, so if inputs change | 758 # Add list of inputs to the command line, so if inputs change |
756 # (e.g. if a Java file is removed), the command will be re-run. | 759 # (e.g. if a Java file is removed), the command will be re-run. |
757 # TODO(newt): remove this once crbug.com/177552 is fixed in ninja. | 760 # TODO(newt): remove this once crbug.com/177552 is fixed in ninja. |
758 '-DTHIS_IS_IGNORED=>!(echo \'>(_inputs)\' | md5sum)', | 761 '-DTHIS_IS_IGNORED=>!(echo \'>(_inputs)\' | md5sum)', |
759 ] | 762 ] |
760 }, | 763 }, |
761 ], | 764 ], |
762 } | 765 } |
OLD | NEW |