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("gst_audio_capture_src_config") { 17 visibility = [ ":*" ] 18 19 cflags = [ 20 "-fno-rtti", 21 "-fno-exceptions", 22 "-Wall", 23 "-fno-common", 24 "-fstack-protector-strong", 25 "-Wshadow", 26 "-FPIC", 27 "-FS", 28 "-O2", 29 "-D_FORTIFY_SOURCE=2", 30 "-fvisibility=hidden", 31 "-Wformat=2", 32 "-Wfloat-equal", 33 "-Wdate-time", 34 "-Werror", 35 "-Wextra", 36 "-Wimplicit-fallthrough", 37 "-Wsign-compare", 38 "-Wunused-parameter", 39 ] 40 41 include_dirs = [ 42 "include", 43 "//commonlibrary/c_utils/base/include", 44 "//foundation/multimedia/player_framework/services/utils/include", 45 "//foundation/multimedia/player_framework/interfaces/inner_api/native", 46 "//foundation/multimedia/player_framework/services/engine/gstreamer/plugins/common", 47 "//foundation/multimedia/audio_framework/frameworks/innerkitsimpl/common/include", 48 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiocommon/include", 49 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiomanager/include", 50 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiopolicy/include", 51 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiosession/include", 52 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiostream/include", 53 "//foundation/multimedia/audio_framework/interfaces/inner_api/native/audiocapturer/include", 54 "//foundation/multimedia/audio_framework/services/audio_service/client/include", 55 "//third_party/gstreamer/gstreamer", 56 "//third_party/gstreamer/gstreamer/libs", 57 "//third_party/gstreamer/gstplugins_base", 58 "//third_party/gstreamer/gstplugins_base/gst-libs", 59 "//third_party/glib/glib", 60 "//third_party/glib", 61 "//third_party/glib/gmodule", 62 ] 63} 64 65ohos_shared_library("gst_audio_capture_src") { 66 install_enable = true 67 68 sources = [ 69 "src/audio_capture_as_impl.cpp", 70 "src/audio_capture_factory.cpp", 71 "src/gst_audio_capture_src.cpp", 72 ] 73 74 configs = [ 75 ":gst_audio_capture_src_config", 76 "//foundation/multimedia/player_framework/services/dfx:media_service_log_dfx_public_config", 77 ] 78 79 deps = [ 80 "../../../../../utils:media_service_utils", 81 "//foundation/multimedia/player_framework/services/dfx:media_service_log_dfx", 82 "//third_party/glib:glib", 83 "//third_party/glib:gmodule", 84 "//third_party/glib:gobject", 85 "//third_party/gstreamer/gstplugins_base:gstaudio", 86 "//third_party/gstreamer/gstreamer:gstbase", 87 "//third_party/gstreamer/gstreamer:gstreamer", 88 ] 89 90 external_deps = [ 91 "hiviewdfx_hilog_native:libhilog", 92 "multimedia_audio_framework:audio_capturer", 93 ] 94 95 relative_install_dir = "media/plugins" 96 subsystem_name = "multimedia" 97 part_name = "multimedia_player_framework" 98} 99