blob: c4f7bac45e11e5d317866c15da97bc278206e81e [file] [log] [blame]
Jason Monka2f2d822018-08-13 11:10:48 -04001//
2// Copyright (C) 2018 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
Bob Badour8a6a2bc2021-02-12 17:07:05 -080017package {
Aditya Choudharyb4262272024-01-31 11:09:29 +000018 default_team: "trendy_team_system_ui_please_use_a_more_specific_subteam_if_possible_",
Bob Badour8a6a2bc2021-02-12 17:07:05 -080019 default_applicable_licenses: ["frameworks_base_packages_SystemUI_license"],
20}
21
22// Added automatically by a large-scale-change
23// See: http://go/android-license-faq
24license {
25 name: "frameworks_base_packages_SystemUI_license",
26 visibility: [":__subpackages__"],
27 license_kinds: [
28 "SPDX-license-identifier-Apache-2.0",
29 ],
30 license_text: [
31 "NOTICE",
32 ],
33}
34
Jordan Demeulenaere68e91822022-12-16 10:55:47 +010035// Opt-in configuration for code depending on Jetpack Compose.
36soong_config_module_type {
37 name: "systemui_compose_java_defaults",
38 module_type: "java_defaults",
39 config_namespace: "ANDROID",
40 bool_variables: ["SYSTEMUI_USE_COMPOSE"],
41 properties: [
42 "srcs",
43 "static_libs",
44 ],
45}
46
47systemui_compose_java_defaults {
48 name: "SystemUI_compose_defaults",
49 soong_config_variables: {
50 SYSTEMUI_USE_COMPOSE: {
51 // Because files in compose/features/ depend on SystemUI
52 // code, we compile those files when compiling SystemUI-core.
53 // We also compile the ComposeFacade in
54 // compose/facade/enabled/.
55 srcs: [
56 "compose/features/src/**/*.kt",
57 "compose/facade/enabled/src/**/*.kt",
58 ],
59
60 // The dependencies needed by SystemUIComposeFeatures,
61 // except for SystemUI-core.
62 // Copied from compose/features/Android.bp.
63 static_libs: [
Jordan Demeulenaere8a1747d2022-12-28 11:11:42 +010064 "PlatformComposeCore",
Jordan Demeulenaere68e91822022-12-16 10:55:47 +010065
66 "androidx.compose.runtime_runtime",
67 "androidx.compose.material3_material3",
Jordan Demeulenaerebf43b1d2022-12-16 13:00:23 +010068 "androidx.activity_activity-compose",
Jordan Demeulenaere0bbebad2023-07-06 10:19:49 +020069 "androidx.compose.animation_animation-graphics",
Jordan Demeulenaere68e91822022-12-16 10:55:47 +010070 ],
71
72 // By default, Compose is disabled and we compile the ComposeFacade
73 // in compose/facade/disabled/.
74 conditions_default: {
75 srcs: ["compose/facade/disabled/src/**/*.kt"],
76 static_libs: [],
77 },
78 },
79 },
80}
81
Jason Monka2f2d822018-08-13 11:10:48 -040082java_library {
83 name: "SystemUI-proto",
84
85 srcs: ["src/**/*.proto"],
86
87 proto: {
88 type: "nano",
89 },
Winson Chungeb1aa3d2020-08-25 19:02:29 -070090
91 libs: [
92 "WindowManager-Shell-proto",
93 ],
Jason Monka2f2d822018-08-13 11:10:48 -040094}
95
96java_library {
97 name: "SystemUI-tags",
98 srcs: ["src/com/android/systemui/EventLogTags.logtags"],
99}
100
Jay Aliomer97d4fc7d2021-09-23 16:59:09 -0400101filegroup {
102 name: "ReleaseJavaFiles",
Jeff DeCew86b8e772021-10-25 20:35:45 -0400103 srcs: [
104 "src-release/**/*.kt",
105 "src-release/**/*.java",
106 ],
Jay Aliomer97d4fc7d2021-09-23 16:59:09 -0400107}
108
109filegroup {
110 name: "DebugJavaFiles",
Jeff DeCew86b8e772021-10-25 20:35:45 -0400111 srcs: [
112 "src-debug/**/*.kt",
113 "src-debug/**/*.java",
114 ],
Jay Aliomer97d4fc7d2021-09-23 16:59:09 -0400115}
116
Xiaozhen Lin53063042022-11-23 02:18:08 +0000117//Create a library to expose SystemUI's resources to other modules.
118android_library {
119 name: "SystemUI-res",
120 resource_dirs: [
121 "res-product",
122 "res-keyguard",
123 "res",
124 ],
125 static_libs: [
126 "SystemUISharedLib",
Hawkwood Glazier057df3a2023-06-14 20:10:21 +0000127 "SystemUICustomizationLib",
Xiaozhen Lin53063042022-11-23 02:18:08 +0000128 "SettingsLib",
129 "androidx.leanback_leanback",
130 "androidx.slice_slice-core",
131 "androidx.slice_slice-view",
132 ],
133 manifest: "AndroidManifest-res.xml",
134}
135
Jason Monka2f2d822018-08-13 11:10:48 -0400136android_library {
137 name: "SystemUI-core",
Jordan Demeulenaere68e91822022-12-16 10:55:47 +0100138 defaults: [
139 "SystemUI_compose_defaults",
140 ],
Jason Monka2f2d822018-08-13 11:10:48 -0400141 srcs: [
Jason Monkae7ced22018-08-22 16:56:58 -0400142 "src/**/*.kt",
Jason Monka2f2d822018-08-13 11:10:48 -0400143 "src/**/*.java",
144 "src/**/I*.aidl",
Dave Mankoff72a50022021-11-02 20:44:54 -0400145 ":ReleaseJavaFiles",
Jason Monka2f2d822018-08-13 11:10:48 -0400146 ],
Jay Aliomer97d4fc7d2021-09-23 16:59:09 -0400147 product_variables: {
148 debuggable: {
149 srcs: [":DebugJavaFiles"],
150 exclude_srcs: [":ReleaseJavaFiles"],
151 },
152 },
Jason Monka2f2d822018-08-13 11:10:48 -0400153 resource_dirs: [
Sunny Goyalb4a26012019-12-05 15:49:41 -0800154 "res-product",
Jason Monka2f2d822018-08-13 11:10:48 -0400155 "res-keyguard",
156 "res",
157 ],
Colin Crossc23cde42023-06-21 11:22:11 -0700158 use_resource_processor: true,
Jason Monka2f2d822018-08-13 11:10:48 -0400159 static_libs: [
Quang Luongc6fc5b22021-06-10 14:35:32 -0700160 "WifiTrackerLib",
Winson Chung10a9b4b2019-12-18 10:01:36 -0800161 "WindowManager-Shell",
Jordan Demeulenaerecea62bb2021-04-08 11:04:50 +0200162 "SystemUIAnimationLib",
Darrell Shi60006322023-04-06 17:58:40 +0000163 "SystemUICommon",
164 "SystemUICustomizationLib",
Darrell Shi1a21b362023-04-28 19:51:44 +0000165 "SystemUILogLib",
Jason Monka2f2d822018-08-13 11:10:48 -0400166 "SystemUIPluginLib",
167 "SystemUISharedLib",
Jerry Chang919d1d22020-07-16 12:31:24 +0800168 "SystemUI-statsd",
Jason Monka2f2d822018-08-13 11:10:48 -0400169 "SettingsLib",
Alejandro Nijamkin38859642022-06-27 14:18:17 -0700170 "androidx.core_core-ktx",
Fabian Kozynski713b7272020-03-03 18:35:52 -0500171 "androidx.viewpager2_viewpager2",
Jason Monka2f2d822018-08-13 11:10:48 -0400172 "androidx.legacy_legacy-support-v4",
173 "androidx.recyclerview_recyclerview",
174 "androidx.preference_preference",
175 "androidx.appcompat_appcompat",
Mark Renoufe2395012020-12-16 01:05:12 -0500176 "androidx.concurrent_concurrent-futures",
Jason Monka2f2d822018-08-13 11:10:48 -0400177 "androidx.mediarouter_mediarouter",
178 "androidx.palette_palette",
179 "androidx.legacy_legacy-preference-v14",
180 "androidx.leanback_leanback",
181 "androidx.slice_slice-core",
182 "androidx.slice_slice-view",
183 "androidx.slice_slice-builders",
184 "androidx.arch.core_core-runtime",
Bryce Lee436e42c2022-01-24 14:53:49 -0800185 "androidx.lifecycle_lifecycle-common-java8",
Jason Monka2f2d822018-08-13 11:10:48 -0400186 "androidx.lifecycle_lifecycle-extensions",
Jordan Demeulenaere8a169ff2022-07-13 10:42:10 +0200187 "androidx.lifecycle_lifecycle-runtime-ktx",
Joshua Tsujib1a796b2019-01-16 15:43:12 -0800188 "androidx.dynamicanimation_dynamicanimation",
Steve Elliott300b48f2019-05-29 14:13:50 -0400189 "androidx-constraintlayout_constraintlayout",
Miranda Kepharte1a22b92020-12-16 14:01:12 -0500190 "androidx.exifinterface_exifinterface",
Lucas Dupin00c1a602022-02-16 16:40:36 -0800191 "com.google.android.material_material",
Steve Elliotta7d72052020-12-16 23:04:19 -0500192 "kotlinx_coroutines_android",
193 "kotlinx_coroutines",
Hyunyoung Song5347a542019-03-01 13:32:28 -0800194 "iconloader_base",
Jason Monka2f2d822018-08-13 11:10:48 -0400195 "SystemUI-tags",
196 "SystemUI-proto",
Lucas Dupine37369f2021-08-31 00:19:39 +0000197 "monet",
Lucas Dupind83b4ee2023-07-08 11:05:47 -0700198 "libmonet",
Dave Mankoffdffcc472020-07-08 15:25:16 -0400199 "dagger2",
Brett Chabotfc8675a2023-03-27 10:33:10 -0700200 "jsr305",
Andy Wickham64e34102021-03-07 16:02:01 -0800201 "jsr330",
Beverly46817e12021-06-22 16:29:52 -0400202 "lottie",
Lucas Silva0bfb4052022-09-20 23:32:02 -0400203 "LowLightDreamLib",
Johannes Gallmann0d5183c2022-10-04 13:32:16 +0000204 "motion_tool_lib",
Jason Monka2f2d822018-08-13 11:10:48 -0400205 ],
206 manifest: "AndroidManifest.xml",
207
Kevin Jeonf2e72182022-04-04 19:05:05 +0000208 javacflags: ["-Adagger.fastInit=enabled"],
Colin Cross6954ea72023-07-18 10:52:21 -0700209 kotlincflags: ["-Xjvm-default=all"],
Jason Monk73e8ffc2018-12-06 14:45:19 -0500210
Dave Mankoffdffcc472020-07-08 15:25:16 -0400211 plugins: ["dagger2-compiler"],
Jernej Viragbb4ff3f2022-03-10 17:52:11 +0000212
213 lint: {
214 extra_check_modules: ["SystemUILintChecker"],
215 },
Zi Wang337b89a2024-03-06 11:39:13 -0800216 skip_jarjar_repackage: true,
Jason Monka2f2d822018-08-13 11:10:48 -0400217}
218
Tadashi G. Takaokaa6572dc2019-09-17 15:18:53 +0900219filegroup {
Fabian Kozynskid389df52022-01-06 10:52:51 -0500220 name: "AAA-src",
221 srcs: ["tests/src/com/android/AAAPlusPlusVerifySysuiRequiredTestPropertiesTest.java"],
222 path: "tests/src",
223}
224
225filegroup {
Tadashi G. Takaokaa6572dc2019-09-17 15:18:53 +0900226 name: "SystemUI-tests-utils",
227 srcs: [
Jordan Demeulenaeref7fed3c2022-07-28 18:06:49 +0200228 "tests/utils/src/**/*.java",
229 "tests/utils/src/**/*.kt",
Dave Mankoffb4935a22021-06-01 15:12:15 -0400230 ],
Jordan Demeulenaeref7fed3c2022-07-28 18:06:49 +0200231 path: "tests/utils/src",
Tadashi G. Takaokaa6572dc2019-09-17 15:18:53 +0900232}
233
Kevin Liud3793232023-02-09 20:37:27 +0000234filegroup {
Caitlin Shkuratovd3777bd2023-07-18 21:39:33 +0000235 name: "SystemUI-test-fakes",
236 srcs: [
237 /* Status bar fakes */
238 "tests/src/com/android/systemui/statusbar/pipeline/airplane/data/repository/FakeAirplaneModeRepository.kt",
239 "tests/src/com/android/systemui/statusbar/pipeline/shared/data/repository/FakeConnectivityRepository.kt",
240 "tests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/FakeWifiRepository.kt",
241 ],
242 path: "tests/src",
243}
244
245filegroup {
Kevin Liud3793232023-02-09 20:37:27 +0000246 name: "SystemUI-tests-robolectric-pilots",
247 srcs: [
Kevin Liuc54db8b2023-03-22 21:41:46 +0000248 /* Keyguard converted tests */
Kevin Liud3793232023-02-09 20:37:27 +0000249 // data
250 "tests/src/com/android/systemui/keyguard/data/quickaffordance/CameraQuickAffordanceConfigTest.kt",
251 "tests/src/com/android/systemui/keyguard/data/quickaffordance/DoNotDisturbQuickAffordanceConfigTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000252 "tests/src/com/android/systemui/keyguard/data/quickaffordance/FlashlightQuickAffordanceConfigTest.kt",
253 "tests/src/com/android/systemui/keyguard/data/quickaffordance/HomeControlsKeyguardQuickAffordanceConfigTest.kt",
254 "tests/src/com/android/systemui/keyguard/data/quickaffordance/KeyguardQuickAffordanceLegacySettingSyncerTest.kt",
255 "tests/src/com/android/systemui/keyguard/data/quickaffordance/KeyguardQuickAffordanceLocalUserSelectionManagerTest.kt",
256 "tests/src/com/android/systemui/keyguard/data/quickaffordance/KeyguardQuickAffordanceRemoteUserSelectionManagerTest.kt",
Kevin Liuc54db8b2023-03-22 21:41:46 +0000257 "tests/src/com/android/systemui/keyguard/data/quickaffordance/MuteQuickAffordanceConfigTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000258 "tests/src/com/android/systemui/keyguard/data/quickaffordance/QrCodeScannerKeyguardQuickAffordanceConfigTest.kt",
259 "tests/src/com/android/systemui/keyguard/data/quickaffordance/QuickAccessWalletKeyguardQuickAffordanceConfigTest.kt",
Kevin Liuc54db8b2023-03-22 21:41:46 +0000260 "tests/src/com/android/systemui/keyguard/data/quickaffordance/VideoCameraQuickAffordanceConfigTest.kt",
261 "tests/src/com/android/systemui/keyguard/data/repository/BiometricSettingsRepositoryTest.kt",
262 "tests/src/com/android/systemui/keyguard/data/repository/DeviceEntryFaceAuthRepositoryTest.kt",
263 "tests/src/com/android/systemui/keyguard/data/repository/DeviceEntryFingerprintAuthRepositoryTest.kt",
264 "tests/src/com/android/systemui/keyguard/data/repository/DevicePostureRepositoryTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000265 "tests/src/com/android/systemui/keyguard/data/repository/KeyguardQuickAffordanceRepositoryTest.kt",
266 "tests/src/com/android/systemui/keyguard/data/repository/KeyguardRepositoryImplTest.kt",
Kevin Liuc54db8b2023-03-22 21:41:46 +0000267 "tests/src/com/android/systemui/keyguard/data/repository/LightRevealScrimRepositoryTest.kt",
268 "tests/src/com/android/systemui/keyguard/data/repository/TrustRepositoryTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000269 // domain
Aaron Liu8456c412023-05-31 11:12:55 -0700270 "tests/src/com/android/systemui/bouncer/domain/interactor/AlternateBouncerInteractorTest.kt",
271 "tests/src/com/android/systemui/bouncer/domain/interactor/PrimaryBouncerCallbackInteractorTest.kt",
272 "tests/src/com/android/systemui/bouncer/domain/interactor/PrimaryBouncerInteractorWithCoroutinesTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000273 "tests/src/com/android/systemui/keyguard/domain/interactor/KeyguardInteractorTest.kt",
Kevin Liu810fcbb2023-04-24 22:33:07 +0000274 "tests/src/com/android/systemui/keyguard/domain/interactor/KeyguardLongPressInteractorTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000275 "tests/src/com/android/systemui/keyguard/domain/interactor/KeyguardQuickAffordanceInteractorTest.kt",
276 "tests/src/com/android/systemui/keyguard/domain/interactor/KeyguardTransitionInteractorTest.kt",
277 "tests/src/com/android/systemui/keyguard/domain/interactor/LightRevealScrimInteractorTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000278 // ui
Aaron Liu8456c412023-05-31 11:12:55 -0700279 "tests/src/com/android/systemui/bouncer/ui/viewmodel/KeyguardBouncerViewModelTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000280 "tests/src/com/android/systemui/keyguard/ui/viewmodel/DreamingToLockscreenTransitionViewModelTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000281 "tests/src/com/android/systemui/keyguard/ui/viewmodel/GoneToDreamingTransitionViewModelTest.kt",
282 "tests/src/com/android/systemui/keyguard/ui/viewmodel/LockscreenToDreamingTransitionViewModelTest.kt",
283 "tests/src/com/android/systemui/keyguard/ui/viewmodel/LockscreenToOccludedTransitionViewModelTest.kt",
284 "tests/src/com/android/systemui/keyguard/ui/viewmodel/OccludedToLockscreenTransitionViewModelTest.kt",
Kevin Liu810fcbb2023-04-24 22:33:07 +0000285 "tests/src/com/android/systemui/keyguard/ui/viewmodel/PrimaryBouncerToGoneTransitionViewModelTest.kt",
Kevin Liuc54db8b2023-03-22 21:41:46 +0000286 // Keyguard helper
287 "tests/src/com/android/systemui/keyguard/data/quickaffordance/FakeKeyguardQuickAffordanceConfig.kt",
Brad Hinegardner5094a5d2023-04-25 16:28:45 -0400288 "tests/src/com/android/systemui/dock/DockManagerFake.java",
Kevin Liuc54db8b2023-03-22 21:41:46 +0000289 "tests/src/com/android/systemui/dump/LogBufferHelper.kt",
290 "tests/src/com/android/systemui/statusbar/phone/FakeKeyguardStateController.java",
Kevin Liu092b8212023-02-15 05:42:34 +0000291
Kevin Liuc54db8b2023-03-22 21:41:46 +0000292 /* Biometric converted tests */
Kevin Liu092b8212023-02-15 05:42:34 +0000293 "tests/src/com/android/systemui/biometrics/BiometricTestExtensions.kt",
294 "tests/src/com/android/systemui/biometrics/AuthBiometricFingerprintAndFaceViewTest.kt",
295 "tests/src/com/android/systemui/biometrics/AuthBiometricFingerprintViewTest.kt",
296 "tests/src/com/android/systemui/biometrics/AuthControllerTest.java",
297 "tests/src/com/android/systemui/biometrics/BiometricDisplayListenerTest.java",
298 "tests/src/com/android/systemui/biometrics/FaceHelpMessageDeferralTest.kt",
299 "tests/src/com/android/systemui/biometrics/SideFpsControllerTest.kt",
300 "tests/src/com/android/systemui/biometrics/UdfpsControllerOverlayTest.kt",
301 "tests/src/com/android/systemui/biometrics/UdfpsControllerTest.java",
302 "tests/src/com/android/systemui/biometrics/UdfpsDialogMeasureAdapterTest.java",
303 "tests/src/com/android/systemui/biometrics/UdfpsDisplayModeTest.java",
Beverlyea7325c2023-05-03 13:49:09 +0000304 "tests/src/com/android/systemui/biometrics/UdfpsKeyguardViewLegacyControllerBaseTest.java",
305 "tests/src/com/android/systemui/biometrics/UdfpsKeyguardViewLegacyControllerTest.java",
306 "tests/src/com/android/systemui/biometrics/UdfpsKeyguardViewLegacyControllerWithCoroutinesTest.kt",
Kevin Liu092b8212023-02-15 05:42:34 +0000307 "tests/src/com/android/systemui/biometrics/UdfpsShellTest.kt",
308 "tests/src/com/android/systemui/biometrics/UdfpsViewTest.kt",
Caitlin Shkuratovd3777bd2023-07-18 21:39:33 +0000309
310 /* Status bar wifi converted tests */
311 "tests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/WifiRepositorySwitcherTest.kt",
312 "tests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/prod/DisabledWifiRepositoryTest.kt",
313 "tests/src/com/android/systemui/statusbar/pipeline/wifi/data/repository/prod/WifiRepositoryImplTest.kt",
Caitlin Shkuratove0ed29452023-07-20 13:26:29 +0000314 "tests/src/com/android/systemui/statusbar/pipeline/wifi/domain/interactor/WifiInteractorImplTest.kt",
Caitlin Shkuratov87d86642023-07-20 14:49:28 +0000315 "tests/src/com/android/systemui/statusbar/pipeline/wifi/ui/viewmodel/WifiViewModelTest.kt",
Kevin Liud3793232023-02-09 20:37:27 +0000316 ],
317 path: "tests/src",
318}
319
Bryce Leea5b08082021-10-06 11:34:56 -0700320java_library {
321 name: "SystemUI-tests-concurrency",
322 srcs: [
323 "src/com/android/systemui/util/concurrency/DelayableExecutor.java",
324 "src/com/android/systemui/util/time/SystemClock.java",
Jordan Demeulenaeref7fed3c2022-07-28 18:06:49 +0200325 "tests/utils/src/com/android/systemui/util/concurrency/FakeExecutor.java",
326 "tests/utils/src/com/android/systemui/util/time/FakeSystemClock.java",
Bryce Leea5b08082021-10-06 11:34:56 -0700327 ],
328 jarjar_rules: ":jarjar-rules-shared",
329}
330
Jason Monkae7ced22018-08-22 16:56:58 -0400331android_library {
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000332 name: "SystemUI-tests-base",
Sunny Goyaleb18d392020-02-07 16:48:14 -0800333 manifest: "tests/AndroidManifest-base.xml",
Jason Monkae7ced22018-08-22 16:56:58 -0400334 resource_dirs: [
335 "tests/res",
Sunny Goyalb4a26012019-12-05 15:49:41 -0800336 "res-product",
Jason Monkae7ced22018-08-22 16:56:58 -0400337 "res-keyguard",
338 "res",
339 ],
Jason Monkae7ced22018-08-22 16:56:58 -0400340 static_libs: [
Quang Luongc6fc5b22021-06-10 14:35:32 -0700341 "WifiTrackerLib",
Jordan Demeulenaerecea62bb2021-04-08 11:04:50 +0200342 "SystemUIAnimationLib",
Jason Monkae7ced22018-08-22 16:56:58 -0400343 "SystemUIPluginLib",
344 "SystemUISharedLib",
Hawkwood Glazierb8eef872022-11-11 17:56:14 +0000345 "SystemUICustomizationLib",
Hyunyoung Song3d89c932020-04-11 13:31:06 -0700346 "SystemUI-statsd",
Jason Monkae7ced22018-08-22 16:56:58 -0400347 "SettingsLib",
Fabian Kozynski713b7272020-03-03 18:35:52 -0500348 "androidx.viewpager2_viewpager2",
Jason Monkae7ced22018-08-22 16:56:58 -0400349 "androidx.legacy_legacy-support-v4",
350 "androidx.recyclerview_recyclerview",
351 "androidx.preference_preference",
352 "androidx.appcompat_appcompat",
Mark Renoufe2395012020-12-16 01:05:12 -0500353 "androidx.concurrent_concurrent-futures",
Jason Monkae7ced22018-08-22 16:56:58 -0400354 "androidx.mediarouter_mediarouter",
355 "androidx.palette_palette",
356 "androidx.legacy_legacy-preference-v14",
357 "androidx.leanback_leanback",
358 "androidx.slice_slice-core",
359 "androidx.slice_slice-view",
360 "androidx.slice_slice-builders",
361 "androidx.arch.core_core-runtime",
Bryce Lee436e42c2022-01-24 14:53:49 -0800362 "androidx.lifecycle_lifecycle-common-java8",
Jason Monkae7ced22018-08-22 16:56:58 -0400363 "androidx.lifecycle_lifecycle-extensions",
Jordan Demeulenaere8a169ff2022-07-13 10:42:10 +0200364 "androidx.lifecycle_lifecycle-runtime-ktx",
Joshua Tsujib1a796b2019-01-16 15:43:12 -0800365 "androidx.dynamicanimation_dynamicanimation",
Steve Elliott300b48f2019-05-29 14:13:50 -0400366 "androidx-constraintlayout_constraintlayout",
Miranda Kepharte1a22b92020-12-16 14:01:12 -0500367 "androidx.exifinterface_exifinterface",
Pinyao Tingee191b12020-04-29 18:35:39 -0700368 "kotlinx-coroutines-android",
369 "kotlinx-coroutines-core",
Alejandro Nijamkinc738a8c2022-07-25 13:30:41 -0700370 "kotlinx_coroutines_test",
Chandru5a5e5332022-08-19 14:25:31 +0000371 "kotlin-reflect",
Lyn Han1b4f25e2019-06-11 13:56:34 -0700372 "iconloader_base",
Jason Monkae7ced22018-08-22 16:56:58 -0400373 "SystemUI-tags",
374 "SystemUI-proto",
375 "metrics-helper-lib",
Tadashi G. Takaokac7340fb2020-10-20 17:50:13 +0900376 "hamcrest-library",
377 "androidx.test.rules",
Jason Monkae7ced22018-08-22 16:56:58 -0400378 "testables",
Krzysztof KosiƄskice1b2a12023-10-06 20:16:49 +0000379 "truth",
Lucas Dupine37369f2021-08-31 00:19:39 +0000380 "monet",
Lucas Dupind83b4ee2023-07-08 11:05:47 -0700381 "libmonet",
Dave Mankoffdffcc472020-07-08 15:25:16 -0400382 "dagger2",
Bill Lina17858d12020-07-14 10:30:10 +0800383 "jsr330",
384 "WindowManager-Shell",
Lucas Silva0bfb4052022-09-20 23:32:02 -0400385 "LowLightDreamLib",
Johannes Gallmann0d5183c2022-10-04 13:32:16 +0000386 "motion_tool_lib",
Johannes Gallmannb642af92022-10-14 09:58:09 +0000387 "androidx.core_core-animation-testing-nodeps",
Jordan Demeulenaere54a0fae2023-01-04 11:36:46 +0100388 "androidx.compose.ui_ui",
Jason Monkae7ced22018-08-22 16:56:58 -0400389 ],
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000390}
391
392android_library {
393 name: "SystemUI-tests",
Jordan Demeulenaere68e91822022-12-16 10:55:47 +0100394 defaults: [
395 "SystemUI_compose_defaults",
396 ],
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000397 manifest: "tests/AndroidManifest-base.xml",
398 additional_manifests: ["tests/AndroidManifest.xml"],
399 srcs: [
400 "tests/src/**/*.kt",
401 "tests/src/**/*.java",
402 "src/**/*.kt",
403 "src/**/*.java",
404 "src/**/I*.aidl",
405 ":ReleaseJavaFiles",
406 ":SystemUI-tests-utils",
407 ],
408 static_libs: [
409 "SystemUI-tests-base",
410 "androidx.test.uiautomator_uiautomator",
Jeff DeCewa415d0e2023-08-02 11:30:09 -0400411 "androidx.core_core-animation-testing",
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000412 "mockito-target-extended-minus-junit4",
413 "androidx.test.ext.junit",
Steven Ng45b74c62023-03-23 11:23:02 +0000414 "androidx.test.ext.truth",
Colin Cross852cd142023-08-11 16:53:55 -0700415 "kotlin-test",
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000416 ],
Jason Monkae7ced22018-08-22 16:56:58 -0400417 libs: [
418 "android.test.runner",
Jason Monkae7ced22018-08-22 16:56:58 -0400419 "android.test.base",
Jordan Demeulenaere6fb22d42022-08-19 15:00:36 +0200420 "android.test.mock",
Jason Monkae7ced22018-08-22 16:56:58 -0400421 ],
Colin Cross6954ea72023-07-18 10:52:21 -0700422 kotlincflags: ["-Xjvm-default=all"],
Jason Monkae7ced22018-08-22 16:56:58 -0400423 aaptflags: [
424 "--extra-packages",
Hyunyoung Song8f9d34c2019-08-30 14:47:43 -0700425 "com.android.systemui",
Jason Monkae7ced22018-08-22 16:56:58 -0400426 ],
Dave Mankoffdffcc472020-07-08 15:25:16 -0400427 plugins: ["dagger2-compiler"],
Cole Faust17f1e722022-08-16 15:30:26 -0700428 lint: {
429 test: true,
Jeff Chen194a13f2023-03-16 15:40:05 -0700430 extra_check_modules: ["SystemUILintChecker"],
Cole Faust17f1e722022-08-16 15:30:26 -0700431 },
Jason Monkae7ced22018-08-22 16:56:58 -0400432}
433
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000434android_app {
435 name: "SystemUIRobo-stub",
436 defaults: [
437 "platform_app_defaults",
Jared Duke5bf6fb32023-02-23 14:27:47 -0800438 "SystemUI_optimized_defaults",
Kevin Liud3793232023-02-09 20:37:27 +0000439 "SystemUI_compose_defaults",
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000440 ],
441 manifest: "tests/AndroidManifest-base.xml",
Kevin Liud3793232023-02-09 20:37:27 +0000442
443 srcs: [
444 "src/**/*.kt",
445 "src/**/*.java",
446 "src/**/I*.aidl",
447 ":ReleaseJavaFiles",
448 ],
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000449 static_libs: [
450 "SystemUI-tests-base",
451 ],
452 aaptflags: [
453 "--extra-packages",
454 "com.android.systemui",
455 ],
456 dont_merge_manifests: true,
457 platform_apis: true,
458 system_ext_specific: true,
459 certificate: "platform",
460 privileged: true,
461 resource_dirs: [],
Kevin Liud3793232023-02-09 20:37:27 +0000462 kotlincflags: ["-Xjvm-default=all"],
Kevin Liu092b8212023-02-15 05:42:34 +0000463 optimize: {
464 shrink_resources: false,
465 proguard_flags_files: ["proguard.flags"],
466 },
Kevin Liud3793232023-02-09 20:37:27 +0000467
468 plugins: ["dagger2-compiler"],
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000469}
470
471android_robolectric_test {
472 name: "SystemUiRoboTests",
473 srcs: [
474 "tests/robolectric/src/**/*.kt",
475 "tests/robolectric/src/**/*.java",
Kevin Liud3793232023-02-09 20:37:27 +0000476 ":SystemUI-tests-utils",
Caitlin Shkuratovd3777bd2023-07-18 21:39:33 +0000477 ":SystemUI-test-fakes",
Kevin Liud3793232023-02-09 20:37:27 +0000478 ":SystemUI-tests-robolectric-pilots",
479 ],
480 static_libs: [
481 "androidx.test.uiautomator_uiautomator",
Jeff DeCewa415d0e2023-08-02 11:30:09 -0400482 "androidx.core_core-animation-testing",
Kevin Liud3793232023-02-09 20:37:27 +0000483 "androidx.test.ext.junit",
484 "inline-mockito-robolectric-prebuilt",
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000485 ],
486 libs: [
487 "android.test.runner",
488 "android.test.base",
489 "android.test.mock",
Krzysztof KosiƄskice1b2a12023-10-06 20:16:49 +0000490 "truth",
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000491 ],
Kevin Liud3793232023-02-09 20:37:27 +0000492
493 upstream: true,
494
Jay Aliomer9b13ae12022-11-28 14:50:09 +0000495 instrumentation_for: "SystemUIRobo-stub",
496 java_resource_dirs: ["tests/robolectric/config"],
497}
498
Jared Duke84e94b32022-08-05 13:46:38 -0700499// Opt-out config for optimizing the SystemUI target using R8.
500// Disabled via `export SYSTEMUI_OPTIMIZE_JAVA=false`, or explicitly in Make via
501// `SYSTEMUI_OPTIMIZE_JAVA := false`.
Jared Duke9dfa77b2021-12-22 13:31:06 -0800502soong_config_module_type {
503 name: "systemui_optimized_java_defaults",
504 module_type: "java_defaults",
505 config_namespace: "ANDROID",
506 bool_variables: ["SYSTEMUI_OPTIMIZE_JAVA"],
507 properties: ["optimize"],
Jared Duke2fee7402021-10-18 14:35:04 -0700508}
509
Jared Duke9dfa77b2021-12-22 13:31:06 -0800510systemui_optimized_java_defaults {
Jared Duke5bf6fb32023-02-23 14:27:47 -0800511 name: "SystemUI_optimized_defaults",
Jared Duke2fee7402021-10-18 14:35:04 -0700512 soong_config_variables: {
Jared Duke9dfa77b2021-12-22 13:31:06 -0800513 SYSTEMUI_OPTIMIZE_JAVA: {
Jared Duke2fee7402021-10-18 14:35:04 -0700514 optimize: {
515 enabled: true,
516 optimize: true,
517 shrink: true,
Jared Duke0668af22023-02-23 14:43:31 -0800518 shrink_resources: true,
Jared Dukef0904172022-06-07 18:01:06 +0000519 proguard_compatibility: false,
Jared Duke2fee7402021-10-18 14:35:04 -0700520 },
521 conditions_default: {
522 optimize: {
Jared Dukef0904172022-06-07 18:01:06 +0000523 proguard_compatibility: false,
Jared Duke2fee7402021-10-18 14:35:04 -0700524 },
525 },
526 },
527 },
528}
529
Jason Monka2f2d822018-08-13 11:10:48 -0400530android_app {
531 name: "SystemUI",
Jared Duke2fee7402021-10-18 14:35:04 -0700532 defaults: [
533 "platform_app_defaults",
Jared Duke5bf6fb32023-02-23 14:27:47 -0800534 "SystemUI_optimized_defaults",
Jared Duke2fee7402021-10-18 14:35:04 -0700535 ],
Jason Monka2f2d822018-08-13 11:10:48 -0400536 static_libs: [
537 "SystemUI-core",
538 ],
Anton Hansson7ccca9f2019-02-08 09:01:32 +0000539 resource_dirs: [],
Jason Monka2f2d822018-08-13 11:10:48 -0400540
Colin Crossc23cde42023-06-21 11:22:11 -0700541 use_resource_processor: true,
Jason Monka2f2d822018-08-13 11:10:48 -0400542 platform_apis: true,
Jeongik Chad45d9e12019-12-04 13:38:39 +0900543 system_ext_specific: true,
Jason Monka2f2d822018-08-13 11:10:48 -0400544 certificate: "platform",
545 privileged: true,
546
Colin Cross6954ea72023-07-18 10:52:21 -0700547 kotlincflags: ["-Xjvm-default=all"],
Selim Cinek820ba2d2019-06-18 18:59:09 -0700548
Jason Monka2f2d822018-08-13 11:10:48 -0400549 dxflags: ["--multi-dex"],
Jared Duke5bf6fb32023-02-23 14:27:47 -0800550 optimize: {
551 proguard_flags_files: ["proguard.flags"],
552 },
Winson Chungb754f522020-08-03 22:17:08 -0700553 required: [
554 "privapp_whitelist_com.android.systemui",
Hongwei Wang2b227ee2022-08-19 09:38:18 -0700555 "wmshell.protolog.json.gz",
Winson Chungb754f522020-08-03 22:17:08 -0700556 ],
Jason Monka2f2d822018-08-13 11:10:48 -0400557}