• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021-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("//build/ohos.gni")
15import("../../../../windowmanager_aafwk.gni")
16
17config("window_manager_napi_config") {
18  visibility = [ ":*" ]
19
20  include_dirs = [
21    "window_napi",
22    "window_manager_napi",
23    "../../../innerkits/wm",
24    "../../../innerkits/dm",
25    "../../../../wm/include",
26    "../../../../utils/include",
27  ]
28}
29
30config("window_native_kit_config") {
31  visibility = [ ":*" ]
32
33  include_dirs = [
34    "window_napi",
35    "../../../innerkits/wm",
36    "../../../../utils/include",
37    "../../../../wm/include",
38    "../../../../wmserver/include",
39
40    # because of pixle_map.h
41    "//foundation/multimedia/image_framework/interfaces/innerkits/include",
42  ]
43}
44
45ohos_shared_library("window_native_kit") {
46  branch_protector_ret = "pac_ret"
47  sanitize = {
48    cfi = true
49    cfi_cross_dso = true
50    debug = false
51  }
52  sources = [
53    "window_napi/js_transition_controller.cpp",
54    "window_napi/js_window.cpp",
55    "window_napi/js_window_listener.cpp",
56    "window_napi/js_window_register_manager.cpp",
57    "window_napi/js_window_utils.cpp",
58  ]
59
60  configs = [
61    ":window_native_kit_config",
62    "../../../../resources/config/build:coverage_flags",
63  ]
64
65  deps = [
66    "../../../../utils:libwmutil",
67    "../../../../wm:libwm",
68  ]
69
70  defines = []
71  if (scene_board_enabled) {
72    deps +=
73        [ "${window_base_path}/window_scene/interfaces/innerkits:libwsutils" ]
74    defines += [ "SCENE_BOARD_ENABLE" ]
75  }
76
77  external_deps = [
78    "ability_runtime:ability_manager",
79    "ability_runtime:dialog_request_info",
80    "ability_runtime:extensionkit_native",
81    "ability_runtime:runtime",
82    "access_token:libaccesstoken_sdk",
83    "ace_engine:ace_uicontent",
84    "bundle_framework:appexecfwk_base",
85    "c_utils:utils",
86    "eventhandler:libeventhandler",
87    "hilog:libhilog",
88    "hitrace:hitrace_meter",
89    "image_framework:image",
90    "image_framework:image_native",
91    "ipc:ipc_napi",
92    "ipc:ipc_single",
93    "napi:ace_napi",
94  ]
95
96  innerapi_tags = [ "platformsdk" ]
97  part_name = "window_manager"
98  subsystem_name = "window"
99}
100
101ohos_shared_library("window_napi") {
102  branch_protector_ret = "pac_ret"
103  sanitize = {
104    cfi = true
105    cfi_cross_dso = true
106    debug = false
107  }
108  sources = [
109    "window_manager_napi/js_window_manager.cpp",
110    "window_manager_napi/window_manager_module.cpp",
111  ]
112
113  configs = [
114    ":window_manager_napi_config",
115    "../../../../resources/config/build:coverage_flags",
116  ]
117
118  deps = [
119    ":window_native_kit",
120    "../../../../dm:libdm",
121    "../../../../utils:libwmutil",
122    "../../../../wm:libwm",
123  ]
124
125  external_deps = [
126    "ability_runtime:ability_context_native",
127    "ability_runtime:abilitykit_native",
128    "ability_runtime:runtime",
129    "c_utils:utils",
130    "common_event_service:cesfwk_innerkits",
131    "graphic_2d:librender_service_client",
132    "hilog:libhilog",
133    "hitrace:hitrace_meter",
134    "image_framework:image",
135    "napi:ace_napi",
136  ]
137
138  relative_install_dir = "module"
139
140  part_name = "window_manager"
141  subsystem_name = "window"
142}
143
144ohos_shared_library("windowstage_kit") {
145  branch_protector_ret = "pac_ret"
146  sanitize = {
147    cfi = true
148    cfi_cross_dso = true
149    debug = false
150  }
151  sources = [ "window_stage_napi/js_window_stage.cpp" ]
152
153  configs = [
154    ":window_native_kit_config",
155    "../../../../resources/config/build:coverage_flags",
156  ]
157
158  include_dirs = [ "window_stage_napi" ]
159  deps = [
160    ":window_native_kit",
161    "../../../../utils:libwmutil",
162    "../../../../wm:libwm",
163  ]
164
165  external_deps = [
166    "ability_runtime:runtime",
167    "c_utils:utils",
168    "hilog:libhilog",
169    "napi:ace_napi",
170  ]
171
172  innerapi_tags = [ "platformsdk" ]
173  part_name = "window_manager"
174  subsystem_name = "window"
175}
176