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") 16 17group("build_module") { 18 if (datamgr_service_cloud) { 19 deps = [ ":opencloudextension" ] 20 } 21} 22config("module_public_config") { 23 visibility = [ ":*" ] 24 include_dirs = [ 25 "../../framework/include", 26 ] 27} 28 29ohos_shared_library("opencloudextension") { 30 include_dirs = [ "../ylong_cloud_extension/include" ] 31 sources = [ 32 "asset_loader_impl.cpp", 33 "cloud_cursor_impl.cpp", 34 "cloud_db_impl.cpp", 35 "cloud_server_impl.cpp", 36 "extension_util.cpp", 37 ] 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 cflags = [ 47 "-Werror", 48 "-Wno-multichar", 49 ] 50 51 cflags_cc = [ "-fvisibility=hidden" ] 52 53 configs = [ ":module_public_config" ] 54 55 deps = [ 56 "../../framework:distributeddatasvcfwk", 57 "../ylong_cloud_extension:ylong_cloud_extension", 58 ] 59 60 external_deps = [ 61 "access_token:libaccesstoken_sdk", 62 "hilog:libhilog", 63 "json:nlohmann_json_static", 64 "c_utils:utils", 65 "kv_store:datamgr_common", 66 ] 67 subsystem_name = "distributeddatamgr" 68 part_name = "datamgr_service" 69}