| package { | |
| default_applicable_licenses: ["Android-Apache-2.0"], | |
| } | |
| rust_defaults { | |
| name: "virtualizationmanager_defaults", | |
| crate_name: "virtualizationmanager", | |
| crate_root: "src/main.rs", | |
| defaults: [ | |
| "avf_build_flags_rust", | |
| "secretkeeper_use_latest_hal_aidl_rust", | |
| "authgraph_use_latest_hal_aidl_rust", | |
| ], | |
| edition: "2021", | |
| // Only build on targets which crosvm builds on. | |
| enabled: false, | |
| target: { | |
| android64: { | |
| compile_multilib: "64", | |
| enabled: true, | |
| }, | |
| linux_bionic_arm64: { | |
| enabled: true, | |
| }, | |
| }, | |
| prefer_rlib: true, | |
| rustlibs: [ | |
| "android.frameworks.stats-V2-rust", | |
| "android.hardware.virtualization.capabilities.capabilities_service-V1-rust", | |
| "android.system.virtualizationcommon-rust", | |
| "android.system.virtualizationservice-rust", | |
| "android.system.virtualizationservice_internal-rust", | |
| "android.system.virtualmachineservice-rust", | |
| "android.os.permissions_aidl-rust", | |
| "libavf_aconfig_flags_rust", | |
| "libandroid_logger", | |
| "libanyhow", | |
| "libapkverify", | |
| "libavf_features", | |
| "libavflog", | |
| "libbinder_rs", | |
| "libcfg_if", | |
| "libclap", | |
| "libcrosvm_control_static", | |
| "libcommand_fds", | |
| "libdisk", | |
| "libdm_rust", | |
| "libdropbox_rs", | |
| "libglob", | |
| "libhex", | |
| "libhypervisor_props", | |
| "liblibc", | |
| "liblog_rust", | |
| "libmicrodroid_metadata", | |
| "libmicrodroid_payload_config", | |
| "libhw_timeout_multiplier", | |
| "libnix", | |
| "libonce_cell", | |
| "libpsi_rs", | |
| "libregex", | |
| "librpcbinder_rs", | |
| "librustutils", | |
| "libsemver", | |
| "libselinux_bindgen", | |
| "libserde", | |
| "libserde_json", | |
| "libserde_xml_rs", | |
| "libshared_child", | |
| "libstatslog_virtualization_rust", | |
| "libtombstoned_client_rust", | |
| "libvbmeta_rust", | |
| "libvmconfig", | |
| "libzip", | |
| "libvsock", | |
| "liblibfdt", | |
| "libfsfdt", | |
| "libhypervisor_props", | |
| "libzerocopy", | |
| "libuuid", | |
| "libscopeguard", | |
| // TODO(b/202115393) stabilize the interface | |
| "packagemanager_aidl-rust", | |
| "rpc_servicemanager_aidl-rust", | |
| ], | |
| shared_libs: [ | |
| "libselinux", | |
| ], | |
| srcs: [":security_vm_instance_id"], | |
| } | |
| rust_binary { | |
| name: "virtmgr", | |
| defaults: ["virtualizationmanager_defaults"], | |
| apex_available: ["com.android.virt"], | |
| } | |
| rust_binary { | |
| name: "early_virtmgr", | |
| defaults: ["virtualizationmanager_defaults"], | |
| srcs: ["src/main.rs"], | |
| cfgs: ["early"], | |
| apex_available: ["com.android.virt"], | |
| } | |
| xsd_config { | |
| name: "early_vms", | |
| srcs: ["early_vms.xsd"], | |
| api_dir: "schema", | |
| package_name: "android.system.virtualizationservice", | |
| } | |
| rust_test { | |
| name: "virtualizationmanager_device_test", | |
| srcs: ["src/main.rs"], | |
| defaults: ["virtualizationmanager_defaults"], | |
| rustlibs: [ | |
| "libtempfile", | |
| ], | |
| data: [ | |
| ":test_avf_debug_policy_with_ramdump", | |
| ":test_avf_debug_policy_without_ramdump", | |
| ":test_avf_debug_policy_with_adb", | |
| ":test_avf_debug_policy_without_adb", | |
| ":test_avf_reference_dt_fs", | |
| ], | |
| test_suites: ["general-tests"], | |
| } |