1package { 2 default_team: "trendy_team_fwk_uwb", 3 default_applicable_licenses: ["Android-Apache-2.0"], 4} 5 6rust_defaults { 7 name: "libuwb_uci_jni_rust_defaults", 8 crate_name: "uwb_uci_jni_rust", 9 lints: "android", 10 clippy_lints: "android", 11 min_sdk_version: "Tiramisu", 12 srcs: ["src/lib.rs"], 13 rustlibs: [ 14 "libbinder_rs", 15 "libjni_legacy", 16 "liblazy_static", 17 "liblog_rust", 18 "liblogger", 19 "libnum_traits", 20 "libthiserror", 21 "libtokio", 22 "libuwb_uci_packets", 23 ], 24 prefer_rlib: true, 25 apex_available: [ 26 "com.android.uwb", 27 ], 28} 29 30rust_ffi_shared { 31 name: "libuwb_uci_jni_rust", 32 defaults: ["libuwb_uci_jni_rust_defaults"], 33 rustlibs: [ 34 "libuci_hal_android", 35 "libuwb_core", 36 ], 37} 38 39rust_test { 40 name: "libuwb_uci_jni_rust_tests", 41 defaults: ["libuwb_uci_jni_rust_defaults"], 42 rustlibs: [ 43 "libuci_hal_android_with_mock", 44 "libuwb_core_with_mock", 45 ], 46 target: { 47 android: { 48 test_suites: [ 49 "general-tests", 50 "mts-uwb", 51 ], 52 test_config_template: "uwb_rust_test_config_template.xml", 53 }, 54 }, 55 test_options: { 56 unit_test: true, 57 }, 58 // Support multilib variants (using different suffix per sub-architecture), which is needed on 59 // build targets with secondary architectures, as the MTS test suite packaging logic flattens 60 // all test artifacts into a single `testcases` directory. 61 compile_multilib: "both", 62 multilib: { 63 lib32: { 64 suffix: "32", 65 }, 66 lib64: { 67 suffix: "64", 68 }, 69 }, 70 auto_gen_config: true, 71 native_coverage: false, 72} 73