1// 2// Copyright (C) 2023 The Android Open Source Project 3// 4// Licensed under the Apache License, Version 2.0 (the "License"); 5// you may not use this file except in compliance with the License. 6// You may obtain a copy of the License at 7// 8// http://www.apache.org/licenses/LICENSE-2.0 9// 10// Unless required by applicable law or agreed to in writing, software 11// distributed under the License is distributed on an "AS IS" BASIS, 12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13// See the License for the specific language governing permissions and 14// limitations under the License. 15// 16package { 17 // See: http://go/android-license-faq 18 // A large-scale-change added 'default_applicable_licenses' to import 19 // all of the 'license_kinds' from "hardware_interfaces_license" 20 // to get the below license kinds: 21 // SPDX-license-identifier-Apache-2.0 22 default_applicable_licenses: ["hardware_interfaces_license"], 23} 24 25rust_library { 26 name: "libauthgraph_nonsecure", 27 crate_name: "authgraph_nonsecure", 28 defaults: [ 29 "authgraph_use_latest_hal_aidl_rust", 30 ], 31 vendor_available: true, 32 rustlibs: [ 33 "libandroid_logger", 34 "libauthgraph_boringssl", 35 "libauthgraph_core", 36 "libauthgraph_hal", 37 "libbinder_rs", 38 "liblibc", 39 "liblog_rust", 40 ], 41 srcs: ["src/lib.rs"], 42 43} 44 45rust_binary { 46 name: "android.hardware.security.authgraph-service.nonsecure", 47 relative_install_path: "hw", 48 vendor: true, 49 installable: false, // install com.android.hardware.security.authgraph 50 defaults: [ 51 "authgraph_use_latest_hal_aidl_rust", 52 ], 53 prefer_rlib: true, 54 rustlibs: [ 55 "libandroid_logger", 56 "libauthgraph_hal", 57 "libauthgraph_nonsecure", 58 "libbinder_rs", 59 "liblibc", 60 "liblog_rust", 61 ], 62 srcs: [ 63 "src/main.rs", 64 ], 65} 66 67rust_fuzz { 68 name: "android.hardware.authgraph-service.nonsecure_fuzzer", 69 rustlibs: [ 70 "libauthgraph_hal", 71 "libauthgraph_nonsecure", 72 "libbinder_random_parcel_rs", 73 "libbinder_rs", 74 ], 75 srcs: ["src/fuzzer.rs"], 76 fuzz_config: { 77 cc: [ 78 "drysdale@google.com", 79 "hasinitg@google.com", 80 ], 81 }, 82} 83 84prebuilt_etc { 85 name: "authgraph.xml", 86 src: "authgraph.xml", 87 sub_dir: "vintf", 88 installable: false, 89} 90 91prebuilt_etc { 92 name: "authgraph.rc", 93 src: "authgraph.rc", 94 installable: false, 95} 96 97apex { 98 name: "com.android.hardware.security.authgraph", 99 manifest: "apex_manifest.json", 100 file_contexts: "apex_file_contexts", 101 key: "com.android.hardware.key", 102 certificate: ":com.android.hardware.certificate", 103 vendor: true, 104 updatable: false, 105 106 binaries: [ 107 "android.hardware.security.authgraph-service.nonsecure", 108 ], 109 prebuilts: [ 110 "authgraph.rc", 111 "authgraph.xml", 112 ], 113} 114