1package { 2 // See: http://go/android-license-faq 3 // A large-scale-change added 'default_applicable_licenses' to import 4 // all of the 'license_kinds' from "system_bt_license" 5 // to get the below license kinds: 6 // SPDX-license-identifier-Apache-2.0 7 default_applicable_licenses: ["system_bt_license"], 8} 9 10sh_binary { 11 name: "headless_build_timestamp", 12 host_supported: true, 13 src: "tools/build_timestamp.sh", 14} 15 16genrule { 17 name: "HeadlessBuildTimestamp", 18 tools: [ 19 "headless_build_timestamp", 20 ], 21 cmd: "$(location headless_build_timestamp) > $(out)", 22 out: [ 23 "build_timestamp.h", 24 ], 25} 26 27filegroup { 28 name: "TestHeadlessModules", 29 srcs: [ 30 "connect/connect.cc", 31 "discovery/discovery.cc", 32 "dumpsys/dumpsys.cc", 33 "nop/nop.cc", 34 "pairing/pairing.cc", 35 "read/name.cc", 36 "read/read.cc", 37 "scan/scan.cc", 38 "sdp/sdp.cc", 39 "sdp/sdp_db.cc", 40 ], 41} 42 43cc_binary { 44 name: "bt_headless", 45 defaults: [ 46 "fluoride_defaults", 47 ], 48 cflags: [ 49 "-Wall", 50 "-Werror", 51 "-Wextra", 52 "-Wno-date-time", 53 ], 54 generated_headers: [ 55 "HeadlessBuildTimestamp", 56 ], 57 srcs: [ 58 ":TestHeadlessModules", 59 "bt_property.cc", 60 "get_options.cc", 61 "handler.cc", 62 "headless.cc", 63 "log.cc", 64 "main.cc", 65 "messenger.cc", 66 "property.cc", 67 "util.cc", 68 ], 69 include_dirs: [ 70 "packages/modules/Bluetooth/system", 71 "packages/modules/Bluetooth/system/gd", 72 "packages/modules/Bluetooth/system/stack/include", 73 ], 74 whole_static_libs: [ 75 "libbtcore", 76 ], 77 static_libs: [ 78 "android.hardware.bluetooth.a2dp@1.0", 79 "android.system.suspend.control-V1-ndk", 80 "avrcp-target-service", 81 "lib-bt-packets", 82 "lib-bt-packets-avrcp", 83 "lib-bt-packets-base", 84 "libFraunhoferAAC", 85 "libaudio-a2dp-hw-utils", 86 "libbluetooth-dumpsys", 87 "libbluetooth_core_rs", 88 "libbluetooth_gd", 89 "libbluetooth_rust_interop", 90 "libbt-audio-hal-interface", 91 "libbt-bta", 92 "libbt-bta-core", 93 "libbt-common", 94 "libbt-hci", 95 "libbt-protos-lite", 96 "libbt-sbc-decoder", 97 "libbt-sbc-encoder", 98 "libbt-stack", 99 "libbt-stack-core", 100 "libbt_shim_bridge", 101 "libbt_shim_ffi", 102 "libbtdevice", 103 "libbte", 104 "libbtif", 105 "libbtif-core", 106 "libc++fs", 107 "libchrome", 108 "libevent", 109 "libflatbuffers-cpp", 110 "libg722codec", 111 "liblc3", 112 "libmodpb64", 113 "libopus", 114 "libosi", 115 "libprotobuf-cpp-lite", 116 "libudrv-uipc", 117 "libz", 118 ], 119 shared_libs: [ 120 "android.hardware.bluetooth.audio-V3-ndk", 121 "android.hardware.bluetooth.audio@2.0", 122 "android.hardware.bluetooth.audio@2.1", 123 "android.hardware.bluetooth@1.0", 124 "android.hardware.bluetooth@1.1", 125 "android.system.suspend-V1-ndk", 126 "libaaudio", 127 "libbase", 128 "libbinder_ndk", 129 "libcrypto", 130 "libcutils", // property_get_bool 131 "libfmq", 132 "libhidlbase", 133 "libjsoncpp", 134 "liblog", // __android_log_print 135 "libutils", 136 "libPlatformProperties", 137 ], 138 ldflags: ["-rdynamic"], 139 sanitize: { 140 cfi: false, 141 }, 142} 143