Bob Badour | 8a6a2bc | 2021-02-12 17:07:05 -0800 | [diff] [blame] | 1 | package { |
| 2 | // See: http://go/android-license-faq |
| 3 | // A large-scale-change added 'default_applicable_licenses' to import |
| 4 | // all of the 'license_kinds' from "frameworks_base_license" |
| 5 | // to get the below license kinds: |
| 6 | // SPDX-license-identifier-Apache-2.0 |
| 7 | default_applicable_licenses: ["frameworks_base_license"], |
| 8 | } |
| 9 | |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 10 | filegroup { |
| 11 | name: "services-main-sources", |
Colin Cross | 33b78ef | 2021-03-26 10:31:25 -0700 | [diff] [blame] | 12 | srcs: [ |
| 13 | "java/**/*.java", |
| 14 | "java/**/package.html", |
| 15 | ], |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 16 | path: "java", |
| 17 | visibility: ["//visibility:private"], |
| 18 | } |
| 19 | |
| 20 | filegroup { |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 21 | name: "services-non-updatable-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 22 | srcs: [ |
| 23 | ":services.core-sources", |
Hongwei Wang | cdcb68d | 2020-11-23 12:48:05 -0800 | [diff] [blame] | 24 | ":services.core-sources-am-wm", |
Colin Cross | 33b78ef | 2021-03-26 10:31:25 -0700 | [diff] [blame] | 25 | "core/java/com/android/server/am/package.html", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 26 | ":services.accessibility-sources", |
| 27 | ":services.appprediction-sources", |
| 28 | ":services.appwidget-sources", |
| 29 | ":services.autofill-sources", |
| 30 | ":services.backup-sources", |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 31 | ":backuplib-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 32 | ":services.companion-sources", |
| 33 | ":services.contentcapture-sources", |
| 34 | ":services.contentsuggestions-sources", |
| 35 | ":services.coverage-sources", |
| 36 | ":services.devicepolicy-sources", |
| 37 | ":services.midi-sources", |
Nick Moukhine | cf47bdd | 2020-08-19 16:29:18 +0200 | [diff] [blame] | 38 | ":services.musicsearch-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 39 | ":services.net-sources", |
| 40 | ":services.print-sources", |
Yi Kong | 86f8593 | 2020-06-29 20:03:55 +0800 | [diff] [blame] | 41 | ":services.profcollect-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 42 | ":services.restrictions-sources", |
Hyunyoung Song | 21e60a9 | 2020-11-20 20:27:54 -0800 | [diff] [blame] | 43 | ":services.searchui-sources", |
Shashwat Razdan | d33e8c3 | 2021-01-29 13:02:19 -0800 | [diff] [blame] | 44 | ":services.smartspace-sources", |
Eugenio Marchiori | c3c0a1e | 2020-12-23 10:44:55 +0000 | [diff] [blame] | 45 | ":services.speech-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 46 | ":services.startop.iorap-sources", |
| 47 | ":services.systemcaptions-sources", |
Adam He | 2653f23 | 2020-11-30 18:23:20 -0800 | [diff] [blame] | 48 | ":services.translation-sources", |
Alex Agranovich | 50c987f | 2021-02-18 09:19:33 +0000 | [diff] [blame] | 49 | ":services.texttospeech-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 50 | ":services.usage-sources", |
| 51 | ":services.usb-sources", |
| 52 | ":services.voiceinteraction-sources", |
Roshan Pius | ea33fb9 | 2020-02-20 12:49:45 -0800 | [diff] [blame] | 53 | ":services.wifi-sources", |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 54 | ], |
| 55 | visibility: ["//visibility:private"], |
| 56 | } |
| 57 | |
| 58 | filegroup { |
| 59 | name: "services-all-sources", |
| 60 | srcs: [ |
| 61 | ":services-non-updatable-sources", |
| 62 | ":service-media-s-sources", |
Hai Zhang | 76f0def | 2020-01-16 01:42:58 -0800 | [diff] [blame] | 63 | ":service-permission-sources", |
Muhammad Qureshi | 8ea733e | 2020-02-07 09:30:28 -0800 | [diff] [blame] | 64 | ":service-statsd-sources", |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 65 | ], |
| 66 | visibility: ["//visibility:private"], |
| 67 | } |
| 68 | |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 69 | // merge all required services into one jar |
| 70 | // ============================================================ |
| 71 | java_library { |
| 72 | name: "services", |
Colin Cross | a12c0f5 | 2018-06-27 11:00:11 -0700 | [diff] [blame] | 73 | installable: true, |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 74 | |
| 75 | dex_preopt: { |
| 76 | app_image: true, |
| 77 | profile: "art-profile", |
| 78 | }, |
| 79 | |
Jiyong Park | bae2e90 | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 80 | srcs: [":services-main-sources"], |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 81 | |
| 82 | // The convention is to name each service module 'services.$(module_name)' |
| 83 | static_libs: [ |
Colin Cross | 4c0b06b | 2017-12-12 19:43:04 -0800 | [diff] [blame] | 84 | "services.core", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 85 | "services.accessibility", |
Sunny Goyal | 54e9134 | 2018-11-14 11:59:02 -0800 | [diff] [blame] | 86 | "services.appprediction", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 87 | "services.appwidget", |
| 88 | "services.autofill", |
| 89 | "services.backup", |
| 90 | "services.companion", |
Felipe Leme | 749b889 | 2018-12-03 16:30:30 -0800 | [diff] [blame] | 91 | "services.contentcapture", |
Winson Chung | 3fb0f25 | 2019-01-08 17:41:55 -0800 | [diff] [blame] | 92 | "services.contentsuggestions", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 93 | "services.coverage", |
| 94 | "services.devicepolicy", |
| 95 | "services.midi", |
Nick Moukhine | cf47bdd | 2020-08-19 16:29:18 +0200 | [diff] [blame] | 96 | "services.musicsearch", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 97 | "services.net", |
Danning Chen | 20b32ed | 2019-12-18 16:52:03 -0800 | [diff] [blame] | 98 | "services.people", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 99 | "services.print", |
Yi Kong | 86f8593 | 2020-06-29 20:03:55 +0800 | [diff] [blame] | 100 | "services.profcollect", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 101 | "services.restrictions", |
Hyunyoung Song | 21e60a9 | 2020-11-20 20:27:54 -0800 | [diff] [blame] | 102 | "services.searchui", |
Shashwat Razdan | d33e8c3 | 2021-01-29 13:02:19 -0800 | [diff] [blame] | 103 | "services.smartspace", |
Eugenio Marchiori | c3c0a1e | 2020-12-23 10:44:55 +0000 | [diff] [blame] | 104 | "services.speech", |
Igor Murashkin | 4de1e16 | 2018-11-26 10:33:17 -0800 | [diff] [blame] | 105 | "services.startop", |
Robert Berry | e14120e | 2019-03-18 16:33:42 -0400 | [diff] [blame] | 106 | "services.systemcaptions", |
Adam He | 2653f23 | 2020-11-30 18:23:20 -0800 | [diff] [blame] | 107 | "services.translation", |
Alex Agranovich | 50c987f | 2021-02-18 09:19:33 +0000 | [diff] [blame] | 108 | "services.texttospeech", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 109 | "services.usage", |
| 110 | "services.usb", |
| 111 | "services.voiceinteraction", |
Roshan Pius | ea33fb9 | 2020-02-20 12:49:45 -0800 | [diff] [blame] | 112 | "services.wifi", |
Dmitri Plotnikov | 4eaac3a | 2020-05-04 17:00:16 -0700 | [diff] [blame] | 113 | "service-blobstore", |
| 114 | "service-jobscheduler", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 115 | "android.hidl.base-V1.0-java", |
| 116 | ], |
| 117 | |
| 118 | libs: [ |
| 119 | "android.hidl.manager-V1.0-java", |
Paul Duffin | abebc6a | 2020-05-31 11:35:50 +0100 | [diff] [blame] | 120 | "framework-tethering.stubs.module_lib", |
Chris Wailes | 09724a7 | 2021-02-08 10:00:13 -0800 | [diff] [blame^] | 121 | "service-art.stubs.system_server", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 122 | ], |
| 123 | |
| 124 | // Uncomment to enable output of certain warnings (deprecated, unchecked) |
| 125 | //javacflags: ["-Xlint"], |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 126 | } |
| 127 | |
Colin Cross | 3a7d899 | 2017-12-05 17:33:58 -0800 | [diff] [blame] | 128 | // native library |
| 129 | // ============================================================= |
| 130 | |
| 131 | cc_library_shared { |
| 132 | name: "libandroid_servers", |
| 133 | defaults: ["libservices.core-libs"], |
| 134 | whole_static_libs: ["libservices.core"], |
| 135 | } |
atrost | 86895aa | 2019-08-19 16:51:15 +0100 | [diff] [blame] | 136 | |
| 137 | platform_compat_config { |
| 138 | name: "services-platform-compat-config", |
atrost | 86895aa | 2019-08-19 16:51:15 +0100 | [diff] [blame] | 139 | src: ":services", |
| 140 | } |
Ulya Trafimovich | 0d1b063d6 | 2019-12-03 11:59:51 +0000 | [diff] [blame] | 141 | |
| 142 | filegroup { |
| 143 | name: "art-profile", |
| 144 | srcs: ["art-profile"], |
| 145 | } |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 146 | |
| 147 | // API stub |
| 148 | // ============================================================= |
| 149 | |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 150 | stubs_defaults { |
| 151 | name: "services-stubs-default", |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 152 | installable: false, |
Makoto Onuki | af97aef | 2020-02-03 10:32:52 -0800 | [diff] [blame] | 153 | args: " --show-annotation android.annotation.SystemApi\\(client=android.annotation.SystemApi.Client.SYSTEM_SERVER\\)" + |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 154 | " --hide-annotation android.annotation.Hide" + |
Anton Hansson | f74130f | 2020-02-19 18:29:12 +0000 | [diff] [blame] | 155 | " --hide InternalClasses" + // com.android.* classes are okay in this interface |
| 156 | // TODO: remove the --hide options below |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 157 | " --hide-package com.google.android.startop.iorap" + |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 158 | " --hide DeprecationMismatch" + |
| 159 | " --hide HiddenTypedefConstant", |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 160 | visibility: ["//visibility:private"], |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 161 | filter_packages: ["com.android."], |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 162 | } |
| 163 | |
| 164 | droidstubs { |
| 165 | name: "services-stubs.sources", |
| 166 | srcs: [":services-all-sources"], |
| 167 | defaults: ["services-stubs-default"], |
Jiyong Park | 13c923d | 2019-12-20 16:29:45 +0900 | [diff] [blame] | 168 | check_api: { |
| 169 | current: { |
| 170 | api_file: "api/current.txt", |
| 171 | removed_api_file: "api/removed.txt", |
| 172 | }, |
Anton Hansson | daa9d88 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 173 | last_released: { |
Anton Hansson | 48ee95e | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 174 | api_file: ":android.api.system-server.latest", |
Anton Hansson | 960c675 | 2020-05-02 18:00:30 +0100 | [diff] [blame] | 175 | removed_api_file: ":removed.api.system-server.latest", |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 176 | baseline_file: ":android-incompatibilities.api.system-server.latest", |
Anton Hansson | daa9d88 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 177 | }, |
| 178 | api_lint: { |
| 179 | enabled: true, |
Anton Hansson | 48ee95e | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 180 | new_since: ":android.api.system-server.latest", |
Anton Hansson | daa9d88 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 181 | baseline_file: "api/lint-baseline.txt", |
| 182 | }, |
Jiyong Park | 13c923d | 2019-12-20 16:29:45 +0900 | [diff] [blame] | 183 | }, |
Anton Hansson | 85785fe | 2021-01-20 20:23:34 +0000 | [diff] [blame] | 184 | dists: [ |
| 185 | { |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 186 | targets: [ |
| 187 | "sdk", |
| 188 | "win_sdk", |
| 189 | ], |
Anton Hansson | 85785fe | 2021-01-20 20:23:34 +0000 | [diff] [blame] | 190 | dir: "apistubs/android/system-server/api", |
| 191 | dest: "android.txt", |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 192 | tag: ".api.txt", |
Anton Hansson | 85785fe | 2021-01-20 20:23:34 +0000 | [diff] [blame] | 193 | }, |
| 194 | { |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 195 | targets: [ |
| 196 | "sdk", |
| 197 | "win_sdk", |
| 198 | ], |
Anton Hansson | 85785fe | 2021-01-20 20:23:34 +0000 | [diff] [blame] | 199 | dir: "apistubs/android/system-server/api", |
| 200 | dest: "removed.txt", |
| 201 | tag: ".removed-api.txt", |
| 202 | }, |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 203 | ], |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 204 | } |
| 205 | |
| 206 | java_library { |
Anton Hansson | a49fb99 | 2020-03-19 15:23:32 +0000 | [diff] [blame] | 207 | name: "android_system_server_stubs_current", |
Anton Hansson | 53cf0ba | 2020-08-18 12:35:31 +0000 | [diff] [blame] | 208 | defaults: ["android_stubs_dists_default"], |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 209 | srcs: [":services-stubs.sources"], |
| 210 | installable: false, |
Anton Hansson | a49fb99 | 2020-03-19 15:23:32 +0000 | [diff] [blame] | 211 | static_libs: ["android_module_lib_stubs_current"], |
Anton Hansson | 4304e60 | 2020-07-21 12:55:48 +0100 | [diff] [blame] | 212 | sdk_version: "none", |
| 213 | system_modules: "none", |
| 214 | java_version: "1.8", |
Anton Hansson | 53cf0ba | 2020-08-18 12:35:31 +0000 | [diff] [blame] | 215 | dist: { |
| 216 | dir: "apistubs/android/system-server", |
| 217 | }, |
Jiyong Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 218 | } |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 219 | |
| 220 | droidstubs { |
| 221 | name: "services-non-updatable-stubs.sources", |
| 222 | srcs: [":services-non-updatable-sources"], |
| 223 | defaults: ["services-stubs-default"], |
| 224 | check_api: { |
| 225 | current: { |
| 226 | api_file: "api/non-updatable-current.txt", |
| 227 | removed_api_file: "api/non-updatable-removed.txt", |
| 228 | }, |
| 229 | api_lint: { |
| 230 | enabled: true, |
| 231 | new_since: ":android-non-updatable.api.system-server.latest", |
| 232 | baseline_file: "api/non-updatable-lint-baseline.txt", |
| 233 | }, |
| 234 | }, |
| 235 | dists: [ |
| 236 | { |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 237 | targets: [ |
| 238 | "sdk", |
| 239 | "win_sdk", |
| 240 | ], |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 241 | dir: "apistubs/android/system-server/api", |
| 242 | dest: "android-non-updatable.txt", |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 243 | tag: ".api.txt", |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 244 | }, |
| 245 | { |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 246 | targets: [ |
| 247 | "sdk", |
| 248 | "win_sdk", |
| 249 | ], |
Andrei Onea | 4311470 | 2021-02-10 20:53:12 +0000 | [diff] [blame] | 250 | dir: "apistubs/android/system-server/api", |
| 251 | dest: "android-non-updatable-removed.txt", |
| 252 | tag: ".removed-api.txt", |
| 253 | }, |
Felipe Leme | d3895b6 | 2021-03-24 16:55:27 -0700 | [diff] [blame] | 254 | ], |
| 255 | } |