blob: 1b5be9f9145ab874ab029b52903415057b62d0fd [file] [log] [blame]
David Brazdil3f0f1e82023-01-12 16:18:43 +00001package {
2 default_applicable_licenses: ["Android-Apache-2.0"],
3}
4
5rust_defaults {
6 name: "virtualizationmanager_defaults",
7 crate_name: "virtualizationmanager",
8 edition: "2021",
9 // Only build on targets which crosvm builds on.
10 enabled: false,
11 target: {
12 android64: {
13 compile_multilib: "64",
14 enabled: true,
15 },
16 linux_bionic_arm64: {
17 enabled: true,
18 },
19 },
20 prefer_rlib: true,
21 rustlibs: [
22 "android.system.virtualizationcommon-rust",
23 "android.system.virtualizationservice-rust",
24 "android.system.virtualizationservice_internal-rust",
25 "android.system.virtualmachineservice-rust",
26 "android.os.permissions_aidl-rust",
27 "libandroid_logger",
28 "libanyhow",
29 "libapkverify",
Jiyong Parkf4883fc2023-08-10 14:37:46 +090030 "libavfutil",
David Brazdil3f0f1e82023-01-12 16:18:43 +000031 "libbase_rust",
32 "libbinder_rs",
33 "libclap",
34 "libcommand_fds",
35 "libdisk",
Alan Stokesc4d5def2023-02-14 17:01:59 +000036 "libhypervisor_props",
David Brazdil3f0f1e82023-01-12 16:18:43 +000037 "liblazy_static",
38 "liblibc",
39 "liblog_rust",
40 "libmicrodroid_metadata",
41 "libmicrodroid_payload_config",
42 "libnested_virt",
43 "libnix",
44 "libonce_cell",
45 "libregex",
46 "librpcbinder_rs",
47 "librustutils",
48 "libsemver",
49 "libselinux_bindgen",
50 "libserde",
51 "libserde_json",
52 "libserde_xml_rs",
53 "libshared_child",
54 "libstatslog_virtualization_rust",
55 "libtombstoned_client_rust",
56 "libvm_control",
57 "libvmconfig",
58 "libzip",
59 "libvsock",
Jaewan Kim4cf20aa2023-04-03 10:25:38 +090060 "liblibfdt",
David Brazdil3f0f1e82023-01-12 16:18:43 +000061 // TODO(b/202115393) stabilize the interface
62 "packagemanager_aidl-rust",
63 ],
64 shared_libs: [
David Brazdil3f0f1e82023-01-12 16:18:43 +000065 "libselinux",
66 ],
67}
68
69rust_binary {
70 name: "virtmgr",
71 defaults: ["virtualizationmanager_defaults"],
72 srcs: ["src/main.rs"],
73 apex_available: ["com.android.virt"],
74}
75
76rust_test {
77 name: "virtualizationmanager_device_test",
78 srcs: ["src/main.rs"],
79 defaults: ["virtualizationmanager_defaults"],
80 rustlibs: [
81 "libtempfile",
82 ],
Jaewan Kim4cf20aa2023-04-03 10:25:38 +090083 data: [
84 ":test_avf_debug_policy_with_adb",
85 ":test_avf_debug_policy_without_adb",
86 ],
David Brazdil3f0f1e82023-01-12 16:18:43 +000087 test_suites: ["general-tests"],
88}