• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2023-2025 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")
16
17config("playback_capturer_config") {
18  include_dirs = [
19    "../audiostream/include",
20    "../playbackcapturer/include",
21    "../../../interfaces/inner_api/native/audiocommon/include",
22    "../../../interfaces/inner_api/native/audiomanager/include",
23    "../../../services/audio_policy/server/include/service/config",
24  ]
25
26  cflags = [
27    "-Wall",
28    "-Werror",
29  ]
30}
31
32ohos_shared_library("playback_capturer") {
33  branch_protector_ret = "pac_ret"
34  sanitize = {
35    cfi = true
36    cfi_cross_dso = true
37    cfi_vcall_icall_only = true
38    debug = false
39    integer_overflow = true
40    ubsan = true
41    boundary_sanitize = true
42  }
43  install_enable = true
44
45  configs = [ ":playback_capturer_config" ]
46
47  defines = []
48  if (audio_framework_feature_inner_capturer) {
49    defines += [ "HAS_FEATURE_INNERCAPTURER" ]
50  }
51
52  sources = []
53  if (audio_framework_feature_inner_capturer) {
54    sources += [ "src/playback_capturer_manager.cpp" ]
55  } else {
56    sources += [ "src/playback_capturer_adapter_mock.cpp" ]
57  }
58
59  external_deps = [
60    "c_utils:utils",
61    "hilog:libhilog",
62    "ipc:ipc_single",
63    "pulseaudio:pulse",
64  ]
65
66  version_script = "../../../audio_framework.versionscript"
67
68  part_name = "audio_framework"
69  subsystem_name = "multimedia"
70}
71