• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-2024 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_service_context_config") {
18  include_dirs = [ "inc" ]
19}
20
21ohos_source_set("userauth_service_context") {
22  sanitize = {
23    integer_overflow = true
24    ubsan = true
25    boundary_sanitize = true
26    cfi = true
27    cfi_cross_dso = true
28    debug = false
29    blocklist = "../../cfi_blocklist.txt"
30  }
31  branch_protector_ret = "pac_ret"
32  include_dirs = [
33    "inc",
34    "../../frameworks/common/inc",
35  ]
36
37  remove_configs = [ "//build/config/compiler:no_exceptions" ]
38
39  sources = [
40    "src/auth_widget_helper.cpp",
41    "src/base_context.cpp",
42    "src/context_appstate_observer.cpp",
43    "src/context_callback_impl.cpp",
44    "src/context_death_recipient.cpp",
45    "src/context_factory.cpp",
46    "src/context_helper.cpp",
47    "src/context_pool_impl.cpp",
48    "src/delete_context.cpp",
49    "src/enroll_context.cpp",
50    "src/identify_context.cpp",
51    "src/local_remote_auth_context.cpp",
52    "src/remote_auth_context.cpp",
53    "src/remote_auth_invoker_context.cpp",
54    "src/remote_auth_service.cpp",
55    "src/remote_executor_stub.cpp",
56    "src/remote_iam_callback.cpp",
57    "src/schedule_holder_context.cpp",
58    "src/simple_auth_context.cpp",
59    "src/trace.cpp",
60    "src/ui_extension_ability_connection.cpp",
61    "src/widget_client.cpp",
62    "src/widget_context.cpp",
63    "src/widget_context_callback_impl.cpp",
64    "src/widget_json.cpp",
65  ]
66
67  deps = [
68    "../../frameworks/native/common:attributes",
69    "../../frameworks/native/common:dfx",
70    "../../services/core:userauth_service_core",
71    "../../services/load_mode:userauth_service_load_mode",
72  ]
73
74  external_deps = [
75    "ability_base:base",
76    "ability_base:want",
77    "ability_base:zuri",
78    "ability_runtime:ability_connect_callback_stub",
79    "ability_runtime:ability_context_native",
80    "ability_runtime:abilitykit_native",
81    "ability_runtime:app_manager",
82    "ability_runtime:extension_manager",
83    "access_token:libaccesstoken_sdk",
84    "c_utils:utils",
85    "drivers_interface_user_auth:libuser_auth_proxy_4.0",
86    "hdf_core:libhdf_utils",
87    "hilog:libhilog",
88    "hitrace:hitrace_meter",
89    "init:libbegetutil",
90    "ipc:ipc_single",
91    "napi:ace_napi",
92    "samgr:samgr_proxy",
93    "config_policy:configpolicy_util",
94  ]
95
96  defines = []
97  if (window_manager_use_sceneboard) {
98    external_deps += [ "window_manager:libdm_lite" ]
99    defines += [ "SCENE_BOARD_ENABLE" ]
100  } else {
101    external_deps += [ "window_manager:libdm" ]
102  }
103
104  if (screenlock_client_enable) {
105    external_deps += [ "screenlock_mgr:screenlock_client" ]
106    defines += [ "SCREENLOCK_CLIENT_ENABLE" ]
107  }
108
109  public_configs = [ ":userauth_service_context_config" ]
110
111  configs = [
112    "../base:userauth_service_base_config",
113    "../../common:iam_log_config",
114    "../../common:iam_utils_config",
115    "../../frameworks/native/ipc:userauth_client_ipc_config",
116    "../remote_connect:userauth_service_remote_connect_config",
117  ]
118
119  subsystem_name = "useriam"
120  part_name = "user_auth_framework"
121}
122