blob: ddb6b939e40210045fc53757703606438ac51a0e [file] [log] [blame]
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -07001// Copyright (C) 2018 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
Bob Badour4bdf3802021-02-12 17:08:17 -080015package {
16 default_applicable_licenses: ["packages_apps_Launcher3_license"],
17}
18
Sunny Goyal1fb271f2021-05-20 10:43:23 -070019min_launcher3_sdk_version = "26"
20
Bob Badour4bdf3802021-02-12 17:08:17 -080021// Added automatically by a large-scale-change
22// See: http://go/android-license-faq
23license {
24 name: "packages_apps_Launcher3_license",
25 visibility: [":__subpackages__"],
26 license_kinds: [
27 "SPDX-license-identifier-Apache-2.0",
28 ],
29 license_text: [
30 "NOTICE",
31 ],
32}
33
vadimt09df0832019-03-07 14:59:30 -080034android_library {
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070035 name: "launcher-aosp-tapl",
Thiru Ramasamyd495e8c2021-08-26 10:37:17 -070036 libs: [
37 "framework-statsd",
38 ],
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070039 static_libs: [
40 "androidx.annotation_annotation",
Brett Chabotd7d692c2018-10-23 21:17:58 -070041 "androidx.test.runner",
42 "androidx.test.rules",
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070043 "androidx.test.uiautomator_uiautomator",
Hyunyoung Songbb715822020-08-04 10:45:53 -070044 "androidx.preference_preference",
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070045 "SystemUISharedLib",
46 ],
47 srcs: [
48 "tests/tapl/**/*.java",
vadimt1b383af2019-05-08 15:29:37 -070049 "src/com/android/launcher3/ResourceUtils.java",
Sunny Goyalab3963d2019-05-23 00:50:08 -070050 "src/com/android/launcher3/testing/TestProtocol.java",
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070051 ],
Sunny Goyal572aca42021-03-24 15:21:39 -070052 resource_dirs: [ ],
vadimt09df0832019-03-07 14:59:30 -080053 manifest: "tests/tapl/AndroidManifest.xml",
Hyunyoung Songda4fcfe2018-09-05 09:57:59 -070054 platform_apis: true,
55}
thiruram5e1ecf62019-11-13 17:49:35 -080056
57java_library_static {
thiruramc1c2bfa2020-02-04 18:56:40 -080058 name: "launcher_log_protos_lite",
thiruram5e1ecf62019-11-13 17:49:35 -080059 srcs: [
60 "protos/*.proto",
thiruramcbeb13d2021-01-27 14:45:58 -080061 "protos_overrides/*.proto",
thiruram5e1ecf62019-11-13 17:49:35 -080062 ],
63 sdk_version: "current",
64 proto: {
65 type: "lite",
66 local_include_dirs:[
67 "protos",
thiruramcbeb13d2021-01-27 14:45:58 -080068 "protos_overrides",
thiruram5e1ecf62019-11-13 17:49:35 -080069 ],
70 },
thiruramc1c2bfa2020-02-04 18:56:40 -080071 static_libs: ["libprotobuf-java-lite"],
thiruram5e1ecf62019-11-13 17:49:35 -080072}
Hyunyoung Song8605be32020-02-21 14:52:25 -080073
thiruramcbeb13d2021-01-27 14:45:58 -080074java_library_static {
75 name: "launcher_quickstep_log_protos_lite",
76 srcs: [
77 "quickstep/protos_overrides/*.proto",
78 ],
79 sdk_version: "current",
80 proto: {
81 type: "lite",
82 local_include_dirs:[
83 "quickstep/protos_overrides",
84 ],
85 },
86 static_libs: [
87 "libprotobuf-java-lite",
88 "launcher_log_protos_lite"
89 ],
90}
91
Hyunyoung Song8605be32020-02-21 14:52:25 -080092java_library {
93 name: "LauncherPluginLib",
94
95 static_libs: ["PluginCoreLib"],
96
97 srcs: ["src_plugins/**/*.java"],
98
99 sdk_version: "current",
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700100 min_sdk_version: min_launcher3_sdk_version,
Hyunyoung Song8605be32020-02-21 14:52:25 -0800101}
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800102
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800103// Library with all the dependencies for building Launcher3
104android_library {
105 name: "Launcher3ResLib",
106 srcs: [ ],
107 resource_dirs: ["res"],
108 static_libs: [
109 "LauncherPluginLib",
110 "launcher_quickstep_log_protos_lite",
111 "androidx-constraintlayout_constraintlayout",
112 "androidx.recyclerview_recyclerview",
113 "androidx.dynamicanimation_dynamicanimation",
114 "androidx.fragment_fragment",
115 "androidx.preference_preference",
116 "androidx.slice_slice-view",
117 "androidx.cardview_cardview",
Brian Isganitis93031bc2021-06-09 16:34:45 -0400118 "com.google.android.material_material",
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800119 "iconloader_base",
120 ],
121 manifest: "AndroidManifest-common.xml",
122 sdk_version: "current",
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700123 min_sdk_version: min_launcher3_sdk_version,
Pedro Loureiro1e296c12021-03-09 18:35:52 +0000124 lint: {
125 baseline_filename: "lint-baseline-res-lib.xml",
126 },
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800127}
128
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800129//
130// Build rule for Launcher3 dependencies lib.
131//
132android_library {
133 name: "Launcher3CommonDepsLib",
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800134 srcs: ["src_build_config/**/*.java"],
135 static_libs: ["Launcher3ResLib"],
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800136 sdk_version: "current",
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700137 min_sdk_version: min_launcher3_sdk_version,
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800138 manifest: "AndroidManifest-common.xml",
Pedro Loureiro1e296c12021-03-09 18:35:52 +0000139 lint: {
140 baseline_filename: "lint-baseline-common-deps-lib.xml",
141 },
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800142}
143
144//
145// Build rule for Launcher3 app.
146//
147android_app {
148 name: "Launcher3",
149
150 static_libs: [
151 "Launcher3CommonDepsLib",
152 ],
153 srcs: [
154 "src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100155 "src/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800156 "src_shortcuts_overrides/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100157 "src_shortcuts_overrides/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800158 "src_ui_overrides/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100159 "src_ui_overrides/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800160 "ext_tests/src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100161 "ext_tests/src/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800162 ],
163 resource_dirs: [
164 "ext_tests/res",
165 ],
166 optimize: {
167 proguard_flags_files: ["proguard.flags"],
168 // Proguard is disable for testing. Derivarive prjects to keep proguard enabled
169 enabled: false,
170 },
171
172 sdk_version: "current",
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700173 min_sdk_version: min_launcher3_sdk_version,
174 target_sdk_version: "current",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800175 privileged: true,
176 system_ext_specific: true,
177
178 overrides: [
179 "Home",
180 "Launcher2",
181 ],
182 required: ["privapp_whitelist_com.android.launcher3"],
183
184 jacoco: {
185 include_filter: ["com.android.launcher3.**"],
186 },
187 additional_manifests: [
188 "AndroidManifest-common.xml",
189 ],
Pedro Loureiro1e296c12021-03-09 18:35:52 +0000190 lint: {
191 baseline_filename: "lint-baseline-launcher3.xml",
192 },
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800193}
194
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800195// Library with all the dependencies for building quickstep
196android_library {
197 name: "QuickstepResLib",
198 srcs: [ ],
199 resource_dirs: [
200 "quickstep/res",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800201 ],
Thiru Ramasamyd495e8c2021-08-26 10:37:17 -0700202 libs: [
203 "framework-statsd",
204 ],
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800205 static_libs: [
206 "Launcher3ResLib",
Schneider Victor-tuliasd0865f82021-11-09 13:19:21 -0800207 "lottie",
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800208 "SystemUISharedLib",
209 "SystemUI-statsd",
210 ],
211 manifest: "quickstep/AndroidManifest.xml",
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700212 min_sdk_version: "current",
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800213}
214
215
216// Source code used for test helpers
217filegroup {
218 name: "launcher-src-ext-tests",
Thales Lima26f44912021-10-21 15:34:28 +0100219 srcs: [
220 "ext_tests/src/**/*.java",
221 "ext_tests/src/**/*.kt",
222 ],
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800223}
224
225// Common source files used to build launcher
226filegroup {
227 name: "launcher-src-no-build-config",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800228 srcs: [
229 "src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100230 "src/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800231 "src_shortcuts_overrides/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100232 "src_shortcuts_overrides/**/*.kt",
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800233 "quickstep/src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100234 "quickstep/src/**/*.kt",
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800235 ],
Sunny Goyalf5c42ea2021-03-12 16:00:40 -0800236}
237
238// Proguard files for Launcher3
239filegroup {
240 name: "launcher-proguard-rules",
241 srcs: ["proguard.flags"],
Hyunyoung Song5a007fe2021-02-25 00:58:05 -0800242}
Jon Spivacka65d68b2021-04-07 10:22:25 -0700243
Jon Spivacka65d68b2021-04-07 10:22:25 -0700244// Library with all the dependencies for building Launcher Go
245android_library {
246 name: "LauncherGoResLib",
247 srcs: [
248 "src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100249 "src/**/*.kt",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700250 "quickstep/src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100251 "quickstep/src/**/*.kt",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700252 "go/src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100253 "go/src/**/*.kt",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700254 "go/quickstep/src/**/*.java",
Thales Lima26f44912021-10-21 15:34:28 +0100255 "go/quickstep/src/**/*.kt",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700256 ],
257 resource_dirs: [
258 "go/res",
259 "go/quickstep/res",
260 ],
261 static_libs: [
Greg Kaiser6f220d92021-11-05 16:12:47 +0000262 "Launcher3CommonDepsLib",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700263 "QuickstepResLib",
Jon Spivack89c21c72021-08-13 13:18:24 -0700264 "androidx.room_room-runtime",
Jon Spivacka65d68b2021-04-07 10:22:25 -0700265 ],
Jon Spivack89c21c72021-08-13 13:18:24 -0700266 plugins: ["androidx.room_room-compiler-plugin"],
Jon Spivacka65d68b2021-04-07 10:22:25 -0700267 manifest: "quickstep/AndroidManifest-launcher.xml",
268 additional_manifests: [
269 "go/AndroidManifest.xml",
270 "AndroidManifest-common.xml",
271 ],
Sunny Goyal1fb271f2021-05-20 10:43:23 -0700272 min_sdk_version: "current",
Pedro Loureiro1e296c12021-03-09 18:35:52 +0000273 lint: {
274 baseline_filename: "lint-baseline-go-res-lib.xml",
275 },
Jon Spivacka65d68b2021-04-07 10:22:25 -0700276}
277
Sunny Goyal4af8cf92021-07-29 15:48:24 -0700278// Build rule for Quickstep library
279android_library {
280 name: "Launcher3QuickStepLib",
281 srcs: [
282 ":launcher-src-no-build-config",
283 ],
Thales Limac335ad22021-11-08 15:31:49 +0000284 resource_dirs: [],
Thiru Ramasamyd495e8c2021-08-26 10:37:17 -0700285 libs: [
286 "framework-statsd",
287 ],
Sunny Goyal4af8cf92021-07-29 15:48:24 -0700288 static_libs: [
Thales Limac335ad22021-11-08 15:31:49 +0000289 "QuickstepResLib",
Sunny Goyal4af8cf92021-07-29 15:48:24 -0700290 "SystemUI-statsd",
291 "SystemUISharedLib",
Thales Limac335ad22021-11-08 15:31:49 +0000292 "Launcher3CommonDepsLib",
Sunny Goyal4af8cf92021-07-29 15:48:24 -0700293 ],
294 manifest: "quickstep/AndroidManifest.xml",
295 platform_apis: true,
296 min_sdk_version: "current",
297 lint: {
298 baseline_filename: "lint-baseline-launcher3.xml",
299 },
300}