• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-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("../../../user_auth_framework.gni")
16
17config("userauth_client_config") {
18  include_dirs = [
19    "inc",
20    "../../../interfaces/inner_api",
21  ]
22}
23
24ohos_shared_library("userauth_client") {
25  sanitize = {
26    integer_overflow = true
27    ubsan = true
28    boundary_sanitize = true
29    cfi = true
30    cfi_cross_dso = true
31    debug = false
32    blocklist = "../../../cfi_blocklist.txt"
33  }
34  branch_protector_ret = "pac_ret"
35  include_dirs = [
36    "inc",
37    "../../../interfaces/inner_api",
38    "../../js/napi/user_auth/inc",
39  ]
40
41  sources = [
42    "src/auth_message_impl.cpp",
43    "src/callback_manager_impl.cpp",
44    "src/co_auth_client_impl.cpp",
45    "src/executor_callback_service.cpp",
46    "src/executor_messenger_client.cpp",
47    "src/ipc_client_utils.cpp",
48    "src/load_mode_client_util.cpp",
49    "src/modal_callback_service.cpp",
50    "src/user_access_ctrl_callback_service.cpp",
51    "src/user_access_ctrl_client_impl.cpp",
52    "src/user_auth_callback_service.cpp",
53    "src/user_auth_client_impl.cpp",
54    "src/user_auth_modal_inner_callback.cpp",
55    "src/user_auth_napi_client_impl.cpp",
56    "src/user_idm_callback_service.cpp",
57    "src/user_idm_client_impl.cpp",
58    "src/widget_callback_service.cpp",
59  ]
60
61  defines = []
62
63  if (user_auth_framework_enable_dynamic_load) {
64    defines += [ "ENABLE_DYNAMIC_LOAD" ]
65  }
66
67  configs = [
68    "../../../common:iam_log_config",
69    "../../../common:iam_utils_config",
70  ]
71
72  remove_configs = [ "//build/config/compiler:no_exceptions" ]
73
74  public_configs = [
75    ":userauth_client_config",
76    "../ipc:userauth_client_ipc_config",
77  ]
78
79  innerapi_tags = [ "platformsdk" ]
80
81  deps = [
82    "../common:attributes",
83    "../common:dfx",
84    "../ipc:userauth_client_ipc",
85  ]
86
87  if (use_musl) {
88    version_script = "user_auth_client_map"
89  }
90
91  external_deps = [
92    "access_token:libaccesstoken_sdk",
93    "c_utils:utils",
94    "hilog:libhilog",
95    "init:libbeget_proxy",
96    "init:libbegetutil",
97    "ipc:ipc_single",
98    "ipc:ipc_single",
99    "napi:ace_napi",
100    "samgr:samgr_proxy",
101  ]
102
103  subsystem_name = "useriam"
104  part_name = "user_auth_framework"
105}
106