blob: eaa984ac0cddd6b11837b2c254393cc3a578ca05 [file] [log] [blame]
Paul Duffin11281142021-01-25 18:31:26 +00001// Copyright (C) 2021 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
Bob Badour051ef782021-02-12 17:07:05 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "frameworks_base_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 // SPDX-license-identifier-MIT
22 // SPDX-license-identifier-Unicode-DFS
23 default_applicable_licenses: ["frameworks_base_license"],
24}
25
Paul Duffinc67e1df2023-01-09 12:03:59 +000026soong_config_module_type {
27 name: "custom_platform_bootclasspath",
28 module_type: "platform_bootclasspath",
Roshan Pius9667b042024-01-12 14:16:10 -080029 config_namespace: "bootclasspath",
Paul Duffinc67e1df2023-01-09 12:03:59 +000030 bool_variables: [
31 "car_bootclasspath_fragment",
Roshan Pius9667b042024-01-12 14:16:10 -080032 "nfc_apex_bootclasspath_fragment",
Harshit Mahajan919593c2024-01-17 15:52:22 +000033 "release_crashrecovery_module",
Sandeep Bandaru46f44ce2024-11-26 18:44:20 +000034 "release_ondevice_intelligence_module",
Carmen Jackson32c46ea2024-02-27 04:16:46 +000035 "release_package_profiling_module",
Paul Duffinc67e1df2023-01-09 12:03:59 +000036 ],
37 properties: [
38 "fragments",
39 ],
40}
41
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010042// This module provides access to information Soong has related to the
43// whole platform bootclasspath. Currently, that information is provided solely
44// through configuration but additional information will be added here.
45//
46// This will provide support for the following:
47// * Hidden API processing for those parts of the bootclasspath that are not
48// part of an APEX.
49// * Compatibility checking to ensure that the hidden API bits encoded into the
50// dex files by the modularized hidden API processing is compatible with the
51// runtimes of earlier releases which expect the bits to have been computed
52// over the entirety of the bootclasspath in one go not separately.
53// * Dexpreopting apps and other libraries not on the platform bootclasspath.
54// * Generating and installing the appropriate files to the device which will
55// allow it to generate the bootclasspath related environment variables
56// dynamically.
57//
58// This module needs to be present in the build for the above processing to be
59// done correctly.
Paul Duffinc67e1df2023-01-09 12:03:59 +000060custom_platform_bootclasspath {
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010061 name: "platform-bootclasspath",
Paul Duffin81af1f52021-04-08 19:22:50 +010062
Paul Duffinb2d391d2021-04-08 09:05:39 +010063 // The bootclasspath_fragments that contribute to the platform
64 // bootclasspath.
65 fragments: [
66 {
Neha Pattanfa46dd22022-02-18 19:46:09 +000067 apex: "com.android.adservices",
68 module: "com.android.adservices-bootclasspath-fragment",
69 },
70 {
Artur Satayeve19115d2021-05-25 16:46:33 +000071 apex: "com.android.appsearch",
72 module: "com.android.appsearch-bootclasspath-fragment",
73 },
74 {
Paul Duffinb2d391d2021-04-08 09:05:39 +010075 apex: "com.android.art",
76 module: "art-bootclasspath-fragment",
77 },
Paul Duffinfc8fd102021-04-14 19:17:52 +010078 {
William Escande7b012e92022-06-22 13:19:14 -070079 apex: "com.android.btservices",
80 module: "com.android.btservices-bootclasspath-fragment",
Roopa Sattiraju293ed882022-02-03 09:07:17 -080081 },
82 {
Hassan Ali482f91c2022-10-05 13:16:23 +000083 apex: "com.android.configinfrastructure",
84 module: "com.android.configinfrastructure-bootclasspath-fragment",
85 },
86 {
Artur Satayeve19115d2021-05-25 16:46:33 +000087 apex: "com.android.conscrypt",
88 module: "com.android.conscrypt-bootclasspath-fragment",
89 },
90 {
Amos Bianchi62e8cf32022-08-02 15:42:30 -070091 apex: "com.android.devicelock",
92 module: "com.android.devicelock-bootclasspath-fragment",
93 },
94 {
ronishfc97db52023-02-07 17:57:48 +000095 apex: "com.android.healthfitness",
96 module: "com.android.healthfitness-bootclasspath-fragment",
Anna Zhuravlevabdc7f992022-09-06 10:47:37 +000097 },
98 {
Paul Duffinfc8fd102021-04-14 19:17:52 +010099 apex: "com.android.i18n",
100 module: "i18n-bootclasspath-fragment",
101 },
Artur Satayeve19115d2021-05-25 16:46:33 +0000102 {
103 apex: "com.android.ipsec",
104 module: "com.android.ipsec-bootclasspath-fragment",
105 },
106 {
107 apex: "com.android.media",
108 module: "com.android.media-bootclasspath-fragment",
109 },
110 {
111 apex: "com.android.mediaprovider",
112 module: "com.android.mediaprovider-bootclasspath-fragment",
113 },
114 {
Frank Wange97ff9e2022-02-13 07:06:31 +0000115 apex: "com.android.ondevicepersonalization",
116 module: "com.android.ondevicepersonalization-bootclasspath-fragment",
117 },
118 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000119 apex: "com.android.os.statsd",
120 module: "com.android.os.statsd-bootclasspath-fragment",
121 },
122 {
123 apex: "com.android.permission",
124 module: "com.android.permission-bootclasspath-fragment",
125 },
126 {
127 apex: "com.android.scheduling",
128 module: "com.android.scheduling-bootclasspath-fragment",
129 },
130 {
131 apex: "com.android.sdkext",
132 module: "com.android.sdkext-bootclasspath-fragment",
133 },
134 {
135 apex: "com.android.tethering",
136 module: "com.android.tethering-bootclasspath-fragment",
137 },
138 {
Roshan Pius6c580dd2021-07-29 21:31:23 -0700139 apex: "com.android.uwb",
140 module: "com.android.uwb-bootclasspath-fragment",
141 },
142 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000143 apex: "com.android.wifi",
144 module: "com.android.wifi-bootclasspath-fragment",
145 },
Nikita Ioffeceff6b82022-10-18 23:14:22 +0100146 {
147 apex: "com.android.virt",
148 module: "com.android.virt-bootclasspath-fragment",
149 },
Paul Duffinb2d391d2021-04-08 09:05:39 +0100150 ],
151
Paul Duffinc67e1df2023-01-09 12:03:59 +0000152 soong_config_variables: {
153 car_bootclasspath_fragment: {
154 fragments: [
155 // only used for auto
156 {
157 apex: "com.android.car.framework",
158 module: "com.android.car.framework-bootclasspath-fragment",
159 },
160 ],
161 },
Roshan Pius9667b042024-01-12 14:16:10 -0800162 nfc_apex_bootclasspath_fragment: {
163 fragments: [
164 // only used if NFC mainline is enabled.
165 {
166 apex: "com.android.nfcservices",
167 module: "com.android.nfcservices-bootclasspath-fragment",
168 },
169 ],
170 },
Harshit Mahajan919593c2024-01-17 15:52:22 +0000171 release_crashrecovery_module: {
172 fragments: [
173 // only used when crashrecovery is enabled
174 {
175 apex: "com.android.crashrecovery",
176 module: "com.android.crashrecovery-bootclasspath-fragment",
177 },
178 ],
179 },
Sandeep Bandaru46f44ce2024-11-26 18:44:20 +0000180 release_ondevice_intelligence_module: {
181 fragments: [
182 // only used when ondeviceintelligence is moved to neuralnetworks module
183 {
184 apex: "com.android.neuralnetworks",
185 module: "com.android.ondeviceintelligence-bootclasspath-fragment",
186 },
187 ],
188 },
Carmen Jackson32c46ea2024-02-27 04:16:46 +0000189 release_package_profiling_module: {
190 fragments: [
191 // only used if profiling is enabled.
192 {
193 apex: "com.android.profiling",
194 module: "com.android.profiling-bootclasspath-fragment",
195 },
196 ],
197 },
Paul Duffinc67e1df2023-01-09 12:03:59 +0000198 },
199
Paul Duffin81af1f52021-04-08 19:22:50 +0100200 // Additional information needed by hidden api processing.
201 hidden_api: {
202 unsupported: [
203 "hiddenapi/hiddenapi-unsupported.txt",
204 ],
205 removed: [
206 ":combined-removed-dex",
207 ],
208 max_target_r_low_priority: [
209 "hiddenapi/hiddenapi-max-target-r-loprio.txt",
210 ],
211 max_target_q: [
212 "hiddenapi/hiddenapi-max-target-q.txt",
213 ],
214 max_target_p: [
215 "hiddenapi/hiddenapi-max-target-p.txt",
216 ],
217 max_target_o_low_priority: [
218 "hiddenapi/hiddenapi-max-target-o.txt",
219 ],
Paul Duffin81af1f52021-04-08 19:22:50 +0100220 unsupported_packages: [
221 "hiddenapi/hiddenapi-unsupported-packages.txt",
222 ],
223 },
Paul Duffin3969fad2021-04-12 12:57:06 +0100224
225 dists: [
226 {
227 targets: ["droidcore"],
228 tag: "hiddenapi-flags.csv",
229 },
230 {
231 targets: ["droidcore"],
232 tag: "hiddenapi-index.csv",
233 },
234 {
235 targets: ["droidcore"],
236 tag: "hiddenapi-metadata.csv",
237 // Legacy name
238 dest: "hiddenapi-unsupported.csv",
239 },
240 ],
satayev8e93d882021-04-29 11:54:02 +0100241
242 required: [
243 "platform-systemserverclasspath",
244 ],
245}
246
Cole Faust5aeb9fd2024-10-22 16:30:57 -0700247java_genrule { // This module exists to make the srcjar output available to Make.
Anton Hansson26c63d22023-09-22 10:16:00 +0000248 name: "platform-bootclasspath.srcjar",
249 srcs: [":platform-bootclasspath{.srcjar}"],
250 out: ["platform-bootclasspath.srcjar"],
251 cmd: "cp $(in) $(out)",
252}
253
satayev8e93d882021-04-29 11:54:02 +0100254platform_systemserverclasspath {
255 name: "platform-systemserverclasspath",
Paul Duffin11281142021-01-25 18:31:26 +0000256}