• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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")
15
16pulseaudio_dir = "//third_party/pulseaudio"
17pulseaudio_build_path = "//third_party/pulseaudio/ohosbuild"
18libsndfile_dir = "//third_party/libsnd"
19libsndfile_build_path = "//third_party/libsnd"
20
21config("pulseutils_config") {
22  visibility = [ ":*" ]
23
24  include_dirs = [
25    "$pulseaudio_dir",
26    "$pulseaudio_dir/include",
27    "$pulseaudio_build_path/src",
28    "$pulseaudio_build_path/include",
29    "$pulseaudio_dir/src",
30    "$libsndfile_dir/include",
31  ]
32
33  cflags = [
34    "-Wall",
35    "-Werror",
36    "-Wno-implicit-function-declaration",
37    "-DHAVE_CONFIG_H",
38    "-D_GNU_SOURCE",
39  ]
40}
41
42ohos_executable("pacat") {
43  sources = [ "$pulseaudio_dir/src/utils/pacat.c" ]
44
45  configs = [ ":pulseutils_config" ]
46
47  deps = [
48    "$libsndfile_build_path:sndfile",
49    "$pulseaudio_build_path/src:pulsecommon",
50    "$pulseaudio_build_path/src/pulse:pulse",
51  ]
52
53  subsystem_name = "multimedia"
54  part_name = "multimedia_audio_framework"
55}
56
57ohos_executable("pactl") {
58  sources = [ "$pulseaudio_dir/src/utils/pactl.c" ]
59
60  configs = [ ":pulseutils_config" ]
61
62  deps = [
63    "$libsndfile_build_path:sndfile",
64    "$pulseaudio_build_path/src:pulsecommon",
65    "$pulseaudio_build_path/src/pulse:pulse",
66  ]
67  subsystem_name = "multimedia"
68  part_name = "multimedia_audio_framework"
69}
70
71ohos_executable("pacmd") {
72  install_enable = true
73
74  sources = [ "$pulseaudio_dir/src/utils/pacmd.c" ]
75
76  configs = [ ":pulseutils_config" ]
77
78  deps = [
79    "$pulseaudio_build_path/src:pulsecommon",
80    "$pulseaudio_build_path/src/pulse:pulse",
81  ]
82
83  subsystem_name = "multimedia"
84  part_name = "multimedia_audio_framework"
85}
86