# Copyright (c) Huawei Device Co., Ltd. 2026-2026. All rights reserved.
# 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("//build/ohos.gni")
import("//foundation/officeservice/object_editor/object_editor.gni")
ohos_shared_library("content_embed_ndk") {
branch_protector_ret = "pac_ret"
sanitize = {
cfi = true
cfi_cross_dso = true
debug = false
}
output_name = "content_embed_ndk"
output_extension = "so"
include_dirs = [
"include",
"${innerkits_path}/include",
"${kits_path}/c",
"${object_editor_path}/client/include",
"${object_editor_path}/common/include",
"${object_editor_path}/document/include",
"${object_editor_path}/extension_ability/include",
"${object_editor_path}/frameworks/kits/extension/include",
"${object_editor_path}/utils/include/dfx",
]
sources = [
"src/object_editor_document_capi.cpp",
"src/object_editor_extension_capi.cpp",
"src/object_editor_native_common.cpp",
"src/object_editor_proxy_capi.cpp",
"${object_editor_path}/common/src/object_editor_config.cpp",
"${object_editor_path}/common/src/system_utils.cpp",
"${object_editor_path}/document/src/object_editor_document.cpp",
"${object_editor_path}/client/src/object_editor_extension_death_recipient.cpp",
]
deps = [
"${object_editor_path}/client:content_embed_client",
"${object_editor_path}/document:content_embed_document",
"${object_editor_path}/frameworks/kits/extension:content_embed_extension"
]
configs = [
"${object_editor_path}/resources/config/build:coverage_flags",
]
external_deps = [
"ability_base:want",
"ability_base:ability_base_want",
"ability_base:configuration",
"ability_base:session_info",
"ability_runtime:ability_context_native",
"ability_runtime:ability_runtime",
"ability_runtime:ability_manager",
"ability_runtime:ability_start_options",
"ability_runtime:abilitykit_native",
"ability_runtime:app_context",
"ability_runtime:extensionkit_native",
"ability_runtime:napi_common",
"app_file_service:fileuri_native",
"bundle_framework:appexecfwk_base",
"bundle_framework:appexecfwk_core",
"c_utils:utils",
"hilog:libhilog",
"image_framework:image_native",
"image_framework:pixelmap",
"ipc:ipc_core",
"ipc:ipc_napi",
"napi:ace_napi",
"safwk:system_ability_fwk",
"hisysevent:libhisysevent",
"hitrace:hitrace_meter",
"init:libbegetutil",
"window_manager:libwm",
]
defines = []
if (object_editor_dlp_part_enabled) {
external_deps += [ "dlp_permission_service:libdlp_permission_sdk" ]
defines += [ "WITH_DLP" ]
}
relative_install_dir = "ndk/"
part_name = "object_editor"
subsystem_name = "officeservice"
}