Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 1 | // Copyright (C) 2019 The Android Open Source Project |
| 2 | // |
| 3 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | // you may not use this file except in compliance with the License. |
| 5 | // You may obtain a copy of the License at |
| 6 | // |
| 7 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | // |
| 9 | // Unless required by applicable law or agreed to in writing, software |
| 10 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | // See the License for the specific language governing permissions and |
| 13 | // limitations under the License. |
| 14 | |
| 15 | // How stubs are generated: |
| 16 | // |
| 17 | // raw source files --(metalava)--> stub source files --(javac)--> stub jar files |
| 18 | // |
| 19 | // The metalava conversion is done by droidstub modules *-api-stubs-docs. |
| 20 | // The javac compilation is done by java_library modules android_*_stubs_current. |
| 21 | // The metalava conversion is also responsible for creating API signature files |
| 22 | // and comparing them against the last API signature in api/*-current.txt files |
| 23 | // and also against the latest frozen API signature in prebuilts/sdk/*/*/api/android.txt |
| 24 | // files. |
| 25 | |
| 26 | ///////////////////////////////////////////////////////////////////// |
| 27 | // Common metalava configs |
| 28 | ///////////////////////////////////////////////////////////////////// |
| 29 | |
| 30 | packages_to_document = [ |
| 31 | "android", |
| 32 | "dalvik", |
| 33 | "java", |
| 34 | "javax", |
| 35 | "junit", |
| 36 | "org.apache.http", |
| 37 | "org.json", |
| 38 | "org.w3c.dom", |
| 39 | "org.xml.sax", |
| 40 | "org.xmlpull", |
| 41 | ] |
| 42 | |
| 43 | stubs_defaults { |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 44 | name: "metalava-base-api-stubs-default", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 45 | srcs: [ |
| 46 | ":framework-non-updatable-sources", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 47 | "core/java/**/*.logtags", |
| 48 | ":opt-telephony-srcs", |
| 49 | ":opt-net-voip-srcs", |
Paul Duffin | 5c89e70 | 2020-03-26 15:33:48 +0000 | [diff] [blame] | 50 | ":art-module-public-api-stubs-source", |
Paul Duffin | 5c89e70 | 2020-03-26 15:33:48 +0000 | [diff] [blame] | 51 | ":android_icu4j_public_api_files", |
Ramy Medhat | aaa8386 | 2020-05-04 05:54:30 -0400 | [diff] [blame] | 52 | "**/package.html", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 53 | ], |
| 54 | libs: ["framework-internal-utils"], |
| 55 | installable: false, |
| 56 | annotations_enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 57 | previous_api: ":android.api.public.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 58 | merge_annotations_dirs: [ |
| 59 | "metalava-manual", |
| 60 | ], |
Aurimas Liutikas | 94bac9c | 2020-03-12 17:06:12 -0700 | [diff] [blame] | 61 | api_levels_annotations_enabled: false, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 62 | filter_packages: packages_to_document, |
| 63 | } |
| 64 | |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 65 | stubs_defaults { |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 66 | name: "metalava-full-api-stubs-default", |
| 67 | defaults: ["metalava-base-api-stubs-default"], |
Anton Hansson | e01390c | 2020-05-07 12:06:00 +0100 | [diff] [blame] | 68 | srcs: [ |
Paul Duffin | e55d4e3 | 2020-05-14 17:55:46 +0100 | [diff] [blame] | 69 | ":conscrypt.module.public.api{.public.stubs.source}", |
Anton Hansson | e01390c | 2020-05-07 12:06:00 +0100 | [diff] [blame] | 70 | ":framework-updatable-sources", |
| 71 | ], |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 72 | sdk_version: "core_platform", |
| 73 | } |
| 74 | |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 75 | stubs_defaults { |
| 76 | name: "metalava-non-updatable-api-stubs-default", |
| 77 | defaults: ["metalava-base-api-stubs-default"], |
Anton Hansson | e53bec0 | 2020-03-20 09:12:52 +0000 | [diff] [blame] | 78 | sdk_version: "core_platform", |
Anton Hansson | ebb26a3 | 2020-04-14 16:35:36 +0100 | [diff] [blame] | 79 | // There are a few classes from modules used as type arguments that |
| 80 | // need to be resolved by metalava. For now, we can use a previously |
| 81 | // finalized stub library to resolve them. If a new class gets added, |
| 82 | // this may be need to be revisited to use a manually maintained stub |
| 83 | // library with empty classes in order to resolve those references. |
| 84 | libs: ["sdk_system_29_android"], |
| 85 | aidl: { |
| 86 | local_include_dirs: [ |
| 87 | "media/apex/java", |
| 88 | "wifi/aidl-export", |
| 89 | ], |
| 90 | }, |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 91 | } |
| 92 | |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 93 | ///////////////////////////////////////////////////////////////////// |
| 94 | // *-api-stubs-docs modules providing source files for the stub libraries |
| 95 | ///////////////////////////////////////////////////////////////////// |
| 96 | |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 97 | // api-stubs-docs, system-api-stubs-docs, and test-api-stubs-docs have APIs |
| 98 | // from the non-updatable part of the platform as well as from the updatable |
| 99 | // modules |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 100 | droidstubs { |
| 101 | name: "api-stubs-docs", |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 102 | defaults: ["metalava-full-api-stubs-default"], |
Artur Satayev | 0a97d5e | 2020-03-25 16:45:56 +0000 | [diff] [blame] | 103 | removed_dex_api_filename: "removed-dex.txt", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 104 | arg_files: [ |
| 105 | "core/res/AndroidManifest.xml", |
| 106 | ], |
| 107 | args: metalava_framework_docs_args, |
| 108 | check_api: { |
| 109 | current: { |
| 110 | api_file: "api/current.txt", |
| 111 | removed_api_file: "api/removed.txt", |
| 112 | }, |
| 113 | last_released: { |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 114 | api_file: ":android.api.public.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 115 | removed_api_file: "api/removed.txt", |
| 116 | baseline_file: ":public-api-incompatibilities-with-last-released", |
| 117 | }, |
| 118 | api_lint: { |
| 119 | enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 120 | new_since: ":android.api.public.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 121 | baseline_file: "api/lint-baseline.txt", |
| 122 | }, |
| 123 | }, |
Anton Hansson | ba367d3 | 2020-03-23 18:08:55 +0000 | [diff] [blame] | 124 | dist: { |
| 125 | targets: ["sdk", "win_sdk"], |
| 126 | dir: "apistubs/android/public/api", |
| 127 | dest: "android.txt", |
| 128 | }, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 129 | jdiff_enabled: true, |
| 130 | } |
| 131 | |
Anton Hansson | 7f6823e | 2020-06-04 15:09:36 +0100 | [diff] [blame] | 132 | droidstubs { |
| 133 | name: "api-stubs-docs-non-updatable", |
| 134 | defaults: ["metalava-non-updatable-api-stubs-default"], |
| 135 | arg_files: ["core/res/AndroidManifest.xml"], |
| 136 | args: metalava_framework_docs_args, |
| 137 | check_api: { |
| 138 | current: { |
| 139 | api_file: "non-updatable-api/current.txt", |
| 140 | removed_api_file: "non-updatable-api/removed.txt", |
| 141 | }, |
| 142 | }, |
| 143 | } |
| 144 | |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 145 | priv_apps = " " + |
| 146 | "--show-annotation android.annotation.SystemApi\\(" + |
| 147 | "client=android.annotation.SystemApi.Client.PRIVILEGED_APPS" + |
| 148 | "\\) " |
| 149 | |
| 150 | module_libs = " " + |
| 151 | " --show-annotation android.annotation.SystemApi\\(" + |
| 152 | "client=android.annotation.SystemApi.Client.MODULE_LIBRARIES" + |
| 153 | "\\) " |
| 154 | |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 155 | droidstubs { |
| 156 | name: "system-api-stubs-docs", |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 157 | defaults: ["metalava-full-api-stubs-default"], |
Artur Satayev | 0a97d5e | 2020-03-25 16:45:56 +0000 | [diff] [blame] | 158 | removed_dex_api_filename: "system-removed-dex.txt", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 159 | arg_files: [ |
| 160 | "core/res/AndroidManifest.xml", |
| 161 | ], |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 162 | args: metalava_framework_docs_args + priv_apps, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 163 | check_api: { |
| 164 | current: { |
| 165 | api_file: "api/system-current.txt", |
| 166 | removed_api_file: "api/system-removed.txt", |
| 167 | }, |
| 168 | last_released: { |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 169 | api_file: ":android.api.system.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 170 | removed_api_file: "api/system-removed.txt", |
| 171 | baseline_file: ":system-api-incompatibilities-with-last-released" |
| 172 | }, |
| 173 | api_lint: { |
| 174 | enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 175 | new_since: ":android.api.system.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 176 | baseline_file: "api/system-lint-baseline.txt", |
| 177 | }, |
| 178 | }, |
Anton Hansson | ba367d3 | 2020-03-23 18:08:55 +0000 | [diff] [blame] | 179 | dist: { |
| 180 | targets: ["sdk", "win_sdk"], |
| 181 | dir: "apistubs/android/system/api", |
| 182 | dest: "android.txt", |
| 183 | }, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 184 | jdiff_enabled: true, |
| 185 | } |
| 186 | |
| 187 | droidstubs { |
Anton Hansson | 7f6823e | 2020-06-04 15:09:36 +0100 | [diff] [blame] | 188 | name: "system-api-stubs-docs-non-updatable", |
| 189 | defaults: ["metalava-non-updatable-api-stubs-default"], |
| 190 | arg_files: ["core/res/AndroidManifest.xml"], |
| 191 | args: metalava_framework_docs_args + priv_apps, |
| 192 | check_api: { |
| 193 | current: { |
| 194 | api_file: "non-updatable-api/system-current.txt", |
| 195 | removed_api_file: "non-updatable-api/system-removed.txt", |
| 196 | }, |
| 197 | }, |
| 198 | } |
| 199 | |
| 200 | droidstubs { |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 201 | name: "test-api-stubs-docs", |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 202 | defaults: ["metalava-full-api-stubs-default"], |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 203 | arg_files: [ |
| 204 | "core/res/AndroidManifest.xml", |
| 205 | ], |
| 206 | args: metalava_framework_docs_args + " --show-annotation android.annotation.TestApi", |
| 207 | check_api: { |
| 208 | current: { |
| 209 | api_file: "api/test-current.txt", |
| 210 | removed_api_file: "api/test-removed.txt", |
| 211 | }, |
| 212 | api_lint: { |
| 213 | enabled: true, |
| 214 | baseline_file: "api/test-lint-baseline.txt", |
| 215 | }, |
| 216 | }, |
Anton Hansson | ba367d3 | 2020-03-23 18:08:55 +0000 | [diff] [blame] | 217 | dist: { |
| 218 | targets: ["sdk", "win_sdk"], |
| 219 | dir: "apistubs/android/test/api", |
| 220 | dest: "android.txt", |
| 221 | }, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 222 | } |
| 223 | |
| 224 | ///////////////////////////////////////////////////////////////////// |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 225 | // Following droidstubs modules are for extra APIs for modules. |
| 226 | // The framework currently have two more API surfaces for modules: |
| 227 | // @SystemApi(client=MODULE_APPS) and @SystemApi(client=MODULE_LIBRARIES) |
| 228 | ///////////////////////////////////////////////////////////////////// |
| 229 | |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 230 | // TODO(b/146727827) remove the *-api module when we can teach metalava |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 231 | // about the relationship among the API surfaces. Currently, these modules are only to generate |
| 232 | // the API signature files and ensure that the APIs evolve in a backwards compatible manner. |
| 233 | // They however are NOT used for building the API stub. |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 234 | |
| 235 | droidstubs { |
| 236 | name: "module-lib-api", |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 237 | defaults: ["metalava-full-api-stubs-default"], |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 238 | arg_files: ["core/res/AndroidManifest.xml"], |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 239 | args: metalava_framework_docs_args + module_libs, |
Paul Duffin | 4c5dc18 | 2020-04-08 18:28:15 +0100 | [diff] [blame] | 240 | |
| 241 | // Do not generate stubs as they are not needed |
| 242 | generate_stubs: false, |
| 243 | |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 244 | check_api: { |
| 245 | current: { |
| 246 | api_file: "api/module-lib-current.txt", |
| 247 | removed_api_file: "api/module-lib-removed.txt", |
| 248 | }, |
Anton Hansson | 626afea | 2020-02-11 14:36:40 +0000 | [diff] [blame] | 249 | last_released: { |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 250 | api_file: ":android.api.module-lib.latest", |
Anton Hansson | 626afea | 2020-02-11 14:36:40 +0000 | [diff] [blame] | 251 | removed_api_file: "api/module-lib-removed.txt", |
| 252 | baseline_file: ":module-lib-api-incompatibilities-with-last-released" |
| 253 | }, |
| 254 | api_lint: { |
| 255 | enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 256 | new_since: ":android.api.module-lib.latest", |
Anton Hansson | 626afea | 2020-02-11 14:36:40 +0000 | [diff] [blame] | 257 | baseline_file: "api/module-lib-lint-baseline.txt", |
| 258 | }, |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 259 | }, |
Anton Hansson | ba367d3 | 2020-03-23 18:08:55 +0000 | [diff] [blame] | 260 | dist: { |
| 261 | targets: ["sdk", "win_sdk"], |
| 262 | dir: "apistubs/android/module-lib/api", |
| 263 | dest: "android.txt", |
| 264 | }, |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 265 | } |
| 266 | |
Anton Hansson | 7f6823e | 2020-06-04 15:09:36 +0100 | [diff] [blame] | 267 | droidstubs { |
| 268 | name: "module-lib-api-stubs-docs-non-updatable", |
| 269 | defaults: ["metalava-non-updatable-api-stubs-default"], |
| 270 | arg_files: ["core/res/AndroidManifest.xml"], |
| 271 | args: metalava_framework_docs_args + module_libs, |
| 272 | check_api: { |
| 273 | current: { |
| 274 | api_file: "non-updatable-api/module-lib-current.txt", |
| 275 | removed_api_file: "non-updatable-api/module-lib-removed.txt", |
| 276 | }, |
| 277 | }, |
| 278 | } |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 279 | |
| 280 | // The following droidstub module generates source files for the API stub library for |
| 281 | // modules. Note that it not only includes its own APIs but also other APIs that have |
| 282 | // narrower scope (all @SystemApis, not just the ones with 'client=MODULE_LIBRARIES'). |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 283 | |
| 284 | droidstubs { |
| 285 | name: "module-lib-api-stubs-docs", |
Anton Hansson | 537564e | 2020-03-06 17:16:06 +0000 | [diff] [blame] | 286 | defaults: ["metalava-non-updatable-api-stubs-default"], |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 287 | arg_files: ["core/res/AndroidManifest.xml"], |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 288 | args: metalava_framework_docs_args + priv_apps + module_libs, |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 289 | } |
| 290 | |
| 291 | ///////////////////////////////////////////////////////////////////// |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 292 | // android_*_stubs_current modules are the stubs libraries compiled |
| 293 | // from *-api-stubs-docs |
| 294 | ///////////////////////////////////////////////////////////////////// |
| 295 | |
| 296 | java_defaults { |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 297 | name: "android_defaults_stubs_current", |
Anton Hansson | 42afd61 | 2020-02-08 20:43:19 +0000 | [diff] [blame] | 298 | libs: [ "stub-annotations" ], |
Paul Duffin | a281e92 | 2020-03-25 10:13:33 +0000 | [diff] [blame] | 299 | static_libs: [ |
| 300 | "private-stub-annotations-jar", |
| 301 | |
| 302 | // License notices from art module |
| 303 | "art-notices-for-framework-stubs-jar", |
| 304 | ], |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 305 | errorprone: { |
| 306 | javacflags: [ |
| 307 | "-XepDisableAllChecks", |
| 308 | ], |
| 309 | }, |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 310 | sdk_version: "none", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 311 | system_modules: "none", |
| 312 | java_version: "1.8", |
| 313 | compile_dex: true, |
| 314 | } |
| 315 | |
| 316 | java_library_static { |
| 317 | name: "android_stubs_current", |
Anton Hansson | 42afd61 | 2020-02-08 20:43:19 +0000 | [diff] [blame] | 318 | srcs: [ ":api-stubs-docs" ], |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 319 | defaults: ["android_defaults_stubs_current"], |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 320 | } |
| 321 | |
| 322 | java_library_static { |
| 323 | name: "android_system_stubs_current", |
Anton Hansson | 42afd61 | 2020-02-08 20:43:19 +0000 | [diff] [blame] | 324 | srcs: [ ":system-api-stubs-docs" ], |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 325 | defaults: ["android_defaults_stubs_current"], |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 326 | } |
| 327 | |
| 328 | java_library_static { |
| 329 | name: "android_test_stubs_current", |
Anton Hansson | 42afd61 | 2020-02-08 20:43:19 +0000 | [diff] [blame] | 330 | srcs: [ ":test-api-stubs-docs" ], |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 331 | defaults: ["android_defaults_stubs_current"], |
Jiyong Park | 2e6cdcc | 2019-12-20 15:30:28 +0900 | [diff] [blame] | 332 | } |
| 333 | |
| 334 | java_library_static { |
Anton Hansson | 9c4bbe9 | 2020-01-30 12:09:02 +0000 | [diff] [blame] | 335 | name: "android_module_lib_stubs_current", |
Anton Hansson | 42afd61 | 2020-02-08 20:43:19 +0000 | [diff] [blame] | 336 | srcs: [ ":module-lib-api-stubs-docs" ], |
Anton Hansson | fbd32f3 | 2020-04-09 14:16:37 +0100 | [diff] [blame] | 337 | defaults: ["android_defaults_stubs_current"], |
Anton Hansson | ebb26a3 | 2020-04-14 16:35:36 +0100 | [diff] [blame] | 338 | libs: ["sdk_system_29_android"], |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 339 | } |
| 340 | |
Anton Hansson | 7f6823e | 2020-06-04 15:09:36 +0100 | [diff] [blame] | 341 | java_library_static { |
| 342 | name: "android_non_updatable_stubs_current", |
| 343 | srcs: [":api-stubs-docs-non-updatable"], |
| 344 | defaults: ["android_defaults_stubs_current"], |
| 345 | libs: ["sdk_system_29_android"], |
| 346 | } |
| 347 | |
| 348 | java_library_static { |
| 349 | name: "android_system_non_updatable_stubs_current", |
| 350 | srcs: [":system-api-stubs-docs-non-updatable"], |
| 351 | defaults: ["android_defaults_stubs_current"], |
| 352 | libs: ["sdk_system_29_android"], |
| 353 | } |
| 354 | |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 355 | ///////////////////////////////////////////////////////////////////// |
| 356 | // hwbinder.stubs provides APIs required for building HIDL Java |
| 357 | // libraries. |
| 358 | ///////////////////////////////////////////////////////////////////// |
| 359 | |
| 360 | droidstubs { |
| 361 | name: "hwbinder-stubs-docs", |
| 362 | srcs: [ |
| 363 | "core/java/android/os/HidlSupport.java", |
| 364 | "core/java/android/annotation/IntDef.java", |
| 365 | "core/java/android/annotation/IntRange.java", |
| 366 | "core/java/android/annotation/NonNull.java", |
| 367 | "core/java/android/annotation/SystemApi.java", |
| 368 | "core/java/android/os/HidlMemory.java", |
| 369 | "core/java/android/os/HwBinder.java", |
| 370 | "core/java/android/os/HwBlob.java", |
| 371 | "core/java/android/os/HwParcel.java", |
| 372 | "core/java/android/os/IHwBinder.java", |
| 373 | "core/java/android/os/IHwInterface.java", |
| 374 | "core/java/android/os/DeadObjectException.java", |
| 375 | "core/java/android/os/DeadSystemException.java", |
| 376 | "core/java/android/os/NativeHandle.java", |
| 377 | "core/java/android/os/RemoteException.java", |
| 378 | "core/java/android/util/AndroidException.java", |
| 379 | ], |
| 380 | installable: false, |
| 381 | sdk_version: "core_platform", |
| 382 | annotations_enabled: true, |
Anton Hansson | f68ddea | 2020-05-02 17:49:26 +0100 | [diff] [blame] | 383 | previous_api: ":android.api.public.latest", |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 384 | merge_annotations_dirs: [ |
| 385 | "metalava-manual", |
| 386 | ], |
Anton Hansson | 81969c2 | 2020-02-03 20:45:56 +0000 | [diff] [blame] | 387 | args: priv_apps, |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 388 | } |
| 389 | |
| 390 | java_library_static { |
| 391 | name: "hwbinder.stubs", |
| 392 | sdk_version: "core_current", |
| 393 | srcs: [ |
| 394 | ":hwbinder-stubs-docs", |
| 395 | ], |
| 396 | } |
| 397 | |
| 398 | ///////////////////////////////////////////////////////////////////// |
Jiyong Park | 7fb4b18 | 2019-12-20 14:35:43 +0900 | [diff] [blame] | 399 | // api/*-current.txt files for use by modules in other directories |
| 400 | // like the CTS test |
| 401 | ///////////////////////////////////////////////////////////////////// |
| 402 | |
| 403 | filegroup { |
| 404 | name: "frameworks-base-api-current.txt", |
| 405 | srcs: [ |
| 406 | "api/current.txt", |
| 407 | ], |
| 408 | } |
| 409 | |
| 410 | filegroup { |
| 411 | name: "frameworks-base-api-system-current.txt", |
| 412 | srcs: [ |
| 413 | "api/system-current.txt", |
| 414 | ], |
| 415 | } |
| 416 | |
| 417 | filegroup { |
| 418 | name: "frameworks-base-api-system-removed.txt", |
| 419 | srcs: [ |
| 420 | "api/system-removed.txt", |
| 421 | ], |
| 422 | } |