1# Copyright (c) 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") 15import("//foundation/ability/ability_runtime/ability_runtime.gni") 16 17config("connection_obs_manager_public_config") { 18 defines = [ "AMS_LOG_TAG = \"Ability\"" ] 19 defines += [ "AMS_LOG_DOMAIN = 0xD001300" ] 20 visibility = [ ":*" ] 21 visibility += 22 [ "${ability_runtime_test_path}/unittest/connection_observer_test/*" ] 23 include_dirs = [ 24 "include", 25 "${ability_runtime_services_path}/common/include", 26 ] 27 cflags = [] 28 if (target_cpu == "arm") { 29 cflags += [ "-DBINDER_IPC_32BIT" ] 30 } 31} 32 33ohos_shared_library("connection_obs_manager") { 34 branch_protector_ret = "pac_ret" 35 36 sources = [ 37 "src/connection_data.cpp", 38 "src/connection_observer_client.cpp", 39 "src/connection_observer_client_impl.cpp", 40 "src/connection_observer_proxy.cpp", 41 "src/connection_observer_stub.cpp", 42 "src/connection_observer_stub_impl.cpp", 43 "src/dlp_connection_info.cpp", 44 "src/dlp_state_data.cpp", 45 "src/service_proxy_adapter.cpp", 46 ] 47 48 public_configs = [ ":connection_obs_manager_public_config" ] 49 50 deps = [] 51 52 external_deps = [ 53 "ability_base:want", 54 "c_utils:utils", 55 "hilog:libhilog", 56 "ipc:ipc_core", 57 "samgr:samgr_proxy", 58 ] 59 60 cflags_cc = [] 61 if (os_dlp_part_enabled) { 62 cflags_cc += [ "-DWITH_DLP" ] 63 } 64 65 public_external_deps = [ "bundle_framework:appexecfwk_base" ] 66 innerapi_tags = [ "platformsdk" ] 67 subsystem_name = "ability" 68 part_name = "ability_runtime" 69} 70