• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021-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("../../../os_account.gni")
16
17config("public_account_config") {
18  include_dirs = [
19    "include",
20    "${common_path}/include",
21    "${innerkits_path}/include",
22    "//third_party/json/include",
23  ]
24}
25
26config("accountkits_config") {
27  defines = [
28    "ACCOUNT_LOG_TAG = \"DistributedAccountFwk\"",
29    "LOG_DOMAIN = 0xD001B00",
30  ]
31}
32
33ohos_shared_library("libaccountkits") {
34  branch_protector_ret = "pac_ret"
35
36  sanitize = {
37    cfi = true
38    cfi_cross_dso = true
39    debug = false
40  }
41
42  sources = [
43    "src/account_info_parcel.cpp",
44    "src/account_proxy.cpp",
45    "src/ohos_account_kits.cpp",
46    "src/ohos_account_kits_impl.cpp",
47    "src/system_ability_status_change_listener.cpp",
48  ]
49
50  cflags = [ "-pipe" ]
51  cflags_cc = [
52    "-Wdate-time",
53    "-Wformat=2",
54    "-Wfloat-equal",
55    "-Wshadow",
56  ]
57
58  configs = [
59    ":accountkits_config",
60    "${account_coverage_config_path}:coverage_flags",
61  ]
62
63  public_configs = [ ":public_account_config" ]
64
65  if (!use_clang_coverage) {
66    version_script = "libohos_account_innerkits.map"
67  }
68
69  deps = [ "${common_path}:libaccount_common" ]
70
71  external_deps = [
72    "ability_base:want",
73    "c_utils:utils",
74    "hilog:libhilog",
75    "ipc:ipc_single",
76    "samgr:samgr_proxy",
77  ]
78  innerapi_tags = [ "platformsdk" ]
79  subsystem_name = "account"
80  part_name = "os_account"
81}
82