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 16SUBSYSTEM_DIR = "../.." 17config("call_manager_config") { 18 include_dirs = [ 19 "include", 20 "${SUBSYSTEM_DIR}/interfaces/innerkits", 21 "${SUBSYSTEM_DIR}/utils/include", 22 ] 23} 24 25ohos_shared_library("tel_call_manager_api") { 26 sanitize = { 27 cfi = false # client target, not required to enable cfi 28 cfi_cross_dso = false 29 debug = false 30 } 31 branch_protector_ret = "pac_ret" 32 version_script = "tel_call_manager_api.versionscript" 33 sources = [ 34 "src/bluetooth_call_client.cpp", 35 "src/bluetooth_call_proxy.cpp", 36 "src/call_ability_callback.cpp", 37 "src/call_ability_callback_stub.cpp", 38 "src/call_manager_client.cpp", 39 "src/call_manager_proxy.cpp", 40 "src/call_manager_service_proxy.cpp", 41 "src/call_status_callback_proxy.cpp", 42 "src/cellular_call_proxy.cpp", 43 "src/native_call_manager_hisysevent.cpp", 44 "src/native_call_manager_utils.cpp", 45 "src/super_privacy_manager_client.cpp", 46 "src/voip_call_manager_proxy.cpp", 47 ] 48 49 public_configs = [ ":call_manager_config" ] 50 51 external_deps = [ 52 "ability_base:base", 53 "ability_base:want", 54 "ability_runtime:ability_manager", 55 "ability_runtime:app_manager", 56 "c_utils:utils", 57 "common_event_service:cesfwk_innerkits", 58 "core_service:libtel_common", 59 "core_service:tel_core_service_api", 60 "graphic_surface:surface", 61 "hilog:libhilog", 62 "hisysevent:libhisysevent", 63 "init:libbegetutil", 64 "ipc:ipc_single", 65 "safwk:system_ability_fwk", 66 "samgr:samgr_proxy", 67 ] 68 69 cflags_cc = [ 70 "-Wunused", 71 "-Wunreachable-code", 72 "-fno-exceptions", 73 "-fno-rtti", 74 "-fstack-protector-all", 75 "-Os", 76 "-flto", 77 "-Wno-unused-but-set-variable", 78 "-fdata-sections", 79 "-ffunction-sections", 80 "-fno-asynchronous-unwind-tables", 81 "-fno-unwind-tables", 82 ] 83 84 ldflags = [ 85 "-flto", 86 "-Wl,--gc-sections", 87 ] 88 89 defines = [ 90 "TELEPHONY_LOG_TAG = \"CallManagerApi\"", 91 "LOG_DOMAIN = 0xD001F10", 92 ] 93 94 if (device_name == "rk3568") { 95 defines += [ "CALL_MANAGER_AUTO_START_OPTIMIZE" ] 96 } 97 98 part_name = "call_manager" 99 innerapi_tags = [ "platformsdk" ] 100 subsystem_name = "telephony" 101} 102