• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2024 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("//build/ohos/ace/ace.gni")
16import("../../config.gni")
17import("../../multimedia_aafwk.gni")
18
19config("public_ffi_config") {
20  include_dirs = [ "include" ]
21}
22
23ohos_shared_library("cj_multimedia_audio_ffi") {
24  public_configs = [ ":public_ffi_config" ]
25
26  sanitize = {
27    cfi = true  # Enable/disable control flow integrity detection
28    boundary_sanitize = true  # Enable boundary san detection
29    cfi_cross_dso = true  # Cross-SO CFI Checks
30    integer_overflow = true  # Enable integer overflow detection
31    ubsan = true  # Enable some Ubsan options
32    debug = false
33  }
34
35  include_dirs = [
36    "include",
37    "../../frameworks/native/include",
38    "../../interfaces/inner_api",
39  ]
40
41  sources = [
42    "src/multimedia_audio_capturer_callback.cpp",
43    "src/multimedia_audio_capturer_impl.cpp",
44    "src/multimedia_audio_common.cpp",
45    "src/multimedia_audio_ffi.cpp",
46    "src/multimedia_audio_manager_impl.cpp",
47    "src/multimedia_audio_renderer_callback.cpp",
48    "src/multimedia_audio_renderer_impl.cpp",
49    "src/multimedia_audio_routing_manager_callback.cpp",
50    "src/multimedia_audio_routing_manager_impl.cpp",
51    "src/multimedia_audio_stream_manager_callback.cpp",
52    "src/multimedia_audio_stream_manager_impl.cpp",
53    "src/multimedia_audio_volume_group_manager_callback.cpp",
54    "src/multimedia_audio_volume_group_manager_impl.cpp",
55    "src/multimedia_audio_volume_manager_callback.cpp",
56    "src/multimedia_audio_volume_manager_impl.cpp",
57  ]
58
59  deps = [
60    "../../services/audio_policy:audio_policy_client",
61    "../../services/audio_service:audio_client",
62    "../native/audiocapturer:audio_capturer",
63    "../native/audiorenderer:audio_renderer",
64    "../native/audioutils:audio_utils",
65  ]
66
67  external_deps = [
68    "c_utils:utils",
69    "hilog:libhilog",
70    "napi:ace_napi",
71    "napi:cj_bind_ffi",
72    "napi:cj_bind_native",
73  ]
74
75  innerapi_tags = [ "platformsdk" ]
76  part_name = "audio_framework"
77  subsystem_name = "multimedia"
78}
79