blob: 228d060bf9cffa059790ec185a785617cb313c7b [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",
Paul Duffinc67e1df2023-01-09 12:03:59 +000034 ],
35 properties: [
36 "fragments",
37 ],
38}
39
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010040// This module provides access to information Soong has related to the
41// whole platform bootclasspath. Currently, that information is provided solely
42// through configuration but additional information will be added here.
43//
44// This will provide support for the following:
45// * Hidden API processing for those parts of the bootclasspath that are not
46// part of an APEX.
47// * Compatibility checking to ensure that the hidden API bits encoded into the
48// dex files by the modularized hidden API processing is compatible with the
49// runtimes of earlier releases which expect the bits to have been computed
50// over the entirety of the bootclasspath in one go not separately.
51// * Dexpreopting apps and other libraries not on the platform bootclasspath.
52// * Generating and installing the appropriate files to the device which will
53// allow it to generate the bootclasspath related environment variables
54// dynamically.
55//
56// This module needs to be present in the build for the above processing to be
57// done correctly.
Paul Duffinc67e1df2023-01-09 12:03:59 +000058custom_platform_bootclasspath {
Paul Duffin3e4ec3b2021-04-01 11:53:32 +010059 name: "platform-bootclasspath",
Paul Duffin81af1f52021-04-08 19:22:50 +010060
Paul Duffinb2d391d2021-04-08 09:05:39 +010061 // The bootclasspath_fragments that contribute to the platform
62 // bootclasspath.
63 fragments: [
64 {
Neha Pattanfa46dd22022-02-18 19:46:09 +000065 apex: "com.android.adservices",
66 module: "com.android.adservices-bootclasspath-fragment",
67 },
68 {
Artur Satayeve19115d2021-05-25 16:46:33 +000069 apex: "com.android.appsearch",
70 module: "com.android.appsearch-bootclasspath-fragment",
71 },
72 {
Paul Duffinb2d391d2021-04-08 09:05:39 +010073 apex: "com.android.art",
74 module: "art-bootclasspath-fragment",
75 },
Paul Duffinfc8fd102021-04-14 19:17:52 +010076 {
William Escande7b012e92022-06-22 13:19:14 -070077 apex: "com.android.btservices",
78 module: "com.android.btservices-bootclasspath-fragment",
Roopa Sattiraju293ed882022-02-03 09:07:17 -080079 },
80 {
Hassan Ali482f91c2022-10-05 13:16:23 +000081 apex: "com.android.configinfrastructure",
82 module: "com.android.configinfrastructure-bootclasspath-fragment",
83 },
84 {
Artur Satayeve19115d2021-05-25 16:46:33 +000085 apex: "com.android.conscrypt",
86 module: "com.android.conscrypt-bootclasspath-fragment",
87 },
88 {
Amos Bianchi62e8cf32022-08-02 15:42:30 -070089 apex: "com.android.devicelock",
90 module: "com.android.devicelock-bootclasspath-fragment",
91 },
92 {
ronishfc97db52023-02-07 17:57:48 +000093 apex: "com.android.healthfitness",
94 module: "com.android.healthfitness-bootclasspath-fragment",
Anna Zhuravlevabdc7f992022-09-06 10:47:37 +000095 },
96 {
Paul Duffinfc8fd102021-04-14 19:17:52 +010097 apex: "com.android.i18n",
98 module: "i18n-bootclasspath-fragment",
99 },
Artur Satayeve19115d2021-05-25 16:46:33 +0000100 {
101 apex: "com.android.ipsec",
102 module: "com.android.ipsec-bootclasspath-fragment",
103 },
104 {
105 apex: "com.android.media",
106 module: "com.android.media-bootclasspath-fragment",
107 },
108 {
109 apex: "com.android.mediaprovider",
110 module: "com.android.mediaprovider-bootclasspath-fragment",
111 },
112 {
Frank Wange97ff9e2022-02-13 07:06:31 +0000113 apex: "com.android.ondevicepersonalization",
114 module: "com.android.ondevicepersonalization-bootclasspath-fragment",
115 },
116 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000117 apex: "com.android.os.statsd",
118 module: "com.android.os.statsd-bootclasspath-fragment",
119 },
120 {
121 apex: "com.android.permission",
122 module: "com.android.permission-bootclasspath-fragment",
123 },
124 {
125 apex: "com.android.scheduling",
126 module: "com.android.scheduling-bootclasspath-fragment",
127 },
128 {
129 apex: "com.android.sdkext",
130 module: "com.android.sdkext-bootclasspath-fragment",
131 },
132 {
133 apex: "com.android.tethering",
134 module: "com.android.tethering-bootclasspath-fragment",
135 },
136 {
Roshan Pius6c580dd2021-07-29 21:31:23 -0700137 apex: "com.android.uwb",
138 module: "com.android.uwb-bootclasspath-fragment",
139 },
140 {
Artur Satayeve19115d2021-05-25 16:46:33 +0000141 apex: "com.android.wifi",
142 module: "com.android.wifi-bootclasspath-fragment",
143 },
Nikita Ioffeceff6b82022-10-18 23:14:22 +0100144 {
145 apex: "com.android.virt",
146 module: "com.android.virt-bootclasspath-fragment",
147 },
Paul Duffinb2d391d2021-04-08 09:05:39 +0100148 ],
149
Paul Duffinc67e1df2023-01-09 12:03:59 +0000150 soong_config_variables: {
151 car_bootclasspath_fragment: {
152 fragments: [
153 // only used for auto
154 {
155 apex: "com.android.car.framework",
156 module: "com.android.car.framework-bootclasspath-fragment",
157 },
158 ],
159 },
Roshan Pius9667b042024-01-12 14:16:10 -0800160 nfc_apex_bootclasspath_fragment: {
161 fragments: [
162 // only used if NFC mainline is enabled.
163 {
164 apex: "com.android.nfcservices",
165 module: "com.android.nfcservices-bootclasspath-fragment",
166 },
167 ],
168 },
Harshit Mahajan919593c2024-01-17 15:52:22 +0000169 release_crashrecovery_module: {
170 fragments: [
171 // only used when crashrecovery is enabled
172 {
173 apex: "com.android.crashrecovery",
174 module: "com.android.crashrecovery-bootclasspath-fragment",
175 },
176 ],
177 },
Paul Duffinc67e1df2023-01-09 12:03:59 +0000178 },
179
Paul Duffin81af1f52021-04-08 19:22:50 +0100180 // Additional information needed by hidden api processing.
181 hidden_api: {
182 unsupported: [
183 "hiddenapi/hiddenapi-unsupported.txt",
184 ],
185 removed: [
186 ":combined-removed-dex",
187 ],
188 max_target_r_low_priority: [
189 "hiddenapi/hiddenapi-max-target-r-loprio.txt",
190 ],
191 max_target_q: [
192 "hiddenapi/hiddenapi-max-target-q.txt",
193 ],
194 max_target_p: [
195 "hiddenapi/hiddenapi-max-target-p.txt",
196 ],
197 max_target_o_low_priority: [
198 "hiddenapi/hiddenapi-max-target-o.txt",
199 ],
Paul Duffin81af1f52021-04-08 19:22:50 +0100200 unsupported_packages: [
201 "hiddenapi/hiddenapi-unsupported-packages.txt",
202 ],
203 },
Paul Duffin3969fad2021-04-12 12:57:06 +0100204
205 dists: [
206 {
207 targets: ["droidcore"],
208 tag: "hiddenapi-flags.csv",
209 },
210 {
211 targets: ["droidcore"],
212 tag: "hiddenapi-index.csv",
213 },
214 {
215 targets: ["droidcore"],
216 tag: "hiddenapi-metadata.csv",
217 // Legacy name
218 dest: "hiddenapi-unsupported.csv",
219 },
220 ],
satayev8e93d882021-04-29 11:54:02 +0100221
222 required: [
223 "platform-systemserverclasspath",
224 ],
225}
226
Anton Hansson26c63d22023-09-22 10:16:00 +0000227genrule { // This module exists to make the srcjar output available to Make.
228 name: "platform-bootclasspath.srcjar",
229 srcs: [":platform-bootclasspath{.srcjar}"],
230 out: ["platform-bootclasspath.srcjar"],
231 cmd: "cp $(in) $(out)",
232}
233
satayev8e93d882021-04-29 11:54:02 +0100234platform_systemserverclasspath {
235 name: "platform-systemserverclasspath",
Paul Duffin11281142021-01-25 18:31:26 +0000236}