# Copyright (c) 2021-2022 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import("//build/ohos.gni") import("../../../../../config.gni") import("../../../../../ressche_part.gni") config("hdi_config") { visibility = [ ":*" ] include_dirs = [ ".", "../../../audioschedule/include", "../../../hdiadapter/common/include", "../../../hdiadapter/sink/bluetooth", "../../../hdiadapter/sink/common", "../../../hdiadapter/sink/file", "../../../hdiadapter/sink/primary", "../../../hdiadapter/sink/remote", "../../../hdiadapter/sink/offload", "../../../hdiadapter/source/common", "../../../hdiadapter/source/file", "../../../hdiadapter/source/primary", "../../../hdiadapter/source/remote", "../../../hdiadapter/source/multichannel", "../../../audioeffect/include", "../../../playbackcapturer/include", "../../../../../interfaces/inner_api/native/audiocommon/include", "../../../../../services/audio_service/common/include", ] include_dirs += [ multimedia_audio_framework_drivers ] cflags = [ "-Wall", "-Werror", "-DHAVE_CONFIG_H", "-D_GNU_SOURCE", "-D__INCLUDED_FROM_PULSE_AUDIO", ] } ohos_shared_library("module-hdi-sink") { sanitize = { cfi = true cfi_cross_dso = true cfi_vcall_icall_only = true debug = false } sources = [ "hdi_sink.c", "module_hdi_sink.c", ] configs = [ ":hdi_config" ] cflags = [ "-DPA_MODULE_NAME=libmodule_hdi_sink_z_so" ] ldflags = [ "-Wl", "--no-undefined", ] deps = [ "../../../../../services/audio_service:audio_common", "../../../audioeffect:audio_effect", "../../../audioschedule:audio_schedule", "../../../audioutils:audio_utils", "../../../hdiadapter/sink:renderer_sink_adapter", "../../../playbackcapturer:playback_capturer", ] external_deps = [ "bounds_checking_function:libsec_shared", "c_utils:utils", "hilog:libhilog", "pulseaudio:pulse", "pulseaudio:pulsecommon", "pulseaudio:pulsecore", ] if (ressche_enable == true) { external_deps += [ "resource_schedule_service:ressched_client" ] } subsystem_name = "multimedia" part_name = "audio_framework" } ohos_shared_library("module-hdi-source") { sanitize = { cfi = true cfi_cross_dso = true cfi_vcall_icall_only = true debug = false } sources = [ "hdi_source.c", "module_hdi_source.c", ] defines = [] if (is_emulator) { defines += [ "IS_EMULATOR" ] } configs = [ ":hdi_config" ] cflags = [ "-DPA_MODULE_NAME=libmodule_hdi_source_z_so" ] deps = [ "../../../audioeffect:audio_effect", "../../../audioschedule:audio_schedule", "../../../audioutils:audio_utils", "../../../hdiadapter/source:capturer_source_adapter", ] external_deps = [ "bounds_checking_function:libsec_shared", "hilog:libhilog", "pulseaudio:pulse", "pulseaudio:pulsecommon", "pulseaudio:pulsecore", ] subsystem_name = "multimedia" part_name = "audio_framework" } ohos_shared_library("module-split-stream-sink") { sanitize = { cfi = true cfi_cross_dso = true cfi_vcall_icall_only = true debug = false } sources = [ "module_split_stream_sink.c" ] configs = [ ":hdi_config" ] cflags = [ "-DPA_MODULE_NAME=libmodule_split_stream_sink_z_so" ] ldflags = [ "-Wl", "--no-undefined", ] deps = [ "../../../../../services/audio_service:audio_common", "../../../audioschedule:audio_schedule", "../../../audioutils:audio_utils", "../../../hdiadapter/sink:renderer_sink_adapter", ] external_deps = [ "bounds_checking_function:libsec_shared", "c_utils:utils", "hilog:libhilog", "pulseaudio:pulse", "pulseaudio:pulsecommon", "pulseaudio:pulsecore", ] if (ressche_enable == true) { external_deps += [ "resource_schedule_service:ressched_client" ] } subsystem_name = "multimedia" part_name = "audio_framework" }