1# Copyright (c) 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("../../../access_token.gni") 16 17config("proxy_death_handler_configs") { 18 visibility = [ ":*" ] 19 include_dirs = [ "include" ] 20} 21 22ohos_source_set("proxy_death_stub") { 23 subsystem_name = "security" 24 part_name = "access_token" 25 sanitize = { 26 cfi = true 27 cfi_cross_dso = true 28 debug = false 29 } 30 branch_protector_ret = "pac_ret" 31 32 include_dirs = [ 33 "include", 34 "${access_token_path}/interfaces/innerkits/proxy_death/include", 35 ] 36 37 sources = [ "src/proxy_death_callback_stub.cpp" ] 38 39 cflags_cc = [ "-DHILOG_ENABLE" ] 40 configs = [ 41 "${access_token_path}/config:access_token_compile_flags", 42 "${access_token_path}/config:coverage_flags", 43 ] 44 public_configs = [ ":proxy_death_handler_configs" ] 45 46 external_deps = [ 47 "c_utils:utils", 48 "hilog:libhilog", 49 "ipc:ipc_single", 50 ] 51} 52 53ohos_source_set("proxy_death_handler") { 54 subsystem_name = "security" 55 part_name = "access_token" 56 sanitize = { 57 cfi = true 58 cfi_cross_dso = true 59 debug = false 60 } 61 branch_protector_ret = "pac_ret" 62 63 include_dirs = [ "include" ] 64 65 sources = [ 66 "src/proxy_death_handler.cpp", 67 "src/proxy_death_recipient.cpp", 68 ] 69 70 cflags_cc = [ "-DHILOG_ENABLE" ] 71 configs = [ 72 "${access_token_path}/config:access_token_compile_flags", 73 "${access_token_path}/config:coverage_flags", 74 ] 75 public_configs = [ ":proxy_death_handler_configs" ] 76 77 deps = [ "${access_token_path}/frameworks/common:accesstoken_common_cxx" ] 78 79 external_deps = [ 80 "c_utils:utils", 81 "hilog:libhilog", 82 "ipc:ipc_single", 83 ] 84} 85