1# Copyright (c) 2021-2022 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13
14import("//build/ohos.gni")
15import("//foundation/arkui/ace_engine/ace_config.gni")
16
17template("pa_backend") {
18  forward_variables_from(invoker, "*")
19
20  ohos_source_set(target_name) {
21    subsystem_name = ace_engine_subsystem
22    part_name = ace_engine_part
23    configs = [ "$ace_root:ace_config" ]
24
25    deps = []
26
27    external_deps = [
28      "ability_base:want",
29      "ability_base:zuri",
30      "ability_runtime:abilitykit_native",
31      "ability_runtime:appkit_native",
32      "bundle_framework:appexecfwk_core",
33      "c_utils:utils",
34      "eventhandler:libeventhandler",
35      "hilog:libhilog",
36      "i18n:intl_util",
37      "ipc:ipc_core",
38      "ipc:ipc_napi",
39      "napi:ace_napi",
40      "relational_store:native_dataability",
41      "relational_store:native_rdb",
42      "safwk:system_ability_fwk",
43    ]
44
45    sources = [
46      "engine/common/js_backend_engine_loader.cpp",
47      "pa_backend.cpp",
48    ]
49  }
50}
51
52foreach(item, ace_platforms) {
53  pa_backend("pa_backend_" + item.name) {
54    config = {
55    }
56
57    if (defined(item.config)) {
58      config = item.config
59    }
60  }
61}
62