blob: 785ca3537eb331186f2b409acd62b879b91d45c8 [file] [log] [blame]
Jeff Sharkey4d1d7b52020-05-04 15:31:07 -06001java_defaults {
2 name: "services_defaults",
3 plugins: [
4 "error_prone_android_framework",
5 ],
6}
7
Jiyong Parke86e89a2019-11-17 13:11:19 +09008filegroup {
9 name: "services-main-sources",
10 srcs: ["java/**/*.java"],
11 path: "java",
12 visibility: ["//visibility:private"],
13}
14
15filegroup {
Jiyong Park5ba39df2020-01-19 19:08:37 +090016 name: "services-all-sources",
Jiyong Parke86e89a2019-11-17 13:11:19 +090017 srcs: [
18 ":services.core-sources",
19 ":services.accessibility-sources",
20 ":services.appprediction-sources",
21 ":services.appwidget-sources",
22 ":services.autofill-sources",
23 ":services.backup-sources",
Jiyong Parkabc72e42019-11-17 15:17:53 +090024 ":backuplib-sources",
Jiyong Parke86e89a2019-11-17 13:11:19 +090025 ":services.companion-sources",
26 ":services.contentcapture-sources",
27 ":services.contentsuggestions-sources",
28 ":services.coverage-sources",
29 ":services.devicepolicy-sources",
30 ":services.midi-sources",
31 ":services.net-sources",
32 ":services.print-sources",
Yi Konga0bd2a92020-06-29 20:03:55 +080033 ":services.profcollect-sources",
Jiyong Parke86e89a2019-11-17 13:11:19 +090034 ":services.restrictions-sources",
35 ":services.startop.iorap-sources",
36 ":services.systemcaptions-sources",
37 ":services.usage-sources",
38 ":services.usb-sources",
39 ":services.voiceinteraction-sources",
Roshan Piusea33fb92020-02-20 12:49:45 -080040 ":services.wifi-sources",
Hai Zhang76f0def2020-01-16 01:42:58 -080041 ":service-permission-sources",
Muhammad Qureshi8ea733e2020-02-07 09:30:28 -080042 ":service-statsd-sources",
Jiyong Parke86e89a2019-11-17 13:11:19 +090043 ],
44 visibility: ["//visibility:private"],
45}
46
Colin Crosseb652a42017-12-05 09:46:29 -080047// merge all required services into one jar
48// ============================================================
49java_library {
50 name: "services",
Colin Crossa12c0f52018-06-27 11:00:11 -070051 installable: true,
Colin Crosseb652a42017-12-05 09:46:29 -080052
53 dex_preopt: {
54 app_image: true,
55 profile: "art-profile",
56 },
57
Jiyong Parke86e89a2019-11-17 13:11:19 +090058 srcs: [":services-main-sources"],
Colin Crosseb652a42017-12-05 09:46:29 -080059
60 // The convention is to name each service module 'services.$(module_name)'
61 static_libs: [
Colin Cross4c0b06b2017-12-12 19:43:04 -080062 "services.core",
Colin Crosseb652a42017-12-05 09:46:29 -080063 "services.accessibility",
Sunny Goyal54e91342018-11-14 11:59:02 -080064 "services.appprediction",
Colin Crosseb652a42017-12-05 09:46:29 -080065 "services.appwidget",
66 "services.autofill",
67 "services.backup",
68 "services.companion",
Felipe Leme749b8892018-12-03 16:30:30 -080069 "services.contentcapture",
Winson Chung3fb0f252019-01-08 17:41:55 -080070 "services.contentsuggestions",
Colin Crosseb652a42017-12-05 09:46:29 -080071 "services.coverage",
72 "services.devicepolicy",
73 "services.midi",
74 "services.net",
Danning Chen20b32ed2019-12-18 16:52:03 -080075 "services.people",
Colin Crosseb652a42017-12-05 09:46:29 -080076 "services.print",
Yi Konga0bd2a92020-06-29 20:03:55 +080077 "services.profcollect",
Colin Crosseb652a42017-12-05 09:46:29 -080078 "services.restrictions",
Igor Murashkin4de1e162018-11-26 10:33:17 -080079 "services.startop",
Robert Berry835123d2019-03-18 16:33:42 -040080 "services.systemcaptions",
Colin Crosseb652a42017-12-05 09:46:29 -080081 "services.usage",
82 "services.usb",
83 "services.voiceinteraction",
Roshan Piusea33fb92020-02-20 12:49:45 -080084 "services.wifi",
Dmitri Plotnikov4eaac3a2020-05-04 17:00:16 -070085 "service-blobstore",
86 "service-jobscheduler",
Colin Crosseb652a42017-12-05 09:46:29 -080087 "android.hidl.base-V1.0-java",
88 ],
89
90 libs: [
91 "android.hidl.manager-V1.0-java",
Paul Duffin01fd6ff2020-06-02 11:41:13 +010092 "framework-tethering.stubs.module_lib",
Colin Crosseb652a42017-12-05 09:46:29 -080093 ],
94
95 // Uncomment to enable output of certain warnings (deprecated, unchecked)
96 //javacflags: ["-Xlint"],
Colin Crosseb652a42017-12-05 09:46:29 -080097}
98
Colin Cross3a7d8992017-12-05 17:33:58 -080099// native library
100// =============================================================
101
102cc_library_shared {
103 name: "libandroid_servers",
104 defaults: ["libservices.core-libs"],
105 whole_static_libs: ["libservices.core"],
106}
atrost86895aa2019-08-19 16:51:15 +0100107
108platform_compat_config {
109 name: "services-platform-compat-config",
atrost86895aa2019-08-19 16:51:15 +0100110 src: ":services",
111}
Ulya Trafimovich0d1b063d62019-12-03 11:59:51 +0000112
113filegroup {
114 name: "art-profile",
115 srcs: ["art-profile"],
116}
Jiyong Park759a269a2019-11-17 15:17:53 +0900117
118// API stub
119// =============================================================
120
121droidstubs {
122 name: "services-stubs.sources",
Jiyong Park5ba39df2020-01-19 19:08:37 +0900123 srcs: [":services-all-sources"],
Jiyong Park759a269a2019-11-17 15:17:53 +0900124 installable: false,
Makoto Onuki3d8cabd42020-02-03 10:32:52 -0800125 args: " --show-annotation android.annotation.SystemApi\\(client=android.annotation.SystemApi.Client.SYSTEM_SERVER\\)" +
Jiyong Park759a269a2019-11-17 15:17:53 +0900126 " --hide-annotation android.annotation.Hide" +
Anton Hanssonac119a32020-02-19 18:29:12 +0000127 " --hide InternalClasses" + // com.android.* classes are okay in this interface
128 // TODO: remove the --hide options below
Jiyong Park759a269a2019-11-17 15:17:53 +0900129 " --hide-package com.google.android.startop.iorap" +
Jiyong Park759a269a2019-11-17 15:17:53 +0900130 " --hide DeprecationMismatch" +
131 " --hide HiddenTypedefConstant",
Jiyong Park759a269a2019-11-17 15:17:53 +0900132 visibility: ["//visibility:private"],
Anton Hanssonf68ef062020-03-27 15:09:26 +0000133 filter_packages: ["com.android."],
Jiyong Park1a3b9b92019-12-20 16:29:45 +0900134 check_api: {
135 current: {
136 api_file: "api/current.txt",
137 removed_api_file: "api/removed.txt",
138 },
Anton Hansson0decfb12020-02-19 11:35:09 +0000139 last_released: {
Anton Hanssonf68ddea2020-05-02 17:49:26 +0100140 api_file: ":android.api.system-server.latest",
Anton Hansson960c6752020-05-02 18:00:30 +0100141 removed_api_file: ":removed.api.system-server.latest",
Anton Hansson0decfb12020-02-19 11:35:09 +0000142 baseline_file: ":system-server-api-incompatibilities-with-last-released"
143 },
144 api_lint: {
145 enabled: true,
Anton Hanssonf68ddea2020-05-02 17:49:26 +0100146 new_since: ":android.api.system-server.latest",
Anton Hansson0decfb12020-02-19 11:35:09 +0000147 baseline_file: "api/lint-baseline.txt",
148 },
Jiyong Park1a3b9b92019-12-20 16:29:45 +0900149 },
Anton Hansson85785fe2021-01-20 20:23:34 +0000150 dists: [
151 {
152 targets: ["sdk", "win_sdk"],
153 dir: "apistubs/android/system-server/api",
154 dest: "android.txt",
155 tag: ".api.txt"
156 },
157 {
158 targets: ["sdk", "win_sdk"],
159 dir: "apistubs/android/system-server/api",
160 dest: "removed.txt",
161 tag: ".removed-api.txt",
162 },
163 ]
Jiyong Park759a269a2019-11-17 15:17:53 +0900164}
165
166java_library {
Anton Hanssonbde7d4f2020-03-19 15:23:32 +0000167 name: "android_system_server_stubs_current",
Anton Hanssona9205502020-07-15 13:36:34 +0100168 defaults: ["android_stubs_dists_default"],
Jiyong Park759a269a2019-11-17 15:17:53 +0900169 srcs: [":services-stubs.sources"],
170 installable: false,
Anton Hanssonbde7d4f2020-03-19 15:23:32 +0000171 static_libs: ["android_module_lib_stubs_current"],
Anton Hansson4304e602020-07-21 12:55:48 +0100172 sdk_version: "none",
173 system_modules: "none",
174 java_version: "1.8",
Anton Hanssona9205502020-07-15 13:36:34 +0100175 dist: {
176 dir: "apistubs/android/system-server",
177 },
Jiyong Park759a269a2019-11-17 15:17:53 +0900178}