# Copyright (c) 2022 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import("//build/ohos.gni") import("//foundation/distributeddatamgr/datamgr_service/datamgr_service.gni") config("module_public_config") { visibility = [ ":*" ] include_dirs = [ "${data_service_path}/framework/include", "${data_service_path}/adapter/include/communicator", "${data_service_path}/adapter/include/dfx", "${data_service_path}/service/udmf/lifecycle", "${data_service_path}/service/udmf/permission", "${data_service_path}/service/udmf/preprocess", "${data_service_path}/service/udmf/store", "${data_service_path}/service/udmf/utd", "${data_service_path}/service/udmf", "${data_service_path}/service/bootstrap/include", "${kv_store_path}/interfaces/innerkits/distributeddata/include", "${kv_store_path}/framework/libs/distributeddb/interfaces/include", "${kv_store_common_path}", "${udmf_path}/framework/common", "${udmf_path}/interfaces/innerkits/common", "${udmf_path}/interfaces/innerkits/data", ] } ohos_shared_library("udmf_server") { branch_protector_ret = "pac_ret" sanitize = { ubsan = true boundary_sanitize = true cfi = true cfi_cross_dso = true debug = false } sources = [ "lifecycle/clean_on_startup.cpp", "lifecycle/clean_on_timeout.cpp", "lifecycle/lifecycle_manager.cpp", "lifecycle/lifecycle_policy.cpp", "permission/checker_manager.cpp", "permission/data_checker.cpp", "permission/uri_permission_manager.cpp", "preprocess/data_handler.cpp", "preprocess/preprocess_utils.cpp", "preprocess/udmf_dialog.cpp", "store/runtime_store.cpp", "store/store_cache.cpp", "udmf_service_impl.cpp", "udmf_service_stub.cpp", ] configs = [ ":module_public_config" ] cflags = [ "-D_LIBCPP_HAS_COND_CLOCKWAIT" ] deps = [ "${data_service_path}/adapter:distributeddata_adapter", "${data_service_path}/framework:distributeddatasvcfwk", "${data_service_path}/service:distributeddatasvc", ] defines = [] external_deps = [ "ability_base:zuri", "ability_runtime:ability_manager", "ability_runtime:uri_permission_mgr", "ability_runtime:wantagent_innerkits", "access_token:libaccesstoken_sdk", "access_token:libtokenid_sdk", "app_file_service:remote_file_share_native", "bundle_framework:appexecfwk_base", "bundle_framework:appexecfwk_core", "c_utils:utils", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", "hitrace:libhitracechain", "ipc:ipc_core", "kv_store:distributeddb", "safwk:system_ability_fwk", "samgr:samgr_proxy", "udmf:udmf_client", "udmf:utd_client", ] cflags_cc = [ "-fvisibility=hidden" ] subsystem_name = "distributeddatamgr" part_name = "datamgr_service" if (window_manager_use_sceneboard) { external_deps += [ "window_manager:libwm_lite" ] defines += [ "SCENE_BOARD_ENABLE" ] } else { external_deps += [ "window_manager:libwm" ] } }