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

Unified Diff: build/secondary/third_party/android_tools/BUILD.gn

Issue 2156453002: Add AAR support to Chrome and convert support libraries to using AARs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert change in 3p/android_async_task/README.chromium Created 4 years, 5 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/config/android/rules.gni ('k') | chrome/android/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/secondary/third_party/android_tools/BUILD.gn
diff --git a/build/secondary/third_party/android_tools/BUILD.gn b/build/secondary/third_party/android_tools/BUILD.gn
index 2388ff9760cff7ec5cd769c10aa88d251d2860f4..daf758b462a8ba675029fdc289fbbfb277b7f083 100644
--- a/build/secondary/third_party/android_tools/BUILD.gn
+++ b/build/secondary/third_party/android_tools/BUILD.gn
@@ -32,6 +32,9 @@ source_set("cpu_features") {
]
}
+lib_version = "23.2.1"
+lib_path = "$android_sdk_root/extras/android/m2repository/com/android/support"
+
android_java_prebuilt("android_gcm_java") {
jar_path = "$android_sdk_root/extras/google/gcm/gcm-client/dist/gcm.jar"
}
@@ -40,77 +43,65 @@ android_java_prebuilt("emma_device") {
jar_path = "$android_sdk_root/tools/lib/emma_device.jar"
}
-android_resources("android_support_design_resources") {
- v14_skip = true
+android_aar_prebuilt("android_support_design_java") {
deps = [
- ":android_support_v7_appcompat_resources",
- ]
- resource_dirs = [ "$android_sdk_root/extras/android/support/design/res" ]
- custom_package = "android.support.design"
-}
-
-android_java_prebuilt("android_support_design_java") {
- deps = [
- ":android_support_design_resources",
+ ":android_support_v7_appcompat_java",
]
- jar_path = "$android_sdk_root/extras/android/support/design/libs/android-support-design.jar"
+ lib_name = "design"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
-java_prebuilt("android_support_multidex_java") {
- supports_android = true
- jar_path = "$android_sdk_root/extras/android/support/multidex/library/libs/android-support-multidex.jar"
+android_aar_prebuilt("android_support_multidex_java") {
+ # TODO(jbudorick): remove requires_android after crbug.com/522043 is fixed.
+ requires_android = false
+ aar_path = "$lib_path/multidex/1.0.1/multidex-1.0.1.aar"
}
-android_java_prebuilt("android_support_v13_java") {
- jar_path =
- "$android_sdk_root/extras/android/support/v13/android-support-v13.jar"
+android_java_prebuilt("android_support_annotations_java") {
+ lib_name = "support-annotations"
+ jar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.jar"
}
-android_resources("android_support_v7_appcompat_resources") {
- v14_skip = true
- resource_dirs =
- [ "$android_sdk_root/extras/android/support/v7/appcompat/res" ]
- custom_package = "android.support.v7.appcompat"
+android_aar_prebuilt("android_support_v4_java") {
+ lib_name = "support-v4"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
-android_java_prebuilt("android_support_v7_appcompat_java") {
+android_aar_prebuilt("android_support_v13_java") {
deps = [
- ":android_support_v7_appcompat_resources",
+ ":android_support_annotations_java",
+ ":android_support_v4_java",
]
- jar_path = "$android_sdk_root/extras/android/support/v7/appcompat/libs/android-support-v7-appcompat.jar"
+ lib_name = "support-v13"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
-android_resources("android_support_v7_mediarouter_resources") {
- v14_skip = true
- resource_dirs =
- [ "$android_sdk_root/extras/android/support/v7/mediarouter/res" ]
+android_aar_prebuilt("android_support_v7_appcompat_java_internal") {
+ lib_name = "appcompat-v7"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
+}
+
+java_group("android_support_v7_appcompat_java") {
deps = [
- ":android_support_v7_appcompat_resources",
+ ":android_support_v4_java",
+ ":android_support_v7_appcompat_java_internal",
]
- custom_package = "android.support.v7.mediarouter"
}
-android_java_prebuilt("android_support_v7_mediarouter_java") {
+android_aar_prebuilt("android_support_v7_mediarouter_java") {
deps = [
":android_support_v7_appcompat_java",
- ":android_support_v7_mediarouter_resources",
]
- jar_path = "$android_sdk_root/extras/android/support/v7/mediarouter/libs/android-support-v7-mediarouter.jar"
-}
-
-android_resources("android_support_v7_recyclerview_resources") {
- v14_skip = true
- resource_dirs =
- [ "$android_sdk_root/extras/android/support/v7/recyclerview/res" ]
- custom_package = "android.support.v7.recyclerview"
+ lib_name = "mediarouter-v7"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
-android_java_prebuilt("android_support_v7_recyclerview_java") {
+android_aar_prebuilt("android_support_v7_recyclerview_java") {
deps = [
":android_support_v7_appcompat_java",
- ":android_support_v7_recyclerview_resources",
]
- jar_path = "$android_sdk_root/extras/android/support/v7/recyclerview/libs/android-support-v7-recyclerview.jar"
+ lib_name = "recyclerview-v7"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
android_resources("google_play_services_default_resources") {
@@ -118,9 +109,11 @@ android_resources("google_play_services_default_resources") {
resource_dirs = [ "$android_sdk_root/extras/google/google_play_services/libproject/google-play-services_lib/res" ]
custom_package = "com.google.android.gms"
}
+
android_java_prebuilt("google_play_services_default_java") {
deps = [
- ":android_support_v13_java",
+ ":android_support_annotations_java",
+ ":android_support_v4_java",
":android_support_v7_mediarouter_java",
":google_play_services_default_resources",
]
@@ -130,19 +123,12 @@ android_java_prebuilt("google_play_services_default_java") {
jar_path = "$android_sdk_root/extras/google/google_play_services/libproject/google-play-services_lib/libs/google-play-services.jar"
}
-android_resources("android_support_v17_leanback_resources") {
- v14_skip = true
- resource_dirs =
- [ "$android_sdk_root/extras/android/support/v17/leanback/res" ]
- custom_package = "android.support.v17.leanback"
-}
-
-android_java_prebuilt("android_support_v17_leanback_java") {
+android_aar_prebuilt("android_support_v17_leanback_java") {
deps = [
- ":android_support_v17_leanback_resources",
":android_support_v7_recyclerview_java",
]
- jar_path = "$android_sdk_root/extras/android/support/v17/leanback/libs/android-support-v17-leanback.jar"
+ lib_name = "leanback-v17"
+ aar_path = "$lib_path/$lib_name/$lib_version/$lib_name-$lib_version.aar"
}
# TODO(jbudorick): Remove this once net_java_test_support no longer needs it.
« no previous file with comments | « build/config/android/rules.gni ('k') | chrome/android/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698