• 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  ]
85
86  external_deps = [
87    "ability_runtime:ability_manager",
88    "ability_runtime:dialog_request_info",
89    "ability_runtime:extensionkit_native",
90    "ability_runtime:runtime",
91    "access_token:libaccesstoken_sdk",
92    "ace_engine:ace_uicontent",
93    "bundle_framework:appexecfwk_base",
94    "c_utils:utils",
95    "eventhandler:libeventhandler",
96    "hilog:libhilog",
97    "hitrace:hitrace_meter",
98    "image_framework:image",
99    "image_framework:image_native",
100    "ipc:ipc_napi",
101    "ipc:ipc_single",
102    "napi:ace_napi",
103  ]
104
105  innerapi_tags = [ "platformsdk" ]
106  part_name = "window_manager"
107  subsystem_name = "window"
108
109  defines = []
110  if (build_variant == "user") {
111    defines += [ "IS_RELEASE_VERSION" ]
112  }
113}
114
115ohos_shared_library("window_napi") {
116  branch_protector_ret = "pac_ret"
117  sanitize = {
118    cfi = true
119    cfi_cross_dso = true
120    cfi_vcall_icall_only = true
121    debug = false
122  }
123  defines = [ "SUPPORT_SCREEN" ]
124  sources = [
125    "window_manager_napi/js_window_manager.cpp",
126    "window_manager_napi/window_manager_module.cpp",
127  ]
128
129  configs = [
130    ":window_manager_napi_config",
131    "../../../../resources/config/build:coverage_flags",
132  ]
133
134  deps = [
135    ":window_native_kit",
136    "../../../../dm:libdm",
137    "../../../../utils:libwmutil",
138    "../../../../utils:libwmutil_base",
139    "../../../../wm:libwm",
140    "../common:wm_napi_util",
141  ]
142
143  external_deps = [
144    "ability_runtime:ability_context_native",
145    "ability_runtime:abilitykit_native",
146    "ability_runtime:runtime",
147    "ability_runtime:wantagent_innerkits",
148    "c_utils:utils",
149    "common_event_service:cesfwk_innerkits",
150    "graphic_2d:librender_service_base",
151    "graphic_2d:librender_service_client",
152    "hilog:libhilog",
153    "hitrace:hitrace_meter",
154    "image_framework:image",
155    "napi:ace_napi",
156  ]
157
158  relative_install_dir = "module"
159
160  part_name = "window_manager"
161  subsystem_name = "window"
162}
163
164ohos_shared_library("windowstage_kit") {
165  branch_protector_ret = "pac_ret"
166  sanitize = {
167    cfi = true
168    cfi_cross_dso = true
169    cfi_vcall_icall_only = true
170    debug = false
171  }
172  sources = [ "window_stage_napi/js_window_stage.cpp" ]
173
174  configs = [
175    ":window_native_kit_config",
176    "../../../../resources/config/build:coverage_flags",
177  ]
178
179  public_configs = [ ":windowstage_kit_public_config" ]
180  include_dirs = [ "window_stage_napi" ]
181  deps = [
182    ":window_native_kit",
183    "../../../../utils:libwmutil",
184    "../../../../utils:libwmutil_base",
185    "../../../../wm:libwm",
186    "../common:wm_napi_util",
187  ]
188
189  external_deps = [
190    "ability_runtime:ability_manager",
191    "ability_runtime:runtime",
192    "c_utils:utils",
193    "hilog:libhilog",
194    "napi:ace_napi",
195  ]
196
197  innerapi_tags = [ "platformsdk" ]
198  part_name = "window_manager"
199  subsystem_name = "window"
200}
201