• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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.
13
14import("//build/ohos.gni")
15import("//foundation/filemanagement/dfs_service/distributedfile.gni")
16
17config("clouddisk_database_config") {
18  visibility = [ ":*" ]
19}
20
21ohos_shared_library("clouddisk_database") {
22  branch_protector_ret = "pac_ret"
23  sanitize = {
24    ubsan = true
25    boundary_sanitize = true
26    cfi = true
27    cfi_cross_dso = true
28    debug = false
29  }
30  include_dirs = [
31    "include",
32    "${media_library_path}/frameworks/innerkitsimpl/media_library_helper/include",
33    "${media_library_path}/interfaces/inner_api/media_library_helper/include",
34    "${media_library_path}/frameworks/utils/include",
35    "//third_party/libfuse/include",
36  ]
37
38  sources = [
39    "${media_library_path}/frameworks/innerkitsimpl/media_library_helper/src/mimetype_utils.cpp",
40    "src/clouddisk_rdb_utils.cpp",
41    "src/clouddisk_rdbstore.cpp",
42    "src/clouddisk_sync_helper.cpp",
43    "src/file_column.cpp",
44  ]
45
46  configs = [ ":clouddisk_database_config" ]
47  cflags = [
48    "-Wall",
49    "-Werror",
50    "-Wno-unused-but-set-variable",
51  ]
52
53  defines = [
54    "LOG_DOMAIN=0xD00430B",
55    "LOG_TAG=\"CLOUDDISK_DATABASE\"",
56  ]
57
58  deps = [
59    "${innerkits_native_path}/cloudsync_kit_inner:cloudsync_kit_inner",
60    "${utils_path}:libdistributedfileutils",
61    "//third_party/libfuse:libfuse",
62  ]
63
64  external_deps = [
65    "c_utils:utils",
66    "hilog:libhilog",
67    "relational_store:native_rdb",
68  ]
69
70  use_exceptions = true
71  part_name = "dfs_service"
72  subsystem_name = "filemanagement"
73}
74