1# Copyright (c) 2021-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 16## Build wm_napi_util.a {{{ 17config("wm_napi_util_config") { 18 visibility = [ ":*" ] 19 20 cflags = [ 21 "-Wall", 22 "-Werror", 23 "-g3", 24 ] 25} 26 27config("wm_napi_util_public_config") { 28 include_dirs = [ 29 ".", 30 "../../../innerkits/dm", 31 ] 32} 33 34ohos_static_library("wm_napi_util") { 35 branch_protector_ret = "pac_ret" 36 sanitize = { 37 cfi = true 38 cfi_cross_dso = true 39 cfi_vcall_icall_only = true 40 debug = false 41 integer_overflow = true 42 ubsan = true 43 boundary_sanitize = true 44 } 45 sources = [ 46 "dm_napi_common.cpp", 47 "js_err_utils.cpp", 48 ] 49 50 configs = [ 51 ":wm_napi_util_config", 52 "../../../../resources/config/build:coverage_flags", 53 ] 54 55 public_configs = [ ":wm_napi_util_public_config" ] 56 57 deps = [ 58 "../../../../utils:libwmutil", 59 "../../../../utils:libwmutil_base", 60 "../../../../wm:libwm", 61 ] 62 63 external_deps = [ 64 "access_token:libaccesstoken_sdk", 65 "bounds_checking_function:libsec_shared", 66 "bundle_framework:appexecfwk_base", 67 "hilog:libhilog", 68 "ipc:ipc_single", 69 "napi:ace_napi", 70 ] 71 72 subsystem_name = "window" 73 part_name = "window_manager" 74} 75## Build wm_napi_util.a }}} 76