• 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    "../../../innerkits/dm",
37    "../../../../utils/include",
38    "../../../../wm/include",
39    "../../../../wmserver/include",
40  ]
41}
42
43config("window_native_kit_public_config") {
44  visibility = [ ":*" ]
45
46  include_dirs = [ "window_napi" ]
47}
48
49config("windowstage_kit_public_config") {
50  visibility = [ ":*" ]
51
52  include_dirs = [ "window_stage_napi" ]
53}
54
55ohos_shared_library("window_native_kit") {
56  branch_protector_ret = "pac_ret"
57  sanitize = {
58    cfi = true
59    cfi_cross_dso = true
60    cfi_vcall_icall_only = true
61    debug = false
62  }
63  sources = [
64    "window_napi/js_extension_window_config.cpp",
65    "window_napi/js_transition_controller.cpp",
66    "window_napi/js_window.cpp",
67    "window_napi/js_window_listener.cpp",
68    "window_napi/js_window_register_manager.cpp",
69    "window_napi/js_window_utils.cpp",
70  ]
71
72  public_configs = [ ":window_native_kit_public_config" ]
73
74  configs = [
75    ":window_native_kit_config",
76    "../../../../resources/config/build:coverage_flags",
77  ]
78
79  deps = [
80    "../../../../utils:libwmutil",
81    "../../../../utils:libwmutil_base",
82    "../../../../wm:libwm",
83    "../common:wm_napi_util",
84    "${window_base_path}/interfaces/kits/napi/window_animation:window_animation_utils",
85  ]
86
87  external_deps = [
88    "ability_runtime:ability_manager",
89    "ability_runtime:dialog_request_info",
90    "ability_runtime:extensionkit_native",
91    "ability_runtime:runtime",
92    "access_token:libaccesstoken_sdk",
93    "ace_engine:ace_uicontent",
94    "bundle_framework:appexecfwk_base",
95    "c_utils:utils",
96    "eventhandler:libeventhandler",
97    "hilog:libhilog",
98    "hitrace:hitrace_meter",
99    "image_framework:image",
100    "image_framework:image_native",
101    "ipc:ipc_napi",
102    "ipc:ipc_single",
103    "napi:ace_napi",
104  ]
105
106  innerapi_tags = [ "platformsdk" ]
107  part_name = "window_manager"
108  subsystem_name = "window"
109
110  defines = []
111  if (build_variant == "user") {
112    defines += [ "IS_RELEASE_VERSION" ]
113  }
114}
115
116ohos_shared_library("window_napi") {
117  branch_protector_ret = "pac_ret"
118  sanitize = {
119    cfi = true
120    cfi_cross_dso = true
121    cfi_vcall_icall_only = true
122    debug = false
123  }
124  defines = [ "SUPPORT_SCREEN" ]
125  sources = [
126    "window_manager_napi/js_window_manager.cpp",
127    "window_manager_napi/window_manager_module.cpp",
128    "window_napi/js_ui_effect_controller.cpp",
129  ]
130
131  configs = [
132    ":window_manager_napi_config",
133    "../../../../resources/config/build:coverage_flags",
134  ]
135
136  deps = [
137    ":window_native_kit",
138    "../../../../dm:libdm",
139    "../../../../utils:libwmutil",
140    "../../../../utils:libwmutil_base",
141    "../../../../window_scene/interfaces/innerkits:libwsutils",
142    "../../../../wm:libwm",
143    "../common:wm_napi_util",
144    "${window_base_path}/interfaces/kits/napi/window_animation:window_animation_utils",
145    "${window_base_path}/window_scene/session:ui_effect_controller_client",
146  ]
147
148  external_deps = [
149    "ability_runtime:ability_context_native",
150    "ability_runtime:abilitykit_native",
151    "ability_runtime:runtime",
152    "ability_runtime:wantagent_innerkits",
153    "c_utils:utils",
154    "common_event_service:cesfwk_innerkits",
155    "graphic_2d:librender_service_base",
156    "graphic_2d:librender_service_client",
157    "graphic_2d:window_animation",
158    "hilog:libhilog",
159    "hitrace:hitrace_meter",
160    "image_framework:image",
161    "napi:ace_napi",
162  ]
163
164  relative_install_dir = "module"
165
166  part_name = "window_manager"
167  subsystem_name = "window"
168
169  defines = []
170  if (build_variant == "user") {
171    defines += [ "IS_RELEASE_VERSION" ]
172  }
173}
174
175ohos_shared_library("windowstage_kit") {
176  branch_protector_ret = "pac_ret"
177  sanitize = {
178    cfi = true
179    cfi_cross_dso = true
180    cfi_vcall_icall_only = true
181    debug = false
182  }
183  sources = [ "window_stage_napi/js_window_stage.cpp" ]
184
185  configs = [
186    ":window_native_kit_config",
187    "../../../../resources/config/build:coverage_flags",
188  ]
189
190  public_configs = [ ":windowstage_kit_public_config" ]
191  include_dirs = [ "window_stage_napi" ]
192  deps = [
193    ":window_native_kit",
194    "../../../../utils:libwmutil",
195    "../../../../utils:libwmutil_base",
196    "../../../../wm:libwm",
197    "../common:wm_napi_util",
198  ]
199
200  external_deps = [
201    "ability_runtime:ability_manager",
202    "ability_runtime:runtime",
203    "c_utils:utils",
204    "hilog:libhilog",
205    "ipc:ipc_single",
206    "napi:ace_napi",
207  ]
208
209  innerapi_tags = [ "platformsdk" ]
210  part_name = "window_manager"
211  subsystem_name = "window"
212
213  defines = []
214  if (build_variant == "user") {
215    defines += [ "IS_RELEASE_VERSION" ]
216  }
217}
218