xref: /aosp_15_r20/system/secretkeeper/hal/Android.bp (revision 3f8e9d82f4020c68ad19a99fc5fdc1fc90b79379)
1// Copyright 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_applicable_licenses: ["system_secretkeeper_license"],
17}
18
19rust_defaults {
20    name: "libsecretkeeper_hal_defaults",
21    crate_name: "secretkeeper_hal",
22    srcs: ["src/lib.rs"],
23    vendor_available: true,
24    defaults: [
25        "authgraph_use_latest_hal_aidl_rust",
26    ],
27    rustlibs: [
28        "libauthgraph_hal",
29        "libbinder_rs",
30        "libcoset",
31        "liblog_rust",
32        "libsecretkeeper_comm_nostd",
33    ],
34}
35
36rust_library {
37    name: "libsecretkeeper_hal",
38    defaults: [
39        "libsecretkeeper_hal_defaults",
40        "secretkeeper_use_latest_hal_aidl_rust",
41    ],
42    features: [
43        "hal_v2",
44    ],
45}
46
47rust_library {
48    name: "libsecretkeeper_hal_v1",
49    defaults: [
50        "libsecretkeeper_hal_defaults",
51    ],
52    rustlibs: [
53        "android.hardware.security.secretkeeper-V1-rust",
54    ],
55}
56