1// 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// 16package { 17 default_applicable_licenses: ["Android-Apache-2.0"], 18} 19 20android_library { 21 name: "CarSystemUI-core", 22 23 srcs: [ 24 "src/**/*.java", 25 "src/**/*.kt", 26 "src/**/I*.aidl", 27 ], 28 29 resource_dirs: [ 30 "res-keyguard", 31 "res", 32 ], 33 34 static_libs: [ 35 "SystemUI-core", 36 "CarNotificationLib", 37 "SystemUIPluginLib", 38 "SystemUISharedLib", 39 "SettingsLib", 40 "car-admin-ui-lib", 41 "car-helper-lib", 42 "car-ui-lib", 43 "car-qc-lib", 44 "androidx.legacy_legacy-support-v4", 45 "androidx.recyclerview_recyclerview", 46 "androidx.preference_preference", 47 "androidx.appcompat_appcompat", 48 "androidx.mediarouter_mediarouter", 49 "androidx.palette_palette", 50 "androidx.legacy_legacy-preference-v14", 51 "androidx.leanback_leanback", 52 "androidx.slice_slice-core", 53 "androidx.slice_slice-view", 54 "androidx.slice_slice-builders", 55 "androidx.arch.core_core-runtime", 56 "androidx.lifecycle_lifecycle-extensions", 57 "SystemUI-tags", 58 "SystemUI-proto", 59 "dagger2", 60 "//external/kotlinc:kotlin-annotations", 61 ], 62 63 libs: [ 64 "android.car", 65 ], 66 67 aaptflags: [ 68 "--no-resource-deduping", 69 ], 70 71 manifest: "AndroidManifest.xml", 72 73 plugins: ["dagger2-compiler"], 74 75} 76 77android_library { 78 name: "CarSystemUI-tests", 79 manifest: "tests/AndroidManifest.xml", 80 resource_dirs: [ 81 "tests/res", 82 "res-keyguard", 83 "res", 84 ], 85 srcs: [ 86 "tests/src/**/*.java", 87 "src/**/*.java", 88 "src/**/*.kt", 89 "src/**/I*.aidl", 90 ], 91 static_libs: [ 92 "SystemUI-tests", 93 "CarNotificationLib", 94 "SystemUIPluginLib", 95 "SystemUISharedLib", 96 "SettingsLib", 97 "androidx.legacy_legacy-support-v4", 98 "androidx.recyclerview_recyclerview", 99 "androidx.preference_preference", 100 "androidx.appcompat_appcompat", 101 "androidx.mediarouter_mediarouter", 102 "androidx.palette_palette", 103 "androidx.legacy_legacy-preference-v14", 104 "androidx.leanback_leanback", 105 "androidx.slice_slice-core", 106 "androidx.slice_slice-view", 107 "androidx.slice_slice-builders", 108 "androidx.arch.core_core-runtime", 109 "androidx.lifecycle_lifecycle-extensions", 110 "car-admin-ui-lib", 111 "car-helper-lib", 112 "car-ui-lib", 113 "car-qc-lib", 114 "SystemUI-tags", 115 "SystemUI-proto", 116 "metrics-helper-lib", 117 "androidx.test.rules", "hamcrest-library", 118 "mockito-target-inline-minus-junit4", 119 "testables", 120 "truth-prebuilt", 121 "testng", 122 "dagger2", 123 "//external/kotlinc:kotlin-annotations", 124 ], 125 libs: [ 126 "android.test.runner", 127 "android.test.base", 128 "android.car", 129 ], 130 131 aaptflags: [ 132 "--extra-packages", 133 "com.android.systemui", 134 ], 135 136 plugins: ["dagger2-compiler"], 137 138 // TODO(b/218518451) re-enable errorprone. 139 errorprone: {enabled: false}, 140} 141 142android_app { 143 name: "CarSystemUI", 144 145 static_libs: [ 146 "CarSystemUI-core", 147 ], 148 149 export_package_resources: true, 150 151 libs: [ 152 "android.car", 153 ], 154 155 resource_dirs: [], 156 157 overrides: [ 158 "SystemUI", 159 ], 160 161 platform_apis: true, 162 system_ext_specific: true, 163 certificate: "platform", 164 privileged: true, 165 166 optimize: { 167 proguard_flags_files: [ 168 "proguard.flags", 169 ], 170 }, 171 dxflags: ["--multi-dex"], 172 173 aaptflags: [ 174 "--extra-packages", 175 "com.android.keyguard", 176 ], 177 178 kotlincflags: ["-Xjvm-default=enable"], 179 180 plugins: ["dagger2-compiler"], 181 182 required: ["privapp_whitelist_com.android.systemui", "allowed_privapp_com.android.carsystemui"], 183} 184