mirror of
https://gitee.com/openharmony/filemanagement_user_file_service
synced 2024-11-26 17:10:55 +00:00
f6545da659
Signed-off-by: zhangxiaoliang25 <zhangxiaoliang25@huawei.com> Change-Id: Ia92f4474e9f7a7806ae13b6c77437f84eb0de8a3 Signed-off-by: zhangxiaoliang25 <zhangxiaoliang25@huawei.com>
138 lines
4.3 KiB
Plaintext
138 lines
4.3 KiB
Plaintext
# Copyright (c) 2021-2024 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("//build/ohos.gni")
|
|
import("//foundation/filemanagement/user_file_service/filemanagement_aafwk.gni")
|
|
|
|
group("user_file_managers") {
|
|
deps = [
|
|
":external_file_manager_hap",
|
|
":file_access_service",
|
|
":file_access_service.cfg",
|
|
":file_access_service_profile",
|
|
]
|
|
}
|
|
|
|
ohos_hap("external_file_manager_hap") {
|
|
hap_profile = "file_extension_hap/entry/src/main/module.json"
|
|
deps = [
|
|
":external_file_manager_js_assets",
|
|
":external_file_manager_resources",
|
|
]
|
|
publicity_file = "../publicity.xml"
|
|
certificate_profile = "signature/fileextension.p7b"
|
|
hap_name = "external_file_manager"
|
|
subsystem_name = "filemanagement"
|
|
part_name = "user_file_service"
|
|
module_install_dir = "app/com.ohos.UserFile.ExternalFileManager"
|
|
}
|
|
|
|
ohos_js_assets("external_file_manager_js_assets") {
|
|
hap_profile = "file_extension_hap/entry/src/main/module.json"
|
|
ets2abc = true
|
|
source_dir = "file_extension_hap/entry/src/main/ets"
|
|
}
|
|
|
|
ohos_app_scope("external_file_manager_app_profile") {
|
|
app_profile = "file_extension_hap/AppScope/app.json"
|
|
sources = [ "file_extension_hap/AppScope/resources" ]
|
|
}
|
|
|
|
ohos_sa_profile("file_access_service_profile") {
|
|
sources = [ "5010.json" ]
|
|
part_name = "user_file_service"
|
|
}
|
|
|
|
ohos_prebuilt_etc("file_access_service.cfg") {
|
|
source = "file_access_service.cfg"
|
|
relative_install_dir = "init"
|
|
subsystem_name = "filemanagement"
|
|
part_name = "user_file_service"
|
|
}
|
|
|
|
config("ability_config") {
|
|
visibility = [ ":*" ]
|
|
include_dirs = [
|
|
"native/file_access_service/include",
|
|
"${user_file_service_path}/utils",
|
|
"${user_file_service_path}/interfaces/inner_api/file_access/include",
|
|
"${user_file_service_path}/frameworks/js/napi/file_access_module",
|
|
]
|
|
}
|
|
|
|
config("ability_public_config") {
|
|
visibility = [ ":*" ]
|
|
include_dirs = [
|
|
"native/file_access_service/include",
|
|
"${user_file_service_path}/utils",
|
|
"${user_file_service_path}/interfaces/kits/js/src/common",
|
|
]
|
|
}
|
|
|
|
ohos_resources("external_file_manager_resources") {
|
|
sources = [ "file_extension_hap/entry/src/main/resources" ]
|
|
deps = [ ":external_file_manager_app_profile" ]
|
|
hap_profile = "file_extension_hap/entry/src/main/module.json"
|
|
}
|
|
|
|
ohos_shared_library("file_access_service") {
|
|
branch_protector_ret = "pac_ret"
|
|
sanitize = {
|
|
integer_overflow = true
|
|
ubsan = true
|
|
boundary_sanitize = true
|
|
cfi = true
|
|
cfi_cross_dso = true
|
|
debug = false
|
|
}
|
|
|
|
include_dirs = [
|
|
"${user_file_service_path}/services/native/file_access_service/include",
|
|
"${user_file_service_path}/interfaces/inner_api/file_access/include",
|
|
]
|
|
shlib_type = "sa"
|
|
sources = [
|
|
"native/file_access_service/src/file_access_ext_connection.cpp",
|
|
"native/file_access_service/src/file_access_service.cpp",
|
|
"native/file_access_service/src/file_access_service_proxy.cpp",
|
|
"native/file_access_service/src/file_access_service_stub.cpp",
|
|
"native/file_access_service/src/observer_callback_proxy.cpp",
|
|
"native/file_access_service/src/observer_callback_stub.cpp",
|
|
]
|
|
configs = [ ":ability_config" ]
|
|
version_script = "libfile_access_service.map"
|
|
public_configs = [ ":ability_public_config" ]
|
|
|
|
deps = [ "${user_file_service_path}/interfaces/inner_api/file_access:file_access_extension_ability_kit" ]
|
|
|
|
external_deps = [
|
|
"ability_base:want",
|
|
"ability_base:zuri",
|
|
"ability_runtime:ability_connect_callback_stub",
|
|
"ability_runtime:ability_manager",
|
|
"ability_runtime:napi_common",
|
|
"access_token:libaccesstoken_sdk",
|
|
"access_token:libtokenid_sdk",
|
|
"bundle_framework:appexecfwk_core",
|
|
"c_utils:utils",
|
|
"hilog:libhilog",
|
|
"hitrace:hitrace_meter",
|
|
"ipc:ipc_core",
|
|
"safwk:system_ability_fwk",
|
|
"samgr:samgr_proxy",
|
|
]
|
|
|
|
subsystem_name = "filemanagement"
|
|
part_name = "user_file_service"
|
|
}
|