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") 15 16ohos_shared_library("libpin_auth_interface_service_2.1") { 17 sanitize = { 18 integer_overflow = true 19 ubsan = true 20 boundary_sanitize = true 21 cfi = true 22 cfi_cross_dso = true 23 debug = false 24 } 25 branch_protector_ret = "pac_ret" 26 include_dirs = [ 27 "service/inc", 28 "adaptor/inc", 29 "common/inc", 30 "database/inc", 31 "main/inc", 32 "../common/logs", 33 "../common/utils", 34 ] 35 sources = [ 36 "adaptor/src/adaptor_algorithm.c", 37 "adaptor/src/adaptor_file.c", 38 "adaptor/src/adaptor_memory.c", 39 "adaptor/src/adaptor_time.c", 40 "adaptor/src/buffer.c", 41 "adaptor/src/file_operator.c", 42 "common/src/attribute.c", 43 "common/src/c_array.c", 44 "database/src/pin_db.c", 45 "database/src/pin_db_ops.c", 46 "database/src/pin_db_ops_base.c", 47 "database/src/pin_db_ops_v0.c", 48 "database/src/pin_db_ops_v1.c", 49 "main/src/all_in_one_func.c", 50 "main/src/collector_func.c", 51 "main/src/executor_func_common.c", 52 "main/src/pin_auth.cpp", 53 "main/src/verifier_func.c", 54 "service/src/all_in_one_impl.cpp", 55 "service/src/collector_impl.cpp", 56 "service/src/executor_impl_common.cpp", 57 "service/src/pin_auth_interface_service.cpp", 58 "service/src/verifier_impl.cpp", 59 ] 60 61 external_deps = [ 62 "c_utils:utils", 63 "drivers_interface_pin_auth:pin_auth_idl_headers", 64 "hilog:libhilog", 65 "init:libbegetutil", 66 "ipc:ipc_single", 67 "openssl:libcrypto_shared", 68 ] 69 70 install_images = [ chipset_base_dir ] 71 remove_configs = [ "//build/config/compiler:no_exceptions" ] 72 subsystem_name = "hdf" 73 part_name = "drivers_peripheral_pin_auth" 74} 75 76ohos_shared_library("libpin_auth_driver") { 77 sanitize = { 78 integer_overflow = true 79 ubsan = true 80 boundary_sanitize = true 81 cfi = true 82 cfi_cross_dso = true 83 debug = false 84 } 85 branch_protector_ret = "pac_ret" 86 include_dirs = [ 87 "service/inc", 88 "main/inc", 89 "../common/logs", 90 "../common/utils", 91 ] 92 sources = [ "service/src/pin_auth_interface_driver.cpp" ] 93 deps = [ "../hdi_service:libpin_auth_interface_service_2.1" ] 94 95 external_deps = [ 96 "c_utils:utils", 97 "drivers_interface_pin_auth:libpin_auth_stub_2.1", 98 "hdf_core:libhdf_host", 99 "hdf_core:libhdf_ipc_adapter", 100 "hdf_core:libhdf_utils", 101 "hdf_core:libhdi", 102 "hilog:libhilog", 103 "ipc:ipc_single", 104 ] 105 106 shlib_type = "hdi" 107 install_images = [ chipset_base_dir ] 108 remove_configs = [ "//build/config/compiler:no_exceptions" ] 109 subsystem_name = "hdf" 110 part_name = "drivers_peripheral_pin_auth" 111} 112 113group("hdf_pin_auth_service") { 114 deps = [ 115 ":libpin_auth_driver", 116 ":libpin_auth_interface_service_2.1", 117 ] 118} 119