1# Copyright (c) 2020-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. 13import("//build/lite/config/component/lite_component.gni") 14import("//build/lite/ndk/ndk.gni") 15import("//foundation/multimedia/media_utils_lite/config.gni") 16 17shared_library("audio_capturer_lite") { 18 sources = [ "audio_capturer.cpp" ] 19 20 if (enable_media_passthrough_mode == true) { 21 sources += [ "passthrough/audio_capturer_client.cpp" ] 22 include_dirs = [ 23 "//foundation/multimedia/audio_lite/frameworks/passthrough", 24 "//foundation/multimedia/audio_lite/services/impl", 25 "//foundation/systemabilitymgr/samgr_lite/interfaces/kits/samgr", 26 ] 27 deps = [ 28 "//foundation/multimedia/audio_lite/services:audio_capturer_impl", 29 "//foundation/systemabilitymgr/samgr_lite/samgr:samgr", 30 ] 31 } else { 32 sources += [ "binder/audio_capturer_client.cpp" ] 33 34 include_dirs = [ 35 "//base/security/permission_lite/interfaces/kits", 36 "//foundation/multimedia/audio_lite/services/server/include", 37 "//foundation/multimedia/audio_lite/services/impl", 38 "//foundation/multimedia/audio_lite/frameworks/binder", 39 "//foundation/systemabilitymgr/samgr_lite/interfaces/kits/registry", 40 "//foundation/systemabilitymgr/samgr_lite/interfaces/kits/registry", 41 "//foundation/systemabilitymgr/samgr_lite/interfaces/kits/samgr", 42 ] 43 44 deps = [ 45 "//base/security/permission_lite/services/pms_client:pms_client", 46 "//foundation/graphic/surface_lite:surface_lite", 47 "//foundation/systemabilitymgr/samgr_lite/samgr:samgr", 48 ] 49 } 50 public_configs = [ ":audio_capturer_public_config" ] 51 52 public_deps = [ 53 "//foundation/multimedia/media_utils_lite:media_common", 54 "//third_party/bounds_checking_function:libsec_shared", 55 ] 56} 57 58config("audio_capturer_public_config") { 59 include_dirs = [ 60 "//foundation/multimedia/audio_lite/interfaces/kits", 61 "//foundation/multimedia/media_utils_lite/interfaces/kits", 62 ] 63 64 cflags = [ "-fPIC" ] 65 cflags += [ "-Wall" ] 66 cflags_cc = cflags 67} 68