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

Unified Diff: build/config/android/internal_rules.gni

Issue 1328823002: GN: Use interface jars in the classpath to speed up compiling (a little) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ijar2
Patch Set: .interface.jar Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/gyp/javac.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/android/internal_rules.gni
diff --git a/build/config/android/internal_rules.gni b/build/config/android/internal_rules.gni
index 76f3b3c89a70b75fe9aacfe9ff3525ae4eb9d6ea..f0050b0a9e96102b60e16179f06b688d6f5ddd9d 100644
--- a/build/config/android/internal_rules.gni
+++ b/build/config/android/internal_rules.gni
@@ -413,7 +413,8 @@ template("process_java_prebuilt") {
_input_jar_path = invoker.input_jar_path
_output_jar_path = invoker.output_jar_path
- _jar_toc_path = _output_jar_path + ".TOC"
+ _output_ijar_path = get_path_info(_output_jar_path, "dir") + "/" +
+ get_path_info(_output_jar_path, "name") + ".interface.jar"
assert(invoker.build_config != "")
@@ -477,10 +478,9 @@ template("process_java_prebuilt") {
}
}
- # TODO(agrieve): Change file extension to .ijar and use them in classpaths.
- generate_interface_jar("${target_name}__jar_toc") {
+ generate_interface_jar("${target_name}__ijar") {
input_jar = _output_jar_path
- output_jar = _jar_toc_path
+ output_jar = _output_ijar_path
deps = [
":$_output_jar_target",
]
@@ -489,7 +489,7 @@ template("process_java_prebuilt") {
group(target_name) {
forward_variables_from(invoker, [ "visibility" ])
public_deps = [
- ":${target_name}__jar_toc",
+ ":${target_name}__ijar",
":$_output_jar_target",
]
}
@@ -984,7 +984,7 @@ template("java_prebuilt_impl") {
#
# Outputs:
# $jar_path.jar
-# $jar_path.jar.TOC
+# $jar_path.interface.jar
#
# Variables
# java_files: List of .java files to compile.
@@ -1083,6 +1083,7 @@ template("compile_java") {
_rebased_depfile = rebase_path(depfile, root_build_dir)
args = [
"--depfile=$_rebased_depfile",
+ "--use-ijars",
"--classpath=@FileArg($_rebased_build_config:javac:classpath)",
"--jar-path=$_rebased_jar_path",
"--java-srcjars=$_rebased_java_srcjars",
@@ -1090,8 +1091,11 @@ template("compile_java") {
"--jar-excluded-classes=$_jar_excluded_patterns",
]
if (_supports_android) {
- _rebased_android_sdk_jar = rebase_path(android_sdk_jar, root_build_dir)
- args += [ "--bootclasspath=$_rebased_android_sdk_jar" ]
+ deps += [ "//build/android:android_ijar" ]
+ _android_sdk_ijar = "$root_out_dir/lib.java/android.interface.jar"
+ inputs += [ _android_sdk_ijar ]
+ _rebased_android_sdk_ijar = rebase_path(_android_sdk_ijar, root_build_dir)
+ args += [ "--bootclasspath=$_rebased_android_sdk_ijar" ]
}
foreach(e, _manifest_entries) {
args += [ "--manifest-entry=" + e ]
« no previous file with comments | « build/android/gyp/javac.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698