• 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/hdf_core/adapter/uhdf2/uhdf.gni")
16import("//drivers/peripheral/audio/audio.gni")
17
18config("hdi_service_config") {
19  visibility = [ ":*" ]
20
21  cflags = [
22    "-Wall",
23    "-Wextra",
24    "-Werror",
25    "-DGST_DISABLE_DEPRECATED",
26    "-DHAVE_CONFIG_H",
27    "-fno-strict-aliasing",
28    "-Wno-builtin-requires-header",
29    "-Wno-int-conversion",
30    "-Wno-unused-parameter",
31    "-Wno-thread-safety-attributes",
32    "-Wno-inconsistent-missing-override",
33    "-fno-rtti",
34    "-fno-exceptions",
35    "-ffunction-sections",
36    "-fdata-sections",
37  ]
38
39  ldflags = [ "-Wl" ]
40}
41
42ohos_shared_library("audio_bluetooth_hdi_adapter_server") {
43  include_dirs = [
44    "//drivers/hdf_core/adapter/uhdf2/include/hdi",
45    "//drivers/peripheral/bluetooth/audio/interfaces/include",
46    "//drivers/peripheral/bluetooth/audio/hal/hdi_passthrough/include",
47    "//drivers/peripheral/bluetooth/audio/hal/hdi_binder/server/include",
48    "//third_party/bounds_checking_function/include",
49  ]
50
51  sources = [
52    "src/hdf_audio_server.cpp",
53    "src/hdf_audio_server_common.cpp",
54    "src/hdf_audio_server_render.cpp",
55  ]
56
57  deps = [
58    "$hdf_uhdf_path/host:libhdf_host",
59    "$hdf_uhdf_path/utils:libhdf_utils",
60    "//drivers/peripheral/bluetooth/audio/hal/hdi_passthrough:hdi_audio_bluetooth",
61  ]
62
63  defines = []
64  if (is_standard_system) {
65    external_deps = [ "hiviewdfx_hilog_native:libhilog" ]
66  } else {
67    external_deps = [ "hilog:libhilog" ]
68  }
69  external_deps += [ "c_utils:utils" ]
70
71  public_configs = [ ":hdi_service_config" ]
72
73  install_images = [ chipset_base_dir ]
74  subsystem_name = "hdf"
75  part_name = "drivers_peripheral_bluetooth"
76}
77