• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-2023 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("//foundation/resourceschedule/work_scheduler/workscheduler.gni")
15
16config("worksched_private_config") {
17  include_dirs = [ "${worksched_service_path}/zidl/include" ]
18}
19
20config("worksched_public_config") {
21  include_dirs = [ "include" ]
22}
23
24ohos_shared_library("workschedextension") {
25  branch_protector_ret = "pac_ret"
26
27  sanitize = {
28    cfi = true
29    cfi_cross_dso = true
30    debug = false
31  }
32  cflags_cc = [
33    "-fdata-sections",
34    "-ffunction-sections",
35    "-fvisibility=hidden",
36    "-fstack-protector-strong",
37    "-Os",
38  ]
39  sources = [
40    "${worksched_service_path}/zidl/src/work_scheduler_stub_imp.cpp",
41    "src/js_work_scheduler_extension.cpp",
42    "src/js_work_scheduler_extension_context.cpp",
43    "src/work_scheduler_extension.cpp",
44    "src/work_scheduler_extension_context.cpp",
45    "src/work_scheduler_extension_module_loader.cpp",
46  ]
47
48  configs = [ ":worksched_private_config" ]
49
50  public_configs = [ ":worksched_public_config" ]
51
52  deps = [
53    "${worksched_frameworks_path}:workschedclient",
54    "${worksched_utils_path}:workschedutils",
55    "${worksched_zidl_path}:workschedservice_zidl_stub",
56  ]
57
58  external_deps = [
59    "ability_base:want",
60    "ability_runtime:ability_context_native",
61    "ability_runtime:ability_manager",
62    "ability_runtime:abilitykit_native",
63    "ability_runtime:app_context",
64    "ability_runtime:extensionkit_native",
65    "ability_runtime:napi_common",
66    "ability_runtime:runtime",
67    "c_utils:utils",
68    "common_event_service:cesfwk_innerkits",
69    "eventhandler:libeventhandler",
70    "hilog:libhilog",
71    "hitrace:hitrace_meter",
72    "ipc:ipc_napi",
73    "ipc:ipc_single",
74    "napi:ace_napi",
75  ]
76
77  relative_install_dir = "extensionability"
78  subsystem_name = "resourceschedule"
79  part_name = "${worksched_native_part_name}"
80}
81