• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13
14import("//build/ohos.gni")
15import("//drivers/adapter/uhdf2/uhdf.gni")
16
17root_path = "//drivers/peripheral/bluetooth/hdi"
18
19group("bluetooth_hdi") {
20  deps = [
21    ":bluetooth_hdi_client",
22    ":bluetooth_hdi_server",
23  ]
24}
25
26ohos_shared_library("bluetooth_hdi_client") {
27  include_dirs = [ "$root_path" ]
28
29  sources = [
30    "$root_path/ohos/hardware/bt/v1_0/bt_hci_callbacks_stub.cpp",
31    "$root_path/ohos/hardware/bt/v1_0/client/bt_hci_proxy.cpp",
32  ]
33
34  if (is_standard_system) {
35    external_deps = [
36      "device_driver_framework:libhdf_host",
37      "device_driver_framework:libhdf_ipc_adapter",
38      "device_driver_framework:libhdf_utils",
39      "device_driver_framework:libhdi",
40      "hiviewdfx_hilog_native:libhilog",
41      "ipc:ipc_single",
42      "utils_base:utils",
43    ]
44  } else {
45    external_deps = [
46      "hilog:libhilog",
47      "ipc:ipc_single",
48    ]
49  }
50
51  install_images = [ chipset_base_dir ]
52  subsystem_name = "hdf"
53  part_name = "bluetooth_device_driver"
54}
55
56ohos_shared_library("bluetooth_hdi_server") {
57  include_dirs = [
58    "$root_path",
59    "$root_path/ohos/hardware/bt/v1_0",
60    "$root_path/ohos/hardware/bt/v1_0/server/implement",
61  ]
62
63  sources = [
64    "$root_path/ohos/hardware/bt/v1_0/bt_hci_callbacks_proxy.cpp",
65    "$root_path/ohos/hardware/bt/v1_0/server/bt_hci_driver.cpp",
66    "$root_path/ohos/hardware/bt/v1_0/server/bt_hci_service.cpp",
67    "$root_path/ohos/hardware/bt/v1_0/server/bt_hci_stub.cpp",
68    "$root_path/ohos/hardware/bt/v1_0/server/implement/bluetooth_address.cpp",
69    "$root_path/ohos/hardware/bt/v1_0/server/implement/h4_protocol.cpp",
70    "$root_path/ohos/hardware/bt/v1_0/server/implement/hci_protocol.cpp",
71    "$root_path/ohos/hardware/bt/v1_0/server/implement/hci_watcher.cpp",
72    "$root_path/ohos/hardware/bt/v1_0/server/implement/mct_protocol.cpp",
73    "$root_path/ohos/hardware/bt/v1_0/server/implement/vendor_interface.cpp",
74  ]
75
76  if (is_standard_system) {
77    external_deps = [
78      "device_driver_framework:libhdf_host",
79      "device_driver_framework:libhdf_ipc_adapter",
80      "device_driver_framework:libhdf_utils",
81      "device_driver_framework:libhdi",
82      "hiviewdfx_hilog_native:libhilog",
83      "ipc:ipc_single",
84      "utils_base:utils",
85    ]
86  } else {
87    external_deps = [
88      "hilog:libhilog",
89      "ipc:ipc_single",
90    ]
91  }
92
93  install_images = [ chipset_base_dir ]
94  subsystem_name = "hdf"
95  part_name = "bluetooth_device_driver"
96}
97