Jeff Sharkey | 4d1d7b5 | 2020-05-04 15:31:07 -0600 | [diff] [blame] | 1 | java_defaults { |
| 2 | name: "services_defaults", |
| 3 | plugins: [ |
| 4 | "error_prone_android_framework", |
| 5 | ], |
| 6 | } |
| 7 | |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 8 | filegroup { |
| 9 | name: "services-main-sources", |
| 10 | srcs: ["java/**/*.java"], |
| 11 | path: "java", |
| 12 | visibility: ["//visibility:private"], |
| 13 | } |
| 14 | |
| 15 | filegroup { |
Jiyong Park | 5ba39df | 2020-01-19 19:08:37 +0900 | [diff] [blame] | 16 | name: "services-all-sources", |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 17 | 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 Park | abc72e4 | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 24 | ":backuplib-sources", |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 25 | ":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 Kong | a0bd2a9 | 2020-06-29 20:03:55 +0800 | [diff] [blame] | 33 | ":services.profcollect-sources", |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 34 | ":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 Pius | ea33fb9 | 2020-02-20 12:49:45 -0800 | [diff] [blame] | 40 | ":services.wifi-sources", |
Hai Zhang | 76f0def | 2020-01-16 01:42:58 -0800 | [diff] [blame] | 41 | ":service-permission-sources", |
Muhammad Qureshi | 8ea733e | 2020-02-07 09:30:28 -0800 | [diff] [blame] | 42 | ":service-statsd-sources", |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 43 | ], |
| 44 | visibility: ["//visibility:private"], |
| 45 | } |
| 46 | |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 47 | // merge all required services into one jar |
| 48 | // ============================================================ |
| 49 | java_library { |
| 50 | name: "services", |
Colin Cross | a12c0f5 | 2018-06-27 11:00:11 -0700 | [diff] [blame] | 51 | installable: true, |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 52 | |
| 53 | dex_preopt: { |
| 54 | app_image: true, |
| 55 | profile: "art-profile", |
| 56 | }, |
| 57 | |
Jiyong Park | e86e89a | 2019-11-17 13:11:19 +0900 | [diff] [blame] | 58 | srcs: [":services-main-sources"], |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 59 | |
| 60 | // The convention is to name each service module 'services.$(module_name)' |
| 61 | static_libs: [ |
Colin Cross | 4c0b06b | 2017-12-12 19:43:04 -0800 | [diff] [blame] | 62 | "services.core", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 63 | "services.accessibility", |
Sunny Goyal | 54e9134 | 2018-11-14 11:59:02 -0800 | [diff] [blame] | 64 | "services.appprediction", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 65 | "services.appwidget", |
| 66 | "services.autofill", |
| 67 | "services.backup", |
| 68 | "services.companion", |
Felipe Leme | 749b889 | 2018-12-03 16:30:30 -0800 | [diff] [blame] | 69 | "services.contentcapture", |
Winson Chung | 3fb0f25 | 2019-01-08 17:41:55 -0800 | [diff] [blame] | 70 | "services.contentsuggestions", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 71 | "services.coverage", |
| 72 | "services.devicepolicy", |
| 73 | "services.midi", |
| 74 | "services.net", |
Danning Chen | 20b32ed | 2019-12-18 16:52:03 -0800 | [diff] [blame] | 75 | "services.people", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 76 | "services.print", |
Yi Kong | a0bd2a9 | 2020-06-29 20:03:55 +0800 | [diff] [blame] | 77 | "services.profcollect", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 78 | "services.restrictions", |
Igor Murashkin | 4de1e16 | 2018-11-26 10:33:17 -0800 | [diff] [blame] | 79 | "services.startop", |
Robert Berry | 835123d | 2019-03-18 16:33:42 -0400 | [diff] [blame] | 80 | "services.systemcaptions", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 81 | "services.usage", |
| 82 | "services.usb", |
| 83 | "services.voiceinteraction", |
Roshan Pius | ea33fb9 | 2020-02-20 12:49:45 -0800 | [diff] [blame] | 84 | "services.wifi", |
Dmitri Plotnikov | 4eaac3a | 2020-05-04 17:00:16 -0700 | [diff] [blame] | 85 | "service-blobstore", |
| 86 | "service-jobscheduler", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 87 | "android.hidl.base-V1.0-java", |
| 88 | ], |
| 89 | |
| 90 | libs: [ |
| 91 | "android.hidl.manager-V1.0-java", |
Paul Duffin | 01fd6ff | 2020-06-02 11:41:13 +0100 | [diff] [blame] | 92 | "framework-tethering.stubs.module_lib", |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 93 | ], |
| 94 | |
| 95 | // Uncomment to enable output of certain warnings (deprecated, unchecked) |
| 96 | //javacflags: ["-Xlint"], |
Colin Cross | eb652a4 | 2017-12-05 09:46:29 -0800 | [diff] [blame] | 97 | } |
| 98 | |
Colin Cross | 3a7d899 | 2017-12-05 17:33:58 -0800 | [diff] [blame] | 99 | // native library |
| 100 | // ============================================================= |
| 101 | |
| 102 | cc_library_shared { |
| 103 | name: "libandroid_servers", |
| 104 | defaults: ["libservices.core-libs"], |
| 105 | whole_static_libs: ["libservices.core"], |
| 106 | } |
atrost | 86895aa | 2019-08-19 16:51:15 +0100 | [diff] [blame] | 107 | |
| 108 | platform_compat_config { |
| 109 | name: "services-platform-compat-config", |
atrost | 86895aa | 2019-08-19 16:51:15 +0100 | [diff] [blame] | 110 | src: ":services", |
| 111 | } |
Ulya Trafimovich | 0d1b063d6 | 2019-12-03 11:59:51 +0000 | [diff] [blame] | 112 | |
| 113 | filegroup { |
| 114 | name: "art-profile", |
| 115 | srcs: ["art-profile"], |
| 116 | } |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 117 | |
| 118 | // API stub |
| 119 | // ============================================================= |
| 120 | |
| 121 | droidstubs { |
| 122 | name: "services-stubs.sources", |
Jiyong Park | 5ba39df | 2020-01-19 19:08:37 +0900 | [diff] [blame] | 123 | srcs: [":services-all-sources"], |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 124 | installable: false, |
Makoto Onuki | 3d8cabd4 | 2020-02-03 10:32:52 -0800 | [diff] [blame] | 125 | args: " --show-annotation android.annotation.SystemApi\\(client=android.annotation.SystemApi.Client.SYSTEM_SERVER\\)" + |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 126 | " --hide-annotation android.annotation.Hide" + |
Anton Hansson | ac119a3 | 2020-02-19 18:29:12 +0000 | [diff] [blame] | 127 | " --hide InternalClasses" + // com.android.* classes are okay in this interface |
| 128 | // TODO: remove the --hide options below |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 129 | " --hide-package com.google.android.startop.iorap" + |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 130 | " --hide DeprecationMismatch" + |
| 131 | " --hide HiddenTypedefConstant", |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 132 | visibility: ["//visibility:private"], |
Anton Hansson | f68ef06 | 2020-03-27 15:09:26 +0000 | [diff] [blame] | 133 | filter_packages: ["com.android."], |
Jiyong Park | 1a3b9b9 | 2019-12-20 16:29:45 +0900 | [diff] [blame] | 134 | check_api: { |
| 135 | current: { |
| 136 | api_file: "api/current.txt", |
| 137 | removed_api_file: "api/removed.txt", |
| 138 | }, |
Anton Hansson | 0decfb1 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 139 | last_released: { |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 140 | api_file: ":android.api.system-server.latest", |
Anton Hansson | 960c675 | 2020-05-02 18:00:30 +0100 | [diff] [blame] | 141 | removed_api_file: ":removed.api.system-server.latest", |
Anton Hansson | 0decfb1 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 142 | baseline_file: ":system-server-api-incompatibilities-with-last-released" |
| 143 | }, |
| 144 | api_lint: { |
| 145 | enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 146 | new_since: ":android.api.system-server.latest", |
Anton Hansson | 0decfb1 | 2020-02-19 11:35:09 +0000 | [diff] [blame] | 147 | baseline_file: "api/lint-baseline.txt", |
| 148 | }, |
Jiyong Park | 1a3b9b9 | 2019-12-20 16:29:45 +0900 | [diff] [blame] | 149 | }, |
Anton Hansson | 85785fe | 2021-01-20 20:23:34 +0000 | [diff] [blame] | 150 | 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 Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 164 | } |
| 165 | |
| 166 | java_library { |
Anton Hansson | bde7d4f | 2020-03-19 15:23:32 +0000 | [diff] [blame] | 167 | name: "android_system_server_stubs_current", |
Anton Hansson | a920550 | 2020-07-15 13:36:34 +0100 | [diff] [blame] | 168 | defaults: ["android_stubs_dists_default"], |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 169 | srcs: [":services-stubs.sources"], |
| 170 | installable: false, |
Anton Hansson | bde7d4f | 2020-03-19 15:23:32 +0000 | [diff] [blame] | 171 | static_libs: ["android_module_lib_stubs_current"], |
Anton Hansson | 4304e60 | 2020-07-21 12:55:48 +0100 | [diff] [blame] | 172 | sdk_version: "none", |
| 173 | system_modules: "none", |
| 174 | java_version: "1.8", |
Anton Hansson | a920550 | 2020-07-15 13:36:34 +0100 | [diff] [blame] | 175 | dist: { |
| 176 | dir: "apistubs/android/system-server", |
| 177 | }, |
Jiyong Park | 759a269a | 2019-11-17 15:17:53 +0900 | [diff] [blame] | 178 | } |