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