blob: f60bb9e7149a9e619ee933e5587dbad0116dd25c [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",
Carmen Jackson32c46ea2024-02-27 04:16:46 +000034 "release_package_profiling_module",
Paul Duffinc67e1df2023-01-09 12:03:59 +000035 ],
36 properties: [
37 "fragments",
38 ],
39}
40
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010041// This module provides access to information Soong has related to the
42// whole platform bootclasspath. Currently, that information is provided solely
43// through configuration but additional information will be added here.
44//
45// This will provide support for the following:
46// * Hidden API processing for those parts of the bootclasspath that are not
47// part of an APEX.
48// * Compatibility checking to ensure that the hidden API bits encoded into the
49// dex files by the modularized hidden API processing is compatible with the
50// runtimes of earlier releases which expect the bits to have been computed
51// over the entirety of the bootclasspath in one go not separately.
52// * Dexpreopting apps and other libraries not on the platform bootclasspath.
53// * Generating and installing the appropriate files to the device which will
54// allow it to generate the bootclasspath related environment variables
55// dynamically.
56//
57// This module needs to be present in the build for the above processing to be
58// done correctly.
Paul Duffinc67e1df2023-01-09 12:03:59 +000059custom_platform_bootclasspath {
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010060 name: "platform-bootclasspath",
Paul Duffin81af1f52021-04-08 19:22:50 +010061
Paul Duffinb2d391d2021-04-08 09:05:39 +010062 // The bootclasspath_fragments that contribute to the platform
63 // bootclasspath.
64 fragments: [
65 {
Neha Pattanfa46dd22022-02-18 19:46:09 +000066 apex: "com.android.adservices",
67 module: "com.android.adservices-bootclasspath-fragment",
68 },
69 {
Artur Satayeve19115d2021-05-25 16:46:33 +000070 apex: "com.android.appsearch",
71 module: "com.android.appsearch-bootclasspath-fragment",
72 },
73 {
Paul Duffinb2d391d2021-04-08 09:05:39 +010074 apex: "com.android.art",
75 module: "art-bootclasspath-fragment",
76 },
Paul Duffinfc8fd102021-04-14 19:17:52 +010077 {
William Escande7b012e92022-06-22 13:19:14 -070078 apex: "com.android.btservices",
79 module: "com.android.btservices-bootclasspath-fragment",
Roopa Sattiraju293ed882022-02-03 09:07:17 -080080 },
81 {
Hassan Ali482f91c2022-10-05 13:16:23 +000082 apex: "com.android.configinfrastructure",
83 module: "com.android.configinfrastructure-bootclasspath-fragment",
84 },
85 {
Artur Satayeve19115d2021-05-25 16:46:33 +000086 apex: "com.android.conscrypt",
87 module: "com.android.conscrypt-bootclasspath-fragment",
88 },
89 {
Amos Bianchi62e8cf32022-08-02 15:42:30 -070090 apex: "com.android.devicelock",
91 module: "com.android.devicelock-bootclasspath-fragment",
92 },
93 {
ronishfc97db52023-02-07 17:57:48 +000094 apex: "com.android.healthfitness",
95 module: "com.android.healthfitness-bootclasspath-fragment",
Anna Zhuravlevabdc7f992022-09-06 10:47:37 +000096 },
97 {
Paul Duffinfc8fd102021-04-14 19:17:52 +010098 apex: "com.android.i18n",
99 module: "i18n-bootclasspath-fragment",
100 },
Artur Satayeve19115d2021-05-25 16:46:33 +0000101 {
102 apex: "com.android.ipsec",
103 module: "com.android.ipsec-bootclasspath-fragment",
104 },
105 {
106 apex: "com.android.media",
107 module: "com.android.media-bootclasspath-fragment",
108 },
109 {
110 apex: "com.android.mediaprovider",
111 module: "com.android.mediaprovider-bootclasspath-fragment",
112 },
113 {
Frank Wange97ff9e2022-02-13 07:06:31 +0000114 apex: "com.android.ondevicepersonalization",
115 module: "com.android.ondevicepersonalization-bootclasspath-fragment",
116 },
117 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000118 apex: "com.android.os.statsd",
119 module: "com.android.os.statsd-bootclasspath-fragment",
120 },
121 {
122 apex: "com.android.permission",
123 module: "com.android.permission-bootclasspath-fragment",
124 },
125 {
126 apex: "com.android.scheduling",
127 module: "com.android.scheduling-bootclasspath-fragment",
128 },
129 {
130 apex: "com.android.sdkext",
131 module: "com.android.sdkext-bootclasspath-fragment",
132 },
133 {
134 apex: "com.android.tethering",
135 module: "com.android.tethering-bootclasspath-fragment",
136 },
137 {
Roshan Pius6c580dd2021-07-29 21:31:23 -0700138 apex: "com.android.uwb",
139 module: "com.android.uwb-bootclasspath-fragment",
140 },
141 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000142 apex: "com.android.wifi",
143 module: "com.android.wifi-bootclasspath-fragment",
144 },
Nikita Ioffeceff6b82022-10-18 23:14:22 +0100145 {
146 apex: "com.android.virt",
147 module: "com.android.virt-bootclasspath-fragment",
148 },
Paul Duffinb2d391d2021-04-08 09:05:39 +0100149 ],
150
Paul Duffinc67e1df2023-01-09 12:03:59 +0000151 soong_config_variables: {
152 car_bootclasspath_fragment: {
153 fragments: [
154 // only used for auto
155 {
156 apex: "com.android.car.framework",
157 module: "com.android.car.framework-bootclasspath-fragment",
158 },
159 ],
160 },
Roshan Pius9667b042024-01-12 14:16:10 -0800161 nfc_apex_bootclasspath_fragment: {
162 fragments: [
163 // only used if NFC mainline is enabled.
164 {
165 apex: "com.android.nfcservices",
166 module: "com.android.nfcservices-bootclasspath-fragment",
167 },
168 ],
169 },
Harshit Mahajan919593c2024-01-17 15:52:22 +0000170 release_crashrecovery_module: {
171 fragments: [
172 // only used when crashrecovery is enabled
173 {
174 apex: "com.android.crashrecovery",
175 module: "com.android.crashrecovery-bootclasspath-fragment",
176 },
177 ],
178 },
Carmen Jackson32c46ea2024-02-27 04:16:46 +0000179 release_package_profiling_module: {
180 fragments: [
181 // only used if profiling is enabled.
182 {
183 apex: "com.android.profiling",
184 module: "com.android.profiling-bootclasspath-fragment",
185 },
186 ],
187 },
Paul Duffinc67e1df2023-01-09 12:03:59 +0000188 },
189
Paul Duffin81af1f52021-04-08 19:22:50 +0100190 // Additional information needed by hidden api processing.
191 hidden_api: {
192 unsupported: [
193 "hiddenapi/hiddenapi-unsupported.txt",
194 ],
195 removed: [
196 ":combined-removed-dex",
197 ],
198 max_target_r_low_priority: [
199 "hiddenapi/hiddenapi-max-target-r-loprio.txt",
200 ],
201 max_target_q: [
202 "hiddenapi/hiddenapi-max-target-q.txt",
203 ],
204 max_target_p: [
205 "hiddenapi/hiddenapi-max-target-p.txt",
206 ],
207 max_target_o_low_priority: [
208 "hiddenapi/hiddenapi-max-target-o.txt",
209 ],
Paul Duffin81af1f52021-04-08 19:22:50 +0100210 unsupported_packages: [
211 "hiddenapi/hiddenapi-unsupported-packages.txt",
212 ],
213 },
Paul Duffin3969fad2021-04-12 12:57:06 +0100214
215 dists: [
216 {
217 targets: ["droidcore"],
218 tag: "hiddenapi-flags.csv",
219 },
220 {
221 targets: ["droidcore"],
222 tag: "hiddenapi-index.csv",
223 },
224 {
225 targets: ["droidcore"],
226 tag: "hiddenapi-metadata.csv",
227 // Legacy name
228 dest: "hiddenapi-unsupported.csv",
229 },
230 ],
satayev8e93d882021-04-29 11:54:02 +0100231
232 required: [
233 "platform-systemserverclasspath",
234 ],
235}
236
Anton Hansson26c63d22023-09-22 10:16:00 +0000237genrule { // This module exists to make the srcjar output available to Make.
238 name: "platform-bootclasspath.srcjar",
239 srcs: [":platform-bootclasspath{.srcjar}"],
240 out: ["platform-bootclasspath.srcjar"],
241 cmd: "cp $(in) $(out)",
242}
243
satayev8e93d882021-04-29 11:54:02 +0100244platform_systemserverclasspath {
245 name: "platform-systemserverclasspath",
Paul Duffin11281142021-01-25 18:31:26 +0000246}