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") 15 16declare_args() { 17 fingerprint_auth_enabled = true 18} 19 20config("fingerprintauthservice_config") { 21 include_dirs = [ 22 "inc", 23 "../common/inc", 24 "../common/logs", 25 "../common/utils", 26 ] 27} 28 29ohos_source_set("fingerprintauthservice_source_set") { 30 sanitize = { 31 integer_overflow = true 32 ubsan = true 33 boundary_sanitize = true 34 cfi = true 35 cfi_cross_dso = true 36 debug = false 37 } 38 branch_protector_ret = "pac_ret" 39 sources = [ 40 "src/fingerprint_auth_all_in_one_executor_hdi.cpp", 41 "src/fingerprint_auth_driver_hdi.cpp", 42 "src/fingerprint_auth_executor_callback_hdi.cpp", 43 "src/fingerprint_auth_interface_adapter.cpp", 44 "src/fingerprint_auth_service.cpp", 45 "src/memory_guard.cpp", 46 "src/sa_command_manager.cpp", 47 "src/sensor_illumination_manager.cpp", 48 "src/service_ex_manager.cpp", 49 ] 50 51 public_configs = [ ":fingerprintauthservice_config" ] 52 53 external_deps = [ 54 "c_utils:utils", 55 "drivers_interface_fingerprint_auth:libfingerprint_auth_proxy_2.0", 56 "hdf_core:libhdf_utils", 57 "hilog:libhilog", 58 "ipc:ipc_core", 59 "miscdevice:vibrator_interface_native", 60 "safwk:system_ability_fwk", 61 "samgr:samgr_proxy", 62 "user_auth_framework:userauth_executors", 63 ] 64 65 if (use_musl) { 66 if (musl_use_jemalloc && musl_use_jemalloc_dfx_intf) { 67 defines = [ "CONFIG_USE_JEMALLOC_DFX_INTF" ] 68 } 69 } 70 71 remove_configs = [ "//build/config/compiler:no_exceptions" ] 72 73 subsystem_name = "useriam" 74 part_name = "fingerprint_auth" 75} 76 77ohos_shared_library("fingerprintauthservice") { 78 sanitize = { 79 integer_overflow = true 80 ubsan = true 81 boundary_sanitize = true 82 cfi = true 83 cfi_cross_dso = true 84 debug = false 85 } 86 branch_protector_ret = "pac_ret" 87 deps = [ ":fingerprintauthservice_source_set" ] 88 89 external_deps = [ "hilog:libhilog" ] 90 91 if (use_musl) { 92 version_script = "fingerprint_auth_service_map" 93 } 94 95 subsystem_name = "useriam" 96 part_name = "fingerprint_auth" 97} 98