1# Copyright (c) 2022 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")
15
16config("userauth_executors_public_config") {
17  include_dirs = [
18    "../../../interfaces/inner_api",
19    "../../../interfaces/inner_api/iam_executor",
20  ]
21}
22
23ohos_shared_library("userauth_executors") {
24  sanitize = {
25    integer_overflow = true
26    ubsan = true
27    boundary_sanitize = true
28    cfi = true
29    cfi_cross_dso = true
30    debug = false
31    blocklist = "../../../cfi_blocklist.txt"
32  }
33  branch_protector_ret = "pac_ret"
34  sources = [
35    "src/async_command/async_command_base.cpp",
36    "src/async_command/auth_command.cpp",
37    "src/async_command/collect_command.cpp",
38    "src/async_command/custom_command.cpp",
39    "src/async_command/enroll_command.cpp",
40    "src/async_command/identify_command.cpp",
41    "src/driver.cpp",
42    "src/driver_manager.cpp",
43    "src/executor.cpp",
44    "src/framework/executor_mgr_wrapper.cpp",
45    "src/framework/framework_executor_callback.cpp",
46    "src/iauth_executor_hdi.cpp",
47    "src/idriver_manager.cpp",
48    "src/listener/auth_executor_mgr_status_listener.cpp",
49    "src/listener/driver_manager_status_listener.cpp",
50  ]
51
52  include_dirs = [
53    "include",
54    "include/async_command",
55    "include/framework",
56    "include/listener",
57  ]
58
59  configs = [ "../../../common:iam_log_config" ]
60
61  public_configs = [ ":userauth_executors_public_config" ]
62
63  remove_configs = [ "//build/config/compiler:no_exceptions" ]
64
65  if (use_musl) {
66    version_script = "user_auth_executors_map"
67  }
68
69  deps = [
70    "../../../common:iam_utils",
71    "../../../frameworks/native/client:userauth_client",
72    "../../../frameworks/native/common:attributes",
73    "../../../frameworks/native/common:dfx",
74  ]
75
76  external_deps = [
77    "c_utils:utils",
78    "hdf_core:libhdi",
79    "hilog:libhilog",
80    "init:libbeget_proxy",
81    "ipc:ipc_single",
82    "samgr:samgr_proxy",
83  ]
84
85  subsystem_name = "useriam"
86  part_name = "user_auth_framework"
87}
88