1# Copyright (c) 2021-2022 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("../../../../../config.gni") 16import("../../../../../ressche_part.gni") 17 18config("hdi_config") { 19 visibility = [ ":*" ] 20 21 include_dirs = [ 22 ".", 23 "../../../audioschedule/include", 24 "../../../hdiadapter/common/include", 25 "../../../hdiadapter/sink/bluetooth", 26 "../../../hdiadapter/sink/common", 27 "../../../hdiadapter/sink/file", 28 "../../../hdiadapter/sink/primary", 29 "../../../hdiadapter/sink/remote", 30 "../../../hdiadapter/sink/offload", 31 "../../../hdiadapter/source/common", 32 "../../../hdiadapter/source/file", 33 "../../../hdiadapter/source/primary", 34 "../../../hdiadapter/source/remote", 35 "../../../hdiadapter/source/multichannel", 36 "../../../audioeffect/include", 37 "../../../playbackcapturer/include", 38 "../../../../../interfaces/inner_api/native/audiocommon/include", 39 "../../../../../services/audio_service/common/include", 40 ] 41 42 include_dirs += [ multimedia_audio_framework_drivers ] 43 cflags = [ 44 "-Wall", 45 "-Werror", 46 "-DHAVE_CONFIG_H", 47 "-D_GNU_SOURCE", 48 "-D__INCLUDED_FROM_PULSE_AUDIO", 49 ] 50} 51 52ohos_shared_library("module-hdi-sink") { 53 sanitize = { 54 cfi = true 55 cfi_cross_dso = true 56 cfi_vcall_icall_only = true 57 debug = false 58 } 59 sources = [ 60 "hdi_sink.c", 61 "module_hdi_sink.c", 62 ] 63 64 configs = [ ":hdi_config" ] 65 66 cflags = [ "-DPA_MODULE_NAME=libmodule_hdi_sink_z_so" ] 67 68 ldflags = [ 69 "-Wl", 70 "--no-undefined", 71 ] 72 73 deps = [ 74 "../../../../../services/audio_service:audio_common", 75 "../../../audioeffect:audio_effect", 76 "../../../audioschedule:audio_schedule", 77 "../../../audioutils:audio_utils", 78 "../../../hdiadapter/sink:renderer_sink_adapter", 79 "../../../playbackcapturer:playback_capturer", 80 ] 81 82 external_deps = [ 83 "bounds_checking_function:libsec_shared", 84 "c_utils:utils", 85 "hilog:libhilog", 86 "pulseaudio:pulse", 87 "pulseaudio:pulsecommon", 88 "pulseaudio:pulsecore", 89 ] 90 if (ressche_enable == true) { 91 external_deps += [ "resource_schedule_service:ressched_client" ] 92 } 93 94 subsystem_name = "multimedia" 95 part_name = "audio_framework" 96} 97 98ohos_shared_library("module-hdi-source") { 99 sanitize = { 100 cfi = true 101 cfi_cross_dso = true 102 cfi_vcall_icall_only = true 103 debug = false 104 } 105 sources = [ 106 "hdi_source.c", 107 "module_hdi_source.c", 108 ] 109 110 configs = [ ":hdi_config" ] 111 112 cflags = [ "-DPA_MODULE_NAME=libmodule_hdi_source_z_so" ] 113 114 deps = [ 115 "../../../audioeffect:audio_effect", 116 "../../../audioschedule:audio_schedule", 117 "../../../audioutils:audio_utils", 118 "../../../hdiadapter/source:capturer_source_adapter", 119 ] 120 121 external_deps = [ 122 "bounds_checking_function:libsec_shared", 123 "hilog:libhilog", 124 "pulseaudio:pulse", 125 "pulseaudio:pulsecommon", 126 "pulseaudio:pulsecore", 127 ] 128 129 subsystem_name = "multimedia" 130 part_name = "audio_framework" 131} 132 133ohos_shared_library("module-split-stream-sink") { 134 sanitize = { 135 cfi = true 136 cfi_cross_dso = true 137 cfi_vcall_icall_only = true 138 debug = false 139 } 140 sources = [ "module_split_stream_sink.c" ] 141 142 configs = [ ":hdi_config" ] 143 144 cflags = [ "-DPA_MODULE_NAME=libmodule_split_stream_sink_z_so" ] 145 146 ldflags = [ 147 "-Wl", 148 "--no-undefined", 149 ] 150 151 deps = [ 152 "../../../../../services/audio_service:audio_common", 153 "../../../audioschedule:audio_schedule", 154 "../../../audioutils:audio_utils", 155 "../../../hdiadapter/sink:renderer_sink_adapter", 156 ] 157 158 external_deps = [ 159 "bounds_checking_function:libsec_shared", 160 "c_utils:utils", 161 "hilog:libhilog", 162 "pulseaudio:pulse", 163 "pulseaudio:pulsecommon", 164 "pulseaudio:pulsecore", 165 ] 166 167 if (ressche_enable == true) { 168 external_deps += [ "resource_schedule_service:ressched_client" ] 169 } 170 171 subsystem_name = "multimedia" 172 part_name = "audio_framework" 173} 174