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

Side by Side Diff: build/java_apk.gypi

Issue 1136573002: Use the Errorprone Compiler (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: use public jar instead of local Created 5 years, 6 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
« no previous file with comments | « build/java.gypi ('k') | third_party/errorprone/BUILD.gn » ('j') | 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 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 'unsigned_standalone_apk_path': '<(unsigned_standalone_apk_path)', 201 'unsigned_standalone_apk_path': '<(unsigned_standalone_apk_path)',
202 'unsigned_apk_path': '<(unsigned_apk_path)', 202 'unsigned_apk_path': '<(unsigned_apk_path)',
203 'unsigned_abi_split_apk_path': '<(unsigned_abi_split_apk_path)', 203 'unsigned_abi_split_apk_path': '<(unsigned_abi_split_apk_path)',
204 'create_abi_split%': '<(create_abi_split)', 204 'create_abi_split%': '<(create_abi_split)',
205 'managed_input_apk_path': '<(managed_input_apk_path)', 205 'managed_input_apk_path': '<(managed_input_apk_path)',
206 'libchromium_android_linker': 'libchromium_android_linker.>(android_product_ extension)', 206 'libchromium_android_linker': 'libchromium_android_linker.>(android_product_ extension)',
207 'extra_native_libs': [], 207 'extra_native_libs': [],
208 'native_lib_placeholder_stamp': '<(apk_package_native_libs_dir)/<(android_ap p_abi)/native_lib_placeholder.stamp', 208 'native_lib_placeholder_stamp': '<(apk_package_native_libs_dir)/<(android_ap p_abi)/native_lib_placeholder.stamp',
209 'native_lib_placeholders': [], 209 'native_lib_placeholders': [],
210 'main_apk_name': '<(apk_name)', 210 'main_apk_name': '<(apk_name)',
211 'enable_errorprone%': '1',
jbudorick 2015/06/04 14:00:14 Should be '0'
raywilliams_chromium 2015/06/04 16:32:10 Done.
212 'errorprone_exe_path': '<(PRODUCT_DIR)/bin.java/chromium_errorprone',
211 }, 213 },
212 # Pass the jar path to the apk's "fake" jar target. This would be better as 214 # Pass the jar path to the apk's "fake" jar target. This would be better as
213 # direct_dependent_settings, but a variable set by a direct_dependent_settings 215 # direct_dependent_settings, but a variable set by a direct_dependent_settings
214 # cannot be lifted in a dependent to all_dependent_settings. 216 # cannot be lifted in a dependent to all_dependent_settings.
215 'all_dependent_settings': { 217 'all_dependent_settings': {
216 'conditions': [ 218 'conditions': [
217 ['proguard_enabled == "true"', { 219 ['proguard_enabled == "true"', {
218 'variables': { 220 'variables': {
219 'proguard_enabled': 'true', 221 'proguard_enabled': 'true',
220 } 222 }
(...skipping 22 matching lines...) Expand all
243 ['native_lib_target != "" and component == "shared_library"', { 245 ['native_lib_target != "" and component == "shared_library"', {
244 'dependencies': [ 246 'dependencies': [
245 '<(DEPTH)/build/android/setup.gyp:copy_system_libraries', 247 '<(DEPTH)/build/android/setup.gyp:copy_system_libraries',
246 ], 248 ],
247 }], 249 }],
248 ['use_chromium_linker == 1', { 250 ['use_chromium_linker == 1', {
249 'dependencies': [ 251 'dependencies': [
250 '<(DEPTH)/base/base.gyp:chromium_android_linker', 252 '<(DEPTH)/base/base.gyp:chromium_android_linker',
251 ], 253 ],
252 }], 254 }],
255 ['enable_errorprone == 1', {
256 'dependencies': [
257 '<(DEPTH)/third_party/errorprone/errorprone.gyp:chromium_errorprone',
258 ],
259 }],
253 ['native_lib_target != ""', { 260 ['native_lib_target != ""', {
254 'variables': { 261 'variables': {
255 'conditions': [ 262 'conditions': [
256 ['use_chromium_linker == 1', { 263 ['use_chromium_linker == 1', {
257 'variables': { 264 'variables': {
258 'chromium_linker_path': [ 265 'chromium_linker_path': [
259 '<(SHARED_LIB_DIR)/<(libchromium_android_linker)', 266 '<(SHARED_LIB_DIR)/<(libchromium_android_linker)',
260 ], 267 ],
261 } 268 }
262 }, { 269 }, {
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
785 792
786 '--stamp', '<(codegen_stamp)', 793 '--stamp', '<(codegen_stamp)',
787 794
788 '<@(process_resources_options)', 795 '<@(process_resources_options)',
789 ], 796 ],
790 }, 797 },
791 { 798 {
792 'action_name': 'javac_<(_target_name)', 799 'action_name': 'javac_<(_target_name)',
793 'message': 'Compiling java for <(_target_name)', 800 'message': 'Compiling java for <(_target_name)',
794 'variables': { 801 'variables': {
802 'extra_args': [],
803 'extra_inputs': [],
795 'gen_src_dirs': [ 804 'gen_src_dirs': [
796 '<(intermediate_dir)/gen', 805 '<(intermediate_dir)/gen',
797 '>@(generated_src_dirs)', 806 '>@(generated_src_dirs)',
798 ], 807 ],
799 # If there is a separate find for additional_src_dirs, it will find the 808 # If there is a separate find for additional_src_dirs, it will find the
800 # wrong .java files when additional_src_dirs is empty. 809 # wrong .java files when additional_src_dirs is empty.
801 # TODO(thakis): Gyp caches >! evaluation by command. Both java.gypi and 810 # TODO(thakis): Gyp caches >! evaluation by command. Both java.gypi and
802 # java_apk.gypi evaluate the same command, and at the moment two targets 811 # java_apk.gypi evaluate the same command, and at the moment two targets
803 # set java_in_dir to "java". Add a dummy comment here to make sure 812 # set java_in_dir to "java". Add a dummy comment here to make sure
804 # that the two targets (one uses java.gypi, the other java_apk.gypi) 813 # that the two targets (one uses java.gypi, the other java_apk.gypi)
805 # get distinct source lists. Medium-term, make targets list all their 814 # get distinct source lists. Medium-term, make targets list all their
806 # Java files instead of using find. (As is, this will be broken if two 815 # Java files instead of using find. (As is, this will be broken if two
807 # targets use the same java_in_dir and both use java_apk.gypi or 816 # targets use the same java_in_dir and both use java_apk.gypi or
808 # both use java.gypi.) 817 # both use java.gypi.)
809 'java_sources': ['>!@(find >(java_in_dir)>(java_in_dir_suffix) >(additio nal_src_dirs) -name "*.java" # apk)'], 818 'java_sources': ['>!@(find >(java_in_dir)>(java_in_dir_suffix) >(additio nal_src_dirs) -name "*.java" # apk)'],
810 819 'conditions': [
820 ['enable_errorprone == 1', {
821 'extra_inputs': [
822 '<(errorprone_exe_path)',
823 ],
824 'extra_args': [ '--use-errorprone-path=<(errorprone_exe_path)' ],
825 }],
826 ],
811 }, 827 },
812 'inputs': [ 828 'inputs': [
813 '<(DEPTH)/build/android/gyp/util/build_utils.py', 829 '<(DEPTH)/build/android/gyp/util/build_utils.py',
814 '<(DEPTH)/build/android/gyp/javac.py', 830 '<(DEPTH)/build/android/gyp/javac.py',
815 '>@(java_sources)', 831 '>@(java_sources)',
816 '>@(input_jars_paths)', 832 '>@(input_jars_paths)',
817 '<(codegen_stamp)', 833 '<(codegen_stamp)',
834 '<@(extra_inputs)',
818 ], 835 ],
819 'conditions': [ 836 'conditions': [
820 ['native_lib_target != ""', { 837 ['native_lib_target != ""', {
821 'inputs': [ '<(native_libraries_java_stamp)' ], 838 'inputs': [ '<(native_libraries_java_stamp)' ],
822 }], 839 }],
823 ], 840 ],
824 'outputs': [ 841 'outputs': [
825 '<(compile_stamp)', 842 '<(compile_stamp)',
826 '<(javac_jar_path)', 843 '<(javac_jar_path)',
827 ], 844 ],
828 'action': [ 845 'action': [
829 'python', '<(DEPTH)/build/android/gyp/javac.py', 846 'python', '<(DEPTH)/build/android/gyp/javac.py',
830 '--classpath=>(input_jars_paths) <(android_sdk_jar)', 847 '--classpath=>(input_jars_paths) <(android_sdk_jar)',
831 '--src-gendirs=>(gen_src_dirs)', 848 '--src-gendirs=>(gen_src_dirs)',
832 '--javac-includes=<(javac_includes)', 849 '--javac-includes=<(javac_includes)',
833 '--chromium-code=<(chromium_code)', 850 '--chromium-code=<(chromium_code)',
834 '--jar-path=<(javac_jar_path)', 851 '--jar-path=<(javac_jar_path)',
835 '--jar-excluded-classes=<(jar_excluded_classes)', 852 '--jar-excluded-classes=<(jar_excluded_classes)',
836 '--stamp=<(compile_stamp)', 853 '--stamp=<(compile_stamp)',
854 '<@(extra_args)',
837 '>@(java_sources)', 855 '>@(java_sources)',
838 ], 856 ],
839 }, 857 },
840 { 858 {
841 'action_name': 'instr_jar_<(_target_name)', 859 'action_name': 'instr_jar_<(_target_name)',
842 'message': 'Instrumenting <(_target_name) jar', 860 'message': 'Instrumenting <(_target_name) jar',
843 'variables': { 861 'variables': {
844 'input_path': '<(javac_jar_path)', 862 'input_path': '<(javac_jar_path)',
845 'output_path': '<(jar_path)', 863 'output_path': '<(jar_path)',
846 'stamp_path': '<(instr_stamp)', 864 'stamp_path': '<(instr_stamp)',
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
1019 'native_libs_dir': '<(apk_package_native_libs_dir)', 1037 'native_libs_dir': '<(apk_package_native_libs_dir)',
1020 }, { 1038 }, {
1021 'native_libs_dir': '<(DEPTH)/build/android/ant/empty/res', 1039 'native_libs_dir': '<(DEPTH)/build/android/ant/empty/res',
1022 }], 1040 }],
1023 ], 1041 ],
1024 }, 1042 },
1025 'includes': ['android/apkbuilder_action.gypi'], 1043 'includes': ['android/apkbuilder_action.gypi'],
1026 }, 1044 },
1027 ], 1045 ],
1028 } 1046 }
OLDNEW
« no previous file with comments | « build/java.gypi ('k') | third_party/errorprone/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698