1# Copyright (C) 2022-2025 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("../../../../accessibility_manager_service.gni") 16 17ohos_shared_library("config_napi") { 18 branch_protector_ret = "pac_ret" 19 sanitize = { 20 integer_overflow = true 21 ubsan = true 22 boundary_sanitize = true 23 cfi = false 24 cfi_cross_dso = false 25 debug = false 26 } 27 28 include_dirs = [ 29 "../../../../common/log/include", 30 "../include", 31 "./include", 32 "../../../../common/interface/include", 33 ] 34 35 defines = [ 36 "AAMS_LOG_TAG = \"accessibility_napi\"", 37 "AAMS_LOG_DOMAIN = 0xD001D10", 38 ] 39 40 defines += accessibility_default_defines 41 42 if (build_variant == "user") { 43 defines += [ "RELEASE_VERSION" ] 44 } 45 46 sources = [ 47 "../src/napi_accessibility_utils.cpp", 48 "./src/napi_accessibility_config_observer.cpp", 49 "./src/napi_accessibility_config.cpp", 50 "./src/native_module.cpp", 51 "../../../../common/interface/src/api_event_reporter.cpp", 52 ] 53 54 configs = [ "../../../../resources/config/build:coverage_flags" ] 55 56 deps = [ 57 "../../../../common/interface:accessibility_interface", 58 "../../../innerkits/acfwk:accessibilityconfig", 59 "./../../../innerkits/common:accessibility_common", 60 ] 61 62 external_deps = [ 63 "access_token:libaccesstoken_sdk", 64 "access_token:libtokenid_sdk", 65 "e2fsprogs:libext2_uuid", 66 "ffrt:libffrt", 67 "hilog:libhilog", 68 "input:libmmi-client", 69 "ipc:ipc_core", 70 "napi:ace_napi", 71 ] 72 73 if (product_name != "qemu-arm-linux-min") { 74 external_deps += [ "hiappevent:hiappevent_innerapi" ] 75 } 76 77 relative_install_dir = "module/accessibility" 78 subsystem_name = "barrierfree" 79 part_name = "accessibility" 80} 81