69 lines
1.6 KiB
Plaintext
69 lines
1.6 KiB
Plaintext
package {
|
|
// See: http://go/android-license-faq
|
|
// A large-scale-change added 'default_applicable_licenses' to import
|
|
// all of the 'license_kinds' from "system_bt_license"
|
|
// to get the below license kinds:
|
|
// SPDX-license-identifier-Apache-2.0
|
|
default_applicable_licenses: ["system_bt_license"],
|
|
}
|
|
|
|
rust_ffi {
|
|
name: "liblmp",
|
|
host_supported: true,
|
|
vendor_available : true,
|
|
crate_name: "lmp",
|
|
srcs: [
|
|
"src/lib.rs",
|
|
":LmpGeneratedPackets_rust",
|
|
],
|
|
edition: "2018",
|
|
proc_macros: ["libnum_derive"],
|
|
rustlibs: [
|
|
"libbt_packets_nonapex",
|
|
"libbytes",
|
|
"libnum_bigint",
|
|
"libnum_integer",
|
|
"libnum_traits",
|
|
"libthiserror",
|
|
"libpin_utils",
|
|
"librand",
|
|
],
|
|
include_dirs: ["include"],
|
|
}
|
|
|
|
genrule {
|
|
name: "LmpGeneratedPackets_rust",
|
|
tools: [
|
|
"bluetooth_packetgen",
|
|
],
|
|
cmd: "$(location bluetooth_packetgen) --include=packages/modules/Bluetooth/tools/rootcanal/lmp --out=$(genDir) $(in) --rust",
|
|
srcs: [
|
|
"lmp_packets.pdl",
|
|
],
|
|
out: [
|
|
"lmp_packets.rs",
|
|
],
|
|
}
|
|
|
|
rust_test_host {
|
|
name: "liblmp_tests",
|
|
crate_name: "lmp",
|
|
srcs: [
|
|
"src/lib.rs",
|
|
":LmpGeneratedPackets_rust",
|
|
],
|
|
auto_gen_config: true,
|
|
edition: "2018",
|
|
proc_macros: ["libnum_derive", "libpaste"],
|
|
rustlibs: [
|
|
"libbt_packets",
|
|
"libbytes",
|
|
"libnum_bigint",
|
|
"libnum_integer",
|
|
"libnum_traits",
|
|
"libthiserror",
|
|
"libpin_utils",
|
|
"librand",
|
|
],
|
|
}
|