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

Side by Side Diff: build/config/android/internal_rules.gni

Issue 2142413004: Add required deps to third_party/android_support_test_runner (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated android_support_test_runner to use third_party/junit Created 4 years, 4 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
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 import("//build/config/android/config.gni") 5 import("//build/config/android/config.gni")
6 import("//build/config/sanitizers/sanitizers.gni") 6 import("//build/config/sanitizers/sanitizers.gni")
7 7
8 assert(is_android) 8 assert(is_android)
9 9
10 # These identify targets that have .build_config files (except for android_apk, 10 # These identify targets that have .build_config files (except for android_apk,
(...skipping 1858 matching lines...) Expand 10 before | Expand all | Expand 10 after
1869 # java_sources_file: Path to file containing list of files to compile. 1869 # java_sources_file: Path to file containing list of files to compile.
1870 # chromium_code: If true, enable extra warnings. 1870 # chromium_code: If true, enable extra warnings.
1871 # srcjar_deps: List of srcjar dependencies. The .java files contained in the 1871 # srcjar_deps: List of srcjar dependencies. The .java files contained in the
1872 # dependencies srcjar outputs will be compiled and added to the output jar . 1872 # dependencies srcjar outputs will be compiled and added to the output jar .
1873 # jar_path: Use this to explicitly set the output jar path. Defaults to 1873 # jar_path: Use this to explicitly set the output jar path. Defaults to
1874 # "${target_gen_dir}/${target_name}.jar. 1874 # "${target_gen_dir}/${target_name}.jar.
1875 template("compile_java") { 1875 template("compile_java") {
1876 set_sources_assignment_filter([]) 1876 set_sources_assignment_filter([])
1877 forward_variables_from(invoker, [ "testonly" ]) 1877 forward_variables_from(invoker, [ "testonly" ])
1878 1878
1879 _use_host_bootclasspath = false
1880 if (defined(invoker.use_host_bootclasspath)) {
1881 _use_host_bootclasspath = invoker.use_host_bootclasspath
1882 }
1883
1879 assert(defined(invoker.build_config)) 1884 assert(defined(invoker.build_config))
1880 assert(defined(invoker.jar_path)) 1885 assert(defined(invoker.jar_path))
1881 1886
1882 _build_config = invoker.build_config 1887 _build_config = invoker.build_config
1883 1888
1884 _chromium_code = false 1889 _chromium_code = false
1885 if (defined(invoker.chromium_code)) { 1890 if (defined(invoker.chromium_code)) {
1886 _chromium_code = invoker.chromium_code 1891 _chromium_code = invoker.chromium_code
1887 } 1892 }
1888 1893
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
2018 if (defined(invoker.alternative_android_sdk_ijar)) { 2023 if (defined(invoker.alternative_android_sdk_ijar)) {
2019 deps += [ invoker.alternative_android_sdk_ijar_dep ] 2024 deps += [ invoker.alternative_android_sdk_ijar_dep ]
2020 _android_sdk_ijar = invoker.alternative_android_sdk_ijar 2025 _android_sdk_ijar = invoker.alternative_android_sdk_ijar
2021 } else { 2026 } else {
2022 deps += [ "//build/android:android_ijar" ] 2027 deps += [ "//build/android:android_ijar" ]
2023 _android_sdk_ijar = "$root_out_dir/lib.java/android.interface.jar" 2028 _android_sdk_ijar = "$root_out_dir/lib.java/android.interface.jar"
2024 } 2029 }
2025 inputs += [ _android_sdk_ijar ] 2030 inputs += [ _android_sdk_ijar ]
2026 _rebased_android_sdk_ijar = 2031 _rebased_android_sdk_ijar =
2027 rebase_path(_android_sdk_ijar, root_build_dir) 2032 rebase_path(_android_sdk_ijar, root_build_dir)
2028 args += [ "--bootclasspath=$_rebased_android_sdk_ijar" ] 2033 args += [ "--bootclasspath=$_rebased_android_sdk_ijar" ]
mikecase (-- gone --) 2016/08/22 23:42:17 I would probably just add a flag that causes this
2029 } 2034 }
2035 if (_use_host_bootclasspath) {
2036 args += [ "--use_host_bootclasspath=1" ]
2037 }
2030 foreach(e, _manifest_entries) { 2038 foreach(e, _manifest_entries) {
2031 args += [ "--manifest-entry=" + e ] 2039 args += [ "--manifest-entry=" + e ]
2032 } 2040 }
2033 if (_chromium_code) { 2041 if (_chromium_code) {
2034 args += [ "--chromium-code=1" ] 2042 args += [ "--chromium-code=1" ]
2035 } 2043 }
2036 if (_enable_errorprone) { 2044 if (_enable_errorprone) {
2037 deps += [ "//third_party/errorprone:chromium_errorprone" ] 2045 deps += [ "//third_party/errorprone:chromium_errorprone" ]
2038 args += [ 2046 args += [
2039 "--use-errorprone-path", 2047 "--use-errorprone-path",
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
2117 public_deps += [ ":$_emma_instr_target_name" ] 2125 public_deps += [ ":$_emma_instr_target_name" ]
2118 } else { 2126 } else {
2119 public_deps += [ ":$_process_prebuilt_target_name" ] 2127 public_deps += [ ":$_process_prebuilt_target_name" ]
2120 } 2128 }
2121 } 2129 }
2122 } 2130 }
2123 2131
2124 template("java_library_impl") { 2132 template("java_library_impl") {
2125 set_sources_assignment_filter([]) 2133 set_sources_assignment_filter([])
2126 forward_variables_from(invoker, [ "testonly" ]) 2134 forward_variables_from(invoker, [ "testonly" ])
2135 _use_host_bootclasspath = false
2136 if (defined(invoker.use_host_bootclasspath)) {
2137 _use_host_bootclasspath = invoker.use_host_bootclasspath
2138 }
2127 _accumulated_deps = [] 2139 _accumulated_deps = []
2128 if (defined(invoker.deps)) { 2140 if (defined(invoker.deps)) {
2129 _accumulated_deps = invoker.deps 2141 _accumulated_deps = invoker.deps
2130 } 2142 }
2131 2143
2132 assert(defined(invoker.java_files) || defined(invoker.srcjars) || 2144 assert(defined(invoker.java_files) || defined(invoker.srcjars) ||
2133 defined(invoker.srcjar_deps)) 2145 defined(invoker.srcjar_deps))
2134 _base_path = "$target_gen_dir/$target_name" 2146 _base_path = "$target_gen_dir/$target_name"
2135 2147
2136 # Jar files can be needed at runtime (by Robolectric tests or java binaries) , 2148 # Jar files can be needed at runtime (by Robolectric tests or java binaries) ,
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
2292 java_files = _java_files 2304 java_files = _java_files
2293 if (_java_files != []) { 2305 if (_java_files != []) {
2294 java_sources_file = _java_sources_file 2306 java_sources_file = _java_sources_file
2295 } 2307 }
2296 srcjar_deps = _srcjar_deps 2308 srcjar_deps = _srcjar_deps
2297 srcjars = _srcjars 2309 srcjars = _srcjars
2298 chromium_code = _chromium_code 2310 chromium_code = _chromium_code
2299 supports_android = _supports_android 2311 supports_android = _supports_android
2300 emma_instrument = _emma_instrument 2312 emma_instrument = _emma_instrument
2301 deps = _accumulated_deps 2313 deps = _accumulated_deps
2314 use_host_bootclasspath = _use_host_bootclasspath
2302 } 2315 }
2303 _accumulated_deps += [ ":$_compile_java_target" ] 2316 _accumulated_deps += [ ":$_compile_java_target" ]
2304 assert(_accumulated_deps != []) # Mark used. 2317 assert(_accumulated_deps != []) # Mark used.
2305 2318
2306 if (defined(invoker.main_class)) { 2319 if (defined(invoker.main_class)) {
2307 # Targets might use the generated script while building, so make it a dep 2320 # Targets might use the generated script while building, so make it a dep
2308 # rather than a data_dep. 2321 # rather than a data_dep.
2309 _final_deps += [ ":${_template_name}__java_binary_script" ] 2322 _final_deps += [ ":${_template_name}__java_binary_script" ]
2310 java_binary_script("${_template_name}__java_binary_script") { 2323 java_binary_script("${_template_name}__java_binary_script") {
2311 forward_variables_from(invoker, 2324 forward_variables_from(invoker,
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
2620 outputs = [ 2633 outputs = [
2621 depfile, 2634 depfile,
2622 invoker.out_manifest, 2635 invoker.out_manifest,
2623 ] 2636 ]
2624 inputs = [ 2637 inputs = [
2625 invoker.main_manifest, 2638 invoker.main_manifest,
2626 ] 2639 ]
2627 } 2640 }
2628 } 2641 }
2629 } 2642 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698