mirror of
https://github.com/openharmony/ability_ability_runtime.git
synced 2026-08-24 22:21:36 -04:00
a6827b1f47
Issue:https://gitee.com/openharmony/arkcompiler_toolchain/issues/IAJ58U Signed-off-by: yangxiaoshuai2022 <yangxiaoshuai@huawei.com>
186 lines
6.7 KiB
Plaintext
186 lines
6.7 KiB
Plaintext
# 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("//build/ohos.gni")
|
|
import("//foundation/ability/ability_runtime/ability_runtime.gni")
|
|
|
|
if (is_mac) {
|
|
dylib_suffix = ".dylib"
|
|
} else {
|
|
dylib_suffix = ".dll"
|
|
}
|
|
|
|
not_needed("*", [ "dylib_suffix" ])
|
|
|
|
ohos_copy("ability_simulator_copy_ability_modules") {
|
|
deps = []
|
|
sources = []
|
|
|
|
napi_modules = [ "napi_module/want_constant:wantconstant_napi" ]
|
|
|
|
foreach(module, napi_modules) {
|
|
deps += [ module ]
|
|
out_path = get_label_info(module, "root_out_dir")
|
|
out_name = get_label_info(module, "name")
|
|
sources +=
|
|
[ out_path + "/ability/ability_runtime/lib" + out_name + dylib_suffix ]
|
|
}
|
|
|
|
target_path = get_label_info(":copy_ability_simulator", "target_out_dir")
|
|
|
|
outputs = [ target_path + "/bin/module/ability/{{source_file_part}}" ]
|
|
}
|
|
|
|
ohos_copy("ability_simulator_copy_application_modules") {
|
|
deps = []
|
|
sources = []
|
|
|
|
napi_modules = [
|
|
"napi_module/ability:ability_napi",
|
|
"napi_module/ability_context:abilitycontext_napi",
|
|
"napi_module/ability_stage_context:abilitystagecontext_napi",
|
|
"napi_module/application_context:applicationcontext_napi",
|
|
"napi_module/caller:caller_napi",
|
|
"napi_module/callee:callee",
|
|
"napi_module/context:context_napi",
|
|
]
|
|
|
|
foreach(module, napi_modules) {
|
|
deps += [ module ]
|
|
out_path = get_label_info(module, "root_out_dir")
|
|
out_name = get_label_info(module, "name")
|
|
sources +=
|
|
[ out_path + "/ability/ability_runtime/lib" + out_name + dylib_suffix ]
|
|
}
|
|
|
|
target_path = get_label_info(":copy_ability_simulator", "target_out_dir")
|
|
|
|
outputs = [ target_path + "/bin/module/application/{{source_file_part}}" ]
|
|
}
|
|
|
|
ohos_copy("ability_simulator_copy_app_ability_modules") {
|
|
deps = []
|
|
sources = []
|
|
|
|
napi_modules = [
|
|
"napi_module/embeddable_ui_ability:embeddableuiability_napi",
|
|
"napi_module/embeddable_ui_ability_context:embeddeduiextensionability_napi",
|
|
"napi_module/uiability:uiability",
|
|
"napi_module/ability_stage:abilitystage",
|
|
"napi_module/ability_constant:abilityconstant",
|
|
"napi_module/configuration_constant:configurationconstant",
|
|
]
|
|
|
|
foreach(module, napi_modules) {
|
|
deps += [ module ]
|
|
out_path = get_label_info(module, "root_out_dir")
|
|
out_name = get_label_info(module, "name")
|
|
sources +=
|
|
[ out_path + "/ability/ability_runtime/lib" + out_name + dylib_suffix ]
|
|
}
|
|
|
|
target_path = get_label_info(":copy_ability_simulator", "target_out_dir")
|
|
|
|
outputs = [ target_path + "/bin/module/app/ability/{{source_file_part}}" ]
|
|
|
|
part_name = "ability_runtime"
|
|
subsystem_name = "ability"
|
|
}
|
|
|
|
ohos_copy("copy_ability_simulator") {
|
|
deps = [
|
|
":ability_simulator_copy_ability_modules",
|
|
":ability_simulator_copy_app_ability_modules",
|
|
":ability_simulator_copy_application_modules",
|
|
]
|
|
sources = []
|
|
|
|
deps += [ "test:ability_simulator_test" ]
|
|
out_path = get_label_info("test:ability_simulator_test", "root_out_dir")
|
|
|
|
deps += [ "ability_simulator:ability_simulator" ]
|
|
out_path =
|
|
get_label_info("ability_simulator:ability_simulator", "root_out_dir")
|
|
sources += [ out_path + "/ability/ability_runtime/libability_simulator" +
|
|
dylib_suffix ]
|
|
|
|
deps += [ "${ability_base_path}:string_utils" ]
|
|
out_path = get_label_info("${ability_base_path}:string_utils", "root_out_dir")
|
|
sources +=
|
|
[ out_path + "/ability/ability_base/libstring_utils" + dylib_suffix ]
|
|
|
|
deps += [ "${arkui_path}/napi:ace_napi" ]
|
|
out_path = get_label_info("${arkui_path}/napi:ace_napi", "root_out_dir")
|
|
sources += [ out_path + "/arkui/napi/libace_napi" + dylib_suffix ]
|
|
|
|
deps += [ "//arkcompiler/ets_runtime:libark_jsruntime" ]
|
|
out_path = get_label_info("//arkcompiler/ets_runtime:libark_jsruntime",
|
|
"root_out_dir")
|
|
sources +=
|
|
[ out_path + "/arkcompiler/ets_runtime/libark_jsruntime" + dylib_suffix ]
|
|
|
|
deps += [ "//arkcompiler/toolchain/tooling:libark_ecma_debugger" ]
|
|
out_path =
|
|
get_label_info("//arkcompiler/toolchain/tooling:libark_ecma_debugger",
|
|
"root_out_dir")
|
|
sources +=
|
|
[ out_path + "/arkcompiler/toolchain/libark_tooling" + dylib_suffix ]
|
|
|
|
deps += [ "//arkcompiler/toolchain/inspector:ark_debugger" ]
|
|
out_path = get_label_info("//arkcompiler/toolchain/inspector:ark_debugger",
|
|
"root_out_dir")
|
|
sources +=
|
|
[ out_path + "/arkcompiler/toolchain/libark_inspector" + dylib_suffix ]
|
|
|
|
deps += [ "//third_party/libuv:uv" ]
|
|
out_path = get_label_info("//third_party/libuv:uv", "root_out_dir")
|
|
sources += [ out_path + "/thirdparty/libuv/libuv" + dylib_suffix ]
|
|
|
|
deps += [ "${hilog_path}/interfaces/native/innerkits:libhilog" ]
|
|
out_path =
|
|
get_label_info("${hilog_path}/interfaces/native/innerkits:libhilog",
|
|
"root_out_dir")
|
|
sources += [ out_path + "/hiviewdfx/hilog/libhilog" + dylib_suffix ]
|
|
|
|
deps += [ "//third_party/icu/icu4c:shared_icui18n" ]
|
|
out_path =
|
|
get_label_info("//third_party/icu/icu4c:shared_icui18n", "root_out_dir")
|
|
sources += [ out_path + "/thirdparty/icu/libhmicui18n" + dylib_suffix ]
|
|
|
|
deps += [ "//third_party/icu/icu4c:shared_icuuc" ]
|
|
out_path =
|
|
get_label_info("//third_party/icu/icu4c:shared_icuuc", "root_out_dir")
|
|
sources += [ out_path + "/thirdparty/icu/libhmicuuc" + dylib_suffix ]
|
|
|
|
deps += [ "//third_party/bounds_checking_function:libsec_shared" ]
|
|
out_path =
|
|
get_label_info("//third_party/bounds_checking_function:libsec_shared",
|
|
"root_out_dir")
|
|
sources += [ out_path + "/thirdparty/bounds_checking_function/libsec_shared" +
|
|
dylib_suffix ]
|
|
|
|
deps += [ "${ets_utils_path}/js_sys_module/timer:timer" ]
|
|
out_path = get_label_info("${ets_utils_path}/js_sys_module/timer:timer",
|
|
"root_out_dir")
|
|
sources += [ out_path + "/commonlibrary/ets_utils/libtimer" + dylib_suffix ]
|
|
|
|
deps += [ "${ets_utils_path}/js_sys_module/console:console" ]
|
|
out_path = get_label_info("${ets_utils_path}/js_sys_module/console:console",
|
|
"root_out_dir")
|
|
sources += [ out_path + "/commonlibrary/ets_utils/libconsole" + dylib_suffix ]
|
|
|
|
outputs = [ target_out_dir + "/bin/{{source_file_part}}" ]
|
|
module_source_dir = target_out_dir + "/bin"
|
|
module_install_name = ""
|
|
}
|