| // Copyright 2020, The Android Open Source Project |
| // |
| // Licensed under the Apache License, Version 2.0 (the "License"); |
| // you may not use this file except in compliance with the License. |
| // You may obtain a copy of the License at |
| // |
| // http://www.apache.org/licenses/LICENSE-2.0 |
| // |
| // Unless required by applicable law or agreed to in writing, software |
| // distributed under the License is distributed on an "AS IS" BASIS, |
| // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| // See the License for the specific language governing permissions and |
| // limitations under the License. |
| |
| rust_library { |
| name: "libkeystore2", |
| crate_name: "keystore2", |
| srcs: ["src/lib.rs"], |
| |
| rustlibs: [ |
| "android.hardware.security.keymint-V1-rust", |
| "android.hardware.security.secureclock-V1-rust", |
| "android.security.apc-rust", |
| "android.security.authorization-rust", |
| "android.security.compat-rust", |
| "android.security.remoteprovisioning-rust", |
| "android.system.keystore2-V1-rust", |
| "libanyhow", |
| "libbinder_rs", |
| "libkeystore2_aaid-rust", |
| "libkeystore2_apc_compat-rust", |
| "libkeystore2_crypto_rust", |
| "libkeystore2_km_compat", |
| "libkeystore2_selinux", |
| "liblazy_static", |
| "liblibc", |
| "liblibsqlite3_sys", |
| "liblog_rust", |
| "librand", |
| "librusqlite", |
| "libthiserror", |
| ], |
| } |
| |
| rust_library { |
| name: "libkeystore2_test_utils", |
| crate_name: "keystore2_test_utils", |
| srcs: ["test_utils/lib.rs"], |
| rustlibs: [ |
| "liblog_rust", |
| "librand", |
| ] |
| } |
| |
| rust_test { |
| name: "keystore2_test", |
| crate_name: "keystore2", |
| srcs: ["src/lib.rs"], |
| test_suites: ["general-tests"], |
| auto_gen_config: true, |
| rustlibs: [ |
| "android.hardware.security.keymint-V1-rust", |
| "android.hardware.security.secureclock-V1-rust", |
| "android.security.apc-rust", |
| "android.security.authorization-rust", |
| "android.security.compat-rust", |
| "android.security.remoteprovisioning-rust", |
| "android.system.keystore2-V1-rust", |
| "libandroid_logger", |
| "libanyhow", |
| "libbinder_rs", |
| "libkeystore2_aaid-rust", |
| "libkeystore2_apc_compat-rust", |
| "libkeystore2_crypto_rust", |
| "libkeystore2_km_compat", |
| "libkeystore2_selinux", |
| "libkeystore2_test_utils", |
| "liblazy_static", |
| "liblibc", |
| "liblibsqlite3_sys", |
| "liblog_rust", |
| "librand", |
| "librusqlite", |
| "libthiserror", |
| ], |
| } |
| |
| rust_binary { |
| name: "keystore2", |
| srcs: ["src/keystore2_main.rs"], |
| rustlibs: [ |
| "libandroid_logger", |
| "libbinder_rs", |
| "libkeystore2", |
| "liblog_rust", |
| ], |
| init_rc: ["keystore2.rc"], |
| } |