• 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("//build/ohos.gni")
15import("../../windowmanager_aafwk.gni")
16
17config("libwindow_extension_private_config") {
18  visibility = [ ":*" ]
19
20  include_dirs = [
21    "include",
22    "include/zidl",
23    "../extension_connection/include",
24    "../extension_connection/include/zidl",
25    "../../interfaces/kits/napi/window_runtime/window_napi",
26    "../../interfaces/innerkits/extension",
27    "../../interfaces/innerkits/wm",
28    "../../window_scene/interfaces/innerkits/include",
29  ]
30}
31
32## Build libwindow_extension.so
33ohos_shared_library("libwindow_extension") {
34  sources = [
35    "../extension_connection/src/zidl/window_extension_client_proxy.cpp",
36    "src/js_window_extension.cpp",
37    "src/js_window_extension_context.cpp",
38    "src/window_extension.cpp",
39    "src/window_extension_context.cpp",
40    "src/window_extension_stub_impl.cpp",
41    "src/zidl/window_extension_stub.cpp",
42  ]
43
44  configs = [
45    ":libwindow_extension_private_config",
46    "../../resources/config/build:coverage_flags",
47  ]
48
49  deps = [
50    "../../interfaces/kits/napi/window_runtime:window_native_kit",
51    "../../window_scene/interfaces/innerkits:libwsutils",
52    "../../wm:libwm",
53  ]
54
55  external_deps = [
56    "ability_base:want",
57    "ability_runtime:ability_context_native",
58    "ability_runtime:ability_manager",
59    "ability_runtime:app_context",
60    "ability_runtime:extensionkit_native",
61    "ability_runtime:napi_common",
62    "ability_runtime:runtime",
63    "c_utils:utils",
64    "common_event_service:cesfwk_innerkits",
65    "eventhandler:libeventhandler",
66    "graphic_2d:librender_service_client",
67    "hilog:libhilog",
68    "hitrace:hitrace_meter",
69    "input:libmmi-client",
70    "ipc:ipc_single",
71    "napi:ace_napi",
72  ]
73
74  part_name = "window_manager"
75  subsystem_name = "window"
76}
77
78config("window_extension_module_private_config") {
79  visibility = [ ":*" ]
80
81  include_dirs = [
82    "include",
83    "${ability_runtime_path}/interfaces/kits/native/ability/ability_runtime",
84  ]
85}
86
87## Build libwindow_extension_module.so
88ohos_shared_library("window_extension_module") {
89  sources = [ "src/window_extension_module_loader.cpp" ]
90
91  configs = [
92    ":window_extension_module_private_config",
93    "../../resources/config/build:coverage_flags",
94  ]
95
96  deps = [ ":libwindow_extension" ]
97
98  external_deps = [
99    "ability_runtime:abilitykit_native",
100    "common_event_service:cesfwk_innerkits",
101    "hilog:libhilog",
102    "napi:ace_napi",
103  ]
104  relative_install_dir = "extensionability/"
105  subsystem_name = "window"
106  part_name = "window_manager"
107}
108
109group("test") {
110  testonly = true
111  deps = [ "test:test" ]
112}
113