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

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

Issue 1291793007: GN(android): Add scripts & runtime logic for installing _managed apks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn-managed-install
Patch Set: review comments Created 5 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 6
7 assert(is_android) 7 assert(is_android)
8 8
9 rebased_android_sdk = rebase_path(android_sdk, root_build_dir) 9 rebased_android_sdk = rebase_path(android_sdk, root_build_dir)
10 rebased_android_sdk_root = rebase_path(android_sdk_root, root_build_dir) 10 rebased_android_sdk_root = rebase_path(android_sdk_root, root_build_dir)
(...skipping 1149 matching lines...) Expand 10 before | Expand all | Expand 10 after
1160 if (defined(invoker.srcjar_deps)) { 1160 if (defined(invoker.srcjar_deps)) {
1161 _srcjar_deps = invoker.srcjar_deps 1161 _srcjar_deps = invoker.srcjar_deps
1162 } 1162 }
1163 1163
1164 _srcjars = [] 1164 _srcjars = []
1165 if (defined(invoker.srcjars)) { 1165 if (defined(invoker.srcjars)) {
1166 _srcjars = invoker.srcjars 1166 _srcjars = invoker.srcjars
1167 } 1167 }
1168 1168
1169 _java_files = [] 1169 _java_files = []
1170 if (defined(invoker.java_files)) { 1170 if (defined(invoker.DEPRECATED_java_in_dir)) {
1171 _java_files = invoker.java_files
1172 } else if (defined(invoker.DEPRECATED_java_in_dir)) {
1173 _src_dir = invoker.DEPRECATED_java_in_dir + "/src" 1171 _src_dir = invoker.DEPRECATED_java_in_dir + "/src"
1174 _src_dir_exists = exec_script("//build/dir_exists.py", 1172 _src_dir_exists = exec_script("//build/dir_exists.py",
1175 [ rebase_path(_src_dir, root_build_dir) ], 1173 [ rebase_path(_src_dir, root_build_dir) ],
1176 "string") 1174 "string")
1177 assert(_src_dir_exists == "False", 1175 assert(_src_dir_exists == "False",
1178 "In GN, java_in_dir should be the fully specified java directory " + 1176 "In GN, java_in_dir should be the fully specified java directory " +
1179 "(i.e. including the trailing \"/src\")") 1177 "(i.e. including the trailing \"/src\")")
1180 1178
1181 _java_files_build_rel = exec_script( 1179 _java_files_build_rel =
1182 "//build/android/gyp/find.py", 1180 exec_script("//build/android/gyp/find.py",
1183 [ 1181 [
1184 "--pattern", 1182 "--pattern",
1185 "*.java", 1183 "*.java",
1186 rebase_path(invoker.DEPRECATED_java_in_dir, root_build_dir), 1184 rebase_path(invoker.DEPRECATED_java_in_dir,
1187 ], 1185 root_build_dir),
1188 "list lines") 1186 ],
1187 "list lines")
1189 _java_files = rebase_path(_java_files_build_rel, ".", root_build_dir) 1188 _java_files = rebase_path(_java_files_build_rel, ".", root_build_dir)
1190 } 1189 }
1190 if (defined(invoker.java_files)) {
1191 _java_files += invoker.java_files
1192 }
1191 assert(_java_files != [] || _srcjar_deps != [] || _srcjars != []) 1193 assert(_java_files != [] || _srcjar_deps != [] || _srcjars != [])
1192 1194
1193 _compile_java_target = "${_template_name}__compile_java" 1195 _compile_java_target = "${_template_name}__compile_java"
1194 _final_deps += [ ":$_compile_java_target" ] 1196 _final_deps += [ ":$_compile_java_target" ]
1195 compile_java(_compile_java_target) { 1197 compile_java(_compile_java_target) {
1196 forward_variables_from(invoker, 1198 forward_variables_from(invoker,
1197 [ 1199 [
1198 "dist_jar_path", 1200 "dist_jar_path",
1199 "enable_errorprone", 1201 "enable_errorprone",
1200 "jar_excluded_patterns", 1202 "jar_excluded_patterns",
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after
1577 ] 1579 ]
1578 args = [ 1580 args = [
1579 "--depfile", 1581 "--depfile",
1580 rebase_path(depfile, root_build_dir), 1582 rebase_path(depfile, root_build_dir),
1581 "--script-output-path", 1583 "--script-output-path",
1582 rebase_path(generated_script, root_build_dir), 1584 rebase_path(generated_script, root_build_dir),
1583 ] 1585 ]
1584 args += test_runner_args 1586 args += test_runner_args
1585 } 1587 }
1586 } 1588 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698