# Copyright (c) 2023 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") config("ability_config") { visibility = [ ":*" ] include_dirs = [ "${print_path}/frameworks/innerkitsimpl/print_impl/include", "${print_path}/frameworks/kits/extension/include", "${print_utils_path}/include", "//third_party/node/src", ] cflags = [] if (target_cpu == "arm") { cflags += [ "-DBINDER_IPC_32BIT" ] } defines = [ "APP_LOG_TAG = \"Ability\"", "LOG_DOMAIN = 0xD002200", ] } config("ability_public_config") { visibility = [ ":*" ] include_dirs = [ "${print_path}/frameworks/innerkitsimpl/print_impl/include", "${print_path}/frameworks/kits/extension/include", "//third_party/libuv/include", "//third_party/json/include", ] cflags_cc = [ "-fno-exceptions" ] } ohos_shared_library("print_extension_framework") { include_dirs = [ "${print_path}/frameworks/helper/print_helper/include", "${print_path}/frameworks/models/print_models/include", "${print_path}/frameworks/innerkitsimpl/print_impl/include", "${print_path}/frameworks/kits/extension/include", ] sources = [ "src/js_print_callback.cpp", "src/js_print_extension.cpp", "src/js_print_extension_connection.cpp", "src/js_print_extension_context.cpp", "src/print_extension.cpp", "src/print_extension_context.cpp", ] configs = [ ":ability_config" ] public_configs = [ ":ability_public_config", "${ability_runtime_path}/frameworks/native/ability:ability_context_public_config", ] 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:want", "ability_runtime:ability_context_native", "ability_runtime:ability_manager", "ability_runtime:abilitykit_native", "ability_runtime:app_context", "ability_runtime:runtime", "c_utils:utils", "common_event_service:cesfwk_innerkits", "eventhandler:libeventhandler", "hilog:libhilog", "hitrace:hitrace_meter", "i18n:intl_util", "ipc:ipc_napi", "ipc:rpc", "napi:ace_napi", "resource_management:global_resmgr", ] subsystem_name = "print" part_name = "print_fwk" } ohos_shared_library("print_extension_module") { sources = [ "${print_path}/frameworks/kits/extension/src/print_extension_module_loader.cpp" ] configs = [ ":ability_config" ] public_configs = [ ":ability_public_config" ] deps = [ ":print_extension_framework" ] external_deps = [ "ability_base:base", "ability_base:want", "ability_base:zuri", "ability_runtime:abilitykit_native", "ability_runtime:runtime", "c_utils:utils", "common_event_service:cesfwk_innerkits", "hilog:libhilog", "hisysevent:libhisysevent", "hitrace:hitrace_meter", "i18n:intl_util", "napi:ace_napi", "resource_management:global_resmgr", ] relative_install_dir = "extensionability" subsystem_name = "print" part_name = "print_fwk" }