1// Copyright (C) 2022 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 15package { 16 default_applicable_licenses: ["Android-Apache-2.0"], 17} 18 19apex_key { 20 name: "com.android.adservices.key", 21 public_key: "com.android.adservices.avbpubkey", 22 private_key: "com.android.adservices.pem", 23} 24 25android_app_certificate { 26 name: "com.android.adservices.certificate", 27 certificate: "com.android.adservices", 28} 29 30apex { 31 name: "com.android.adservices", 32 manifest: "manifest.json", 33 apps: [ 34 "AdServicesApk", 35 "SdkSandbox", 36 ], 37 file_contexts: ":com.android.adservices-file_contexts", 38 key: "com.android.adservices.key", 39 bootclasspath_fragments: ["com.android.adservices-bootclasspath-fragment"], 40 systemserverclasspath_fragments: ["com.android.adservices-systemserverclasspath-fragment"], 41 prebuilts: [ 42 "current_sdkinfo", 43 ], 44 certificate: ":com.android.adservices.certificate", 45 defaults: ["t-launched-apex-module"], 46 jni_libs: [ 47 "libtflite_support_classifiers_native", 48 "libhpke_jni", 49 ], 50} 51 52sdk { 53 name: "adservices-module-sdk", 54 apexes: [ 55 // Adds exportable dependencies of the APEX to the sdk, 56 // e.g. *classpath_fragments. 57 "com.android.adservices", 58 ], 59} 60 61systemserverclasspath_fragment { 62 name: "com.android.adservices-systemserverclasspath-fragment", 63 contents: [ 64 "service-adservices", 65 "service-sdksandbox", 66 ], 67 apex_available: ["com.android.adservices"], 68} 69 70// Encapsulate the contributions made by com.android.adservices to the bootclasspath. 71bootclasspath_fragment { 72 name: "com.android.adservices-bootclasspath-fragment", 73 contents: [ 74 "framework-adservices", 75 "framework-sdksandbox", 76 ], 77 apex_available: ["com.android.adservices"], 78 79 // The bootclasspath_fragments that provide APIs on which this depends. 80 fragments: [ 81 { 82 apex: "com.android.art", 83 module: "art-bootclasspath-fragment", 84 }, 85 ], 86 87 // Additional stubs libraries that this fragment's contents use which are 88 // not provided by another bootclasspath_fragment. 89 additional_stubs: [ 90 "android-non-updatable", 91 ], 92 93 hidden_api: { 94 // The following packages contain classes from other modules on the 95 // bootclasspath. That means that the hidden API flags for this module 96 // has to explicitly list every single class this module provides in 97 // that package to differentiate them from the classes provided by other 98 // modules. That can include private classes that are not part of the 99 // API. 100 split_packages: [ 101 "android.adservices", 102 ], 103 104 // The following packages and all their subpackages currently only 105 // contain classes from this bootclasspath_fragment. Listing a package 106 // here won't prevent other bootclasspath modules from adding classes in 107 // any of those packages but it will prevent them from adding those 108 // classes into an API surface, e.g. public, system, etc.. Doing so will 109 // result in a build failure due to inconsistent flags. 110 package_prefixes: [ 111 "android.adservices.adid", 112 "android.adservices.adselection", 113 "android.adservices.appsetid", 114 "android.adservices.cobalt", 115 "android.adservices.common", 116 "android.adservices.customaudience", 117 "android.adservices.exceptions", 118 "android.adservices.extdata", 119 "android.adservices.measurement", 120 "android.adservices.shell", 121 "android.adservices.signals", 122 "android.adservices.topics", 123 "android.app.adservices", 124 "android.app.sdksandbox", 125 "com.android.adservices", 126 ], 127 }, 128} 129