Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 1 | // |
| 2 | // Copyright (C) 2016 The Android Open Source Project |
| 3 | // |
| 4 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | // you may not use this file except in compliance with the License. |
| 6 | // You may obtain a copy of the License at |
| 7 | // |
| 8 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | // |
| 10 | // Unless required by applicable law or agreed to in writing, software |
| 11 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | // See the License for the specific language governing permissions and |
| 14 | // limitations under the License. |
| 15 | |
Bob Badour | b224b36 | 2021-02-12 20:13:01 -0800 | [diff] [blame] | 16 | package { |
| 17 | // See: http://go/android-license-faq |
| 18 | // A large-scale-change added 'default_applicable_licenses' to import |
| 19 | // all of the 'license_kinds' from "hardware_interfaces_license" |
| 20 | // to get the below license kinds: |
| 21 | // SPDX-license-identifier-Apache-2.0 |
| 22 | default_applicable_licenses: ["hardware_interfaces_license"], |
| 23 | } |
| 24 | |
Ayushi Khopkar | a37d3df | 2021-06-24 20:24:03 +0530 | [diff] [blame] | 25 | cc_defaults { |
| 26 | name: "android.hardware.bluetooth@1.0-defaults", |
Hongguang Chen | a12b18a | 2021-07-08 23:31:34 +0000 | [diff] [blame] | 27 | vendor: true, |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 28 | relative_install_path: "hw", |
| 29 | srcs: [ |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 30 | "bluetooth_hci.cc", |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 31 | "bluetooth_address.cc", |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 32 | "vendor_interface.cc", |
| 33 | ], |
| 34 | shared_libs: [ |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 35 | "android.hardware.bluetooth@1.0", |
| 36 | "libbase", |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 37 | "libcutils", |
| 38 | "libhardware", |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 39 | "libhidlbase", |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 40 | "liblog", |
| 41 | "libutils", |
| 42 | ], |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 43 | static_libs: [ |
| 44 | "android.hardware.bluetooth-async", |
Myles Watson | 274a381 | 2017-02-23 06:29:08 -0800 | [diff] [blame] | 45 | "android.hardware.bluetooth-hci", |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 46 | ], |
| 47 | } |
| 48 | |
Ayushi Khopkar | a37d3df | 2021-06-24 20:24:03 +0530 | [diff] [blame] | 49 | cc_library { |
| 50 | name: "android.hardware.bluetooth@1.0-impl", |
| 51 | defaults: [ |
| 52 | "hidl_defaults", |
| 53 | "android.hardware.bluetooth@1.0-defaults", |
| 54 | ], |
| 55 | } |
| 56 | |
| 57 | cc_library { |
| 58 | name: "android.hardware.bluetooth@1.0-impl-test", |
| 59 | defaults: [ |
| 60 | "hidl_defaults", |
| 61 | "android.hardware.bluetooth@1.0-defaults", |
| 62 | ], |
| 63 | cflags: [ |
| 64 | "-DBT_FUZZER", |
| 65 | ], |
| 66 | } |
| 67 | |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 68 | cc_library_static { |
| 69 | name: "android.hardware.bluetooth-async", |
Hongguang Chen | a12b18a | 2021-07-08 23:31:34 +0000 | [diff] [blame] | 70 | vendor: true, |
Steven Moreland | 691a455 | 2017-03-08 15:58:46 -0800 | [diff] [blame] | 71 | defaults: ["hidl_defaults"], |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 72 | srcs: [ |
| 73 | "async_fd_watcher.cc", |
| 74 | ], |
| 75 | export_include_dirs: ["."], |
| 76 | shared_libs: [ |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 77 | "liblog", |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 78 | ], |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 79 | } |
| 80 | |
Myles Watson | 274a381 | 2017-02-23 06:29:08 -0800 | [diff] [blame] | 81 | cc_library_static { |
| 82 | name: "android.hardware.bluetooth-hci", |
Hongguang Chen | a12b18a | 2021-07-08 23:31:34 +0000 | [diff] [blame] | 83 | vendor: true, |
Steven Moreland | 691a455 | 2017-03-08 15:58:46 -0800 | [diff] [blame] | 84 | defaults: ["hidl_defaults"], |
Myles Watson | 274a381 | 2017-02-23 06:29:08 -0800 | [diff] [blame] | 85 | srcs: [ |
| 86 | "hci_packetizer.cc", |
Zach Johnson | 917efb1 | 2017-02-26 23:46:05 -0800 | [diff] [blame] | 87 | "hci_protocol.cc", |
| 88 | "h4_protocol.cc", |
| 89 | "mct_protocol.cc", |
Myles Watson | 274a381 | 2017-02-23 06:29:08 -0800 | [diff] [blame] | 90 | ], |
| 91 | export_include_dirs: ["."], |
| 92 | shared_libs: [ |
| 93 | "libbase", |
Myles Watson | 274a381 | 2017-02-23 06:29:08 -0800 | [diff] [blame] | 94 | "libhidlbase", |
| 95 | "liblog", |
| 96 | "libutils", |
| 97 | ], |
| 98 | } |
| 99 | |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 100 | cc_test { |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 101 | name: "bluetooth-vendor-interface-unit-tests", |
Steven Moreland | 2cfae52 | 2017-04-13 14:19:19 -0700 | [diff] [blame] | 102 | vendor: true, |
Steven Moreland | 691a455 | 2017-03-08 15:58:46 -0800 | [diff] [blame] | 103 | defaults: ["hidl_defaults"], |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 104 | srcs: [ |
Myles Watson | 7d42dca | 2017-01-24 16:51:39 -0800 | [diff] [blame] | 105 | "test/async_fd_watcher_unittest.cc", |
Zach Johnson | 917efb1 | 2017-02-26 23:46:05 -0800 | [diff] [blame] | 106 | "test/h4_protocol_unittest.cc", |
| 107 | "test/mct_protocol_unittest.cc", |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 108 | ], |
| 109 | local_include_dirs: [ |
| 110 | "test", |
| 111 | ], |
| 112 | shared_libs: [ |
| 113 | "libbase", |
Zach Johnson | 917efb1 | 2017-02-26 23:46:05 -0800 | [diff] [blame] | 114 | "libhidlbase", |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 115 | "liblog", |
Philip Cuadra | 8b3f315 | 2017-04-20 16:02:48 -0700 | [diff] [blame] | 116 | "libutils", |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 117 | ], |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 118 | static_libs: [ |
| 119 | "android.hardware.bluetooth-async", |
Zach Johnson | 917efb1 | 2017-02-26 23:46:05 -0800 | [diff] [blame] | 120 | "android.hardware.bluetooth-hci", |
| 121 | "libgmock", |
Myles Watson | be6176d | 2017-02-21 13:27:01 -0800 | [diff] [blame] | 122 | ], |
Keun Soo YIM | 68ae05d | 2018-11-27 14:04:42 -0800 | [diff] [blame] | 123 | test_suites: ["general-tests"], |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 124 | } |
| 125 | |
| 126 | cc_test_host { |
| 127 | name: "bluetooth-address-unit-tests", |
Steven Moreland | 691a455 | 2017-03-08 15:58:46 -0800 | [diff] [blame] | 128 | defaults: ["hidl_defaults"], |
Myles Watson | b43a5b2 | 2017-01-31 12:20:44 -0800 | [diff] [blame] | 129 | srcs: [ |
| 130 | "bluetooth_address.cc", |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 131 | "test/bluetooth_address_test.cc", |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 132 | ], |
| 133 | local_include_dirs: [ |
| 134 | "test", |
| 135 | ], |
| 136 | shared_libs: [ |
| 137 | "libbase", |
Elliott Hughes | 69a0853 | 2020-05-20 08:22:46 -0700 | [diff] [blame] | 138 | "libcutils", |
Myles Watson | 6a7d622 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 139 | "liblog", |
Andre Eisenbach | 89ba528 | 2016-10-13 15:45:02 -0700 | [diff] [blame] | 140 | ], |
| 141 | } |
Steven Moreland | 90e3a50 | 2017-11-02 14:16:29 -0700 | [diff] [blame] | 142 | |
| 143 | cc_binary { |
| 144 | name: "android.hardware.bluetooth@1.0-service", |
Chih-Hung Hsieh | 3f2ea62 | 2017-11-20 10:49:11 -0800 | [diff] [blame] | 145 | defaults: ["hidl_defaults"], |
Steven Moreland | 90e3a50 | 2017-11-02 14:16:29 -0700 | [diff] [blame] | 146 | relative_install_path: "hw", |
| 147 | vendor: true, |
| 148 | init_rc: ["android.hardware.bluetooth@1.0-service.rc"], |
| 149 | srcs: ["service.cpp"], |
| 150 | |
| 151 | shared_libs: [ |
| 152 | "liblog", |
| 153 | "libcutils", |
| 154 | "libdl", |
| 155 | "libbase", |
| 156 | "libutils", |
| 157 | "libhardware", |
| 158 | "libhidlbase", |
Steven Moreland | 90e3a50 | 2017-11-02 14:16:29 -0700 | [diff] [blame] | 159 | "android.hardware.bluetooth@1.0", |
| 160 | ], |
| 161 | } |