# Copyright (c) 2022 Huawei Device Co., Ltd. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import("//base/print/print_fwk/print.gni") import("//build/ohos.gni") cflags_cc = [] config("print_interfaces_kits_napi_config") { visibility = [ ":*" ] include_dirs = [ "include" ] cflags_cc = [ "-fno-exceptions" ] } ohos_shared_library("print_napi") { include_dirs = [ "//third_party/node/src", "//third_party/curl/include", "${print_utils_path}/include", "${print_path}/frameworks/helper/print_helper/include", "${print_path}/frameworks/models/print_models/include", "${print_path}/frameworks/innerkitsimpl/print_impl/include", ] public_configs = [ ":print_interfaces_kits_napi_config" ] branch_protector_ret = "pac_ret" sanitize = { cfi = true cfi_cross_dso = true boundary_sanitize = true debug = false integer_overflow = true ubsan = true } sources = [ "src/napi_inner_print.cpp", "src/napi_print_ext.cpp", "src/napi_print_task.cpp", "src/print_async_call.cpp", "src/print_modal_ui_callback.cpp", "src/print_module.cpp", "src/print_task.cpp", ] deps = [ "${print_path}/frameworks/helper/print_helper:print_helper", "${print_path}/frameworks/innerkitsimpl/print_impl:print_client", "${print_path}/frameworks/models/print_models:print_models", ] external_deps = [ "ability_base:base", "ability_base:want", "ability_base:zuri", "ability_runtime:ability_context_native", "ability_runtime:ability_manager", "ability_runtime:abilitykit_native", "ability_runtime:data_ability_helper", "ability_runtime:napi_base_context", "ability_runtime:ui_extension", "access_token:libaccesstoken_sdk", "ace_engine:ace_uicontent", "bundle_framework:appexecfwk_core", "c_utils:utils", "eventhandler:libeventhandler", "hilog:libhilog", "ipc:ipc_core", "napi:ace_napi", "samgr:samgr_proxy", ] if (build_variant == "user") { cflags_cc += [ "-DIS_RELEASE_VERSION" ] } relative_install_dir = "module" subsystem_name = "print" part_name = "print_fwk" }