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 "${kv_store_common_path}", 27 ] 28} 29 30ohos_shared_library("opencloudextension") { 31 include_dirs = [ "../ylong_cloud_extension/include" ] 32 sources = [ 33 "asset_loader_impl.cpp", 34 "cloud_cursor_impl.cpp", 35 "cloud_db_impl.cpp", 36 "cloud_server_impl.cpp", 37 "extension_util.cpp", 38 ] 39 branch_protector_ret = "pac_ret" 40 sanitize = { 41 ubsan = true 42 boundary_sanitize = true 43 cfi = true 44 cfi_cross_dso = true 45 debug = false 46 } 47 cflags = [ 48 "-Werror", 49 "-Wno-multichar", 50 ] 51 52 cflags_cc = [ "-fvisibility=hidden" ] 53 54 configs = [ ":module_public_config" ] 55 56 deps = [ 57 "../../framework:distributeddatasvcfwk", 58 "../ylong_cloud_extension:ylong_cloud_extension", 59 ] 60 61 external_deps = [ 62 "access_token:libaccesstoken_sdk", 63 "hilog:libhilog", 64 "json:nlohmann_json_static", 65 "kv_store:datamgr_common", 66 ] 67 subsystem_name = "distributeddatamgr" 68 part_name = "datamgr_service" 69} 70