1// Copyright (C) 2023 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_team: "trendy_team_rubidium_sdk_runtime", 17 default_applicable_licenses: ["Android-Apache-2.0"], 18} 19 20filegroup { 21 name: "sdksandbox-service-proto", 22 srcs: [ 23 "*.proto", 24 ], 25} 26 27genrule_defaults { 28 name: "gen_platform_api_allowlist_per_target_sdk_version", 29 tools: ["aprotoc"], 30 tool_files: ["Verifier.proto"], 31 cmd: "$(location aprotoc) --encode=com.android.server.sdksandbox.proto.AllowedApisPerTargetSdk " + 32 "-I $$(dirname $(location Verifier.proto))" + 33 " $(location Verifier.proto) < $(in) > $(out)", 34 visibility: [ 35 "//packages/modules/AdServices/sdksandbox/service", 36 ], 37} 38 39genrule { 40 name: "platform_api_allowlist_per_target_sdk_version_current.binarypb", 41 defaults: ["gen_platform_api_allowlist_per_target_sdk_version"], 42 srcs: ["platform_api_allowlist_per_target_sdk_version_current.textproto"], 43 out: ["platform_api_allowlist_per_target_sdk_version_current.binarypb"], 44} 45 46// Generate the Proto builders, etc. 47java_library { 48 name: "sdksandbox-service-proto-lite", 49 sdk_version: "core_current", 50 proto: { 51 type: "lite", 52 include_dirs: [ 53 "external/protobuf/src", 54 "external/protobuf/java", 55 ], 56 }, 57 srcs: [ 58 ":sdksandbox-service-proto", 59 ":libprotobuf-internal-protos", 60 ], 61 static_libs: ["libprotobuf-java-lite"], 62 apex_available: ["com.android.adservices"], 63} 64