1# Copyright (c) 2023 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/ohos.gni") 14import("//build/ohos_var.gni") 15import("//foundation/distributeddatamgr/datamgr_service/datamgr_service.gni") 16config("module_public_config") { 17 visibility = [ ":*" ] 18 include_dirs = [ 19 ".", 20 "strategies", 21 "common", 22 "data", 23 "../../adapter/include", 24 "../../app/src", 25 "../../framework/include", 26 "${datashare_path}/frameworks/native/common/include", 27 "${datashare_path}/interfaces/inner_api/common/include", 28 "${datashare_path}/interfaces/inner_api/consumer/include", 29 "../common", 30 "../crypto/include", 31 "../permission/include", 32 ] 33} 34group("build_module") { 35 deps = [ ":data_share_service" ] 36} 37ohos_shared_library("data_share_service") { 38 branch_protector_ret = "pac_ret" 39 sanitize = { 40 ubsan = true 41 boundary_sanitize = true 42 cfi = true 43 cfi_cross_dso = true 44 debug = false 45 } 46 sources = [ 47 "${data_service_path}/service/common/xcollie.cpp", 48 "common/app_connect_manager.cpp", 49 "common/base64_utils.cpp", 50 "common/bundle_mgr_proxy.cpp", 51 "common/db_delegate.cpp", 52 "common/div_strategy.cpp", 53 "common/extension_ability_manager.cpp", 54 "common/extension_connect_adaptor.cpp", 55 "common/extension_mgr_proxy.cpp", 56 "common/kv_delegate.cpp", 57 "common/rdb_delegate.cpp", 58 "common/scheduler_manager.cpp", 59 "common/seq_strategy.cpp", 60 "common/uri_utils.cpp", 61 "data/published_data.cpp", 62 "data/resultset_json_formatter.cpp", 63 "data/template_data.cpp", 64 "data_provider_config.cpp", 65 "data_share_db_config.cpp", 66 "data_share_obs_proxy.cpp", 67 "data_share_profile_config.cpp", 68 "data_share_service_impl.cpp", 69 "data_share_service_stub.cpp", 70 "data_share_silent_config.cpp", 71 "data_share_types_util.cpp", 72 "strategies/data_proxy/load_config_from_data_proxy_node_strategy.cpp", 73 "strategies/data_share/load_config_from_data_share_bundle_info_strategy.cpp", 74 "strategies/general/check_is_data_proxy_strategy.cpp", 75 "strategies/general/check_is_single_app_strategy.cpp", 76 "strategies/general/cross_permission_strategy.cpp", 77 "strategies/general/load_config_common_strategy.cpp", 78 "strategies/general/load_config_data_info_strategy.cpp", 79 "strategies/general/load_config_from_bundle_info_strategy.cpp", 80 "strategies/general/permission_strategy.cpp", 81 "strategies/get_data_strategy.cpp", 82 "strategies/publish_strategy.cpp", 83 "strategies/rdb_notify_strategy.cpp", 84 "strategies/subscribe_strategy.cpp", 85 "strategies/template_strategy.cpp", 86 "subscriber_managers/published_data_subscriber_manager.cpp", 87 "subscriber_managers/rdb_subscriber_manager.cpp", 88 "sys_event_subscriber.cpp", 89 ] 90 cflags = [ 91 "-Wno-multichar", 92 "-D_LIBCPP_HAS_COND_CLOCKWAIT", 93 ] 94 95 cflags_cc = [ "-fvisibility=hidden" ] 96 97 configs = [ ":module_public_config" ] 98 99 deps = [ 100 "../../adapter:distributeddata_adapter", 101 "../../adapter/utils:distributeddata_utils_static", 102 "../../framework:distributeddatasvcfwk", 103 "../../service:distributeddatasvc", 104 ] 105 106 external_deps = [ 107 "ability_base:base", 108 "ability_base:want", 109 "ability_base:zuri", 110 "ability_runtime:dataobs_manager", 111 "ability_runtime:extension_manager", 112 "ability_runtime:wantagent_innerkits", 113 "access_token:libaccesstoken_sdk", 114 "access_token:libtokenid_sdk", 115 "bundle_framework:appexecfwk_base", 116 "bundle_framework:appexecfwk_core", 117 "c_utils:utils", 118 "common_event_service:cesfwk_innerkits", 119 "data_share:datashare_common", 120 "device_manager:devicemanagersdk", 121 "hicollie:libhicollie", 122 "hilog:libhilog", 123 "hisysevent:libhisysevent", 124 "ipc:ipc_core", 125 "json:nlohmann_json_static", 126 "kv_store:distributeddb", 127 "relational_store:native_rdb", 128 "relational_store:rdb_data_share_adapter", 129 "resource_management:global_resmgr", 130 "samgr:samgr_proxy", 131 "time_service:time_client", 132 ] 133 subsystem_name = "distributeddatamgr" 134 135 part_name = "datamgr_service" 136} 137