blob: 91c25d325927fea9c16e0a623459238d03d9a6c6 [file] [log] [blame]
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"],
}
sh_binary {
name: "headless_build_timestamp",
host_supported: true,
src: "tools/build_timestamp.sh",
}
genrule {
name: "HeadlessBuildTimestamp",
tools: [
"headless_build_timestamp",
],
cmd: "$(location headless_build_timestamp) > $(out)",
out: [
"build_timestamp.h",
],
}
filegroup {
name: "TestHeadlessModules",
srcs: [
"connect/connect.cc",
"discovery/discovery.cc",
"dumpsys/dumpsys.cc",
"nop/nop.cc",
"pairing/pairing.cc",
"read/name.cc",
"read/read.cc",
"scan/scan.cc",
"sdp/sdp.cc",
"sdp/sdp_db.cc",
],
}
cc_binary {
name: "bt_headless",
defaults: [
"fluoride_defaults",
],
cflags: [
"-Wall",
"-Werror",
"-Wextra",
"-Wno-date-time",
],
generated_headers: [
"HeadlessBuildTimestamp",
],
srcs: [
":TestHeadlessModules",
"bt_property.cc",
"get_options.cc",
"handler.cc",
"headless.cc",
"log.cc",
"main.cc",
"messenger.cc",
"property.cc",
"util.cc",
],
include_dirs: [
"packages/modules/Bluetooth/system",
"packages/modules/Bluetooth/system/gd",
"packages/modules/Bluetooth/system/stack/include",
],
whole_static_libs: [
"libbtcore",
],
static_libs: [
"android.hardware.bluetooth.a2dp@1.0",
"android.system.suspend.control-V1-ndk",
"avrcp-target-service",
"lib-bt-packets",
"lib-bt-packets-avrcp",
"lib-bt-packets-base",
"libFraunhoferAAC",
"libaudio-a2dp-hw-utils",
"libbluetooth-dumpsys",
"libbluetooth_core_rs",
"libbluetooth_gd",
"libbluetooth_rust_interop",
"libbt-audio-hal-interface",
"libbt-bta",
"libbt-bta-core",
"libbt-common",
"libbt-hci",
"libbt-sbc-decoder",
"libbt-sbc-encoder",
"libbt-stack",
"libbt-stack-core",
"libbt_shim_bridge",
"libbt_shim_ffi",
"libbtdevice",
"libbte",
"libbtif",
"libbtif-core",
"libc++fs",
"libchrome",
"libevent",
"libflatbuffers-cpp",
"libg722codec",
"liblc3",
"libmodpb64",
"libopus",
"libosi",
"libprotobuf-cpp-lite",
"libstatslog_bt",
"libudrv-uipc",
"libz",
],
shared_libs: [
"android.hardware.bluetooth.audio-V3-ndk",
"android.hardware.bluetooth.audio@2.0",
"android.hardware.bluetooth.audio@2.1",
"android.hardware.bluetooth@1.0",
"android.hardware.bluetooth@1.1",
"android.system.suspend-V1-ndk",
"libaaudio",
"libbase",
"libbinder_ndk",
"libcrypto",
"libcutils", // property_get_bool
"libfmq",
"libhidlbase",
"libjsoncpp",
"liblog", // __android_log_print
"libstatssocket",
"libutils",
"libPlatformProperties",
],
ldflags: ["-rdynamic"],
sanitize: {
cfi: false,
},
}