• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 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("//foundation/graphic/graphic_2d/rosen/modules/platform/config.gni")
16
17# ace_skia {{{
18group("ace_skia") {
19  public_deps = [ "//third_party/flutter/build/skia:ace_skia_$platform" ]
20}
21
22# ace_skia }}}
23
24# eventhandler {{{
25group("eventhandler") {
26  if (platform == "ohos") {
27    public_deps = eventhandler_deps
28  } else {
29    public_deps = [ ":impl_eventhandler" ]
30  }
31}
32
33config("eventhandler_config") {
34  include_dirs = [ "eventhandler" ]
35}
36
37ohos_source_set("impl_eventhandler") {
38  public_configs = [ ":eventhandler_config" ]
39  sources = [
40    "eventhandler_impl/epoll_io_waiter_mingw.cpp",
41    "eventhandler_impl/event_handler.cpp",
42    "eventhandler_impl/event_queue.cpp",
43    "eventhandler_impl/event_runner.cpp",
44    "eventhandler_impl/file_descriptor_listener.cpp",
45    "eventhandler_impl/inner_event.cpp",
46    "eventhandler_impl/native_implement_eventhandler.cpp",
47    "eventhandler_impl/none_io_waiter.cpp",
48  ]
49  defines = [ "LOG_DOMAIN=0xD001200" ]
50  cflags = [ "-std=c++17" ]
51  deps = [
52    ":hilog",
53    ":utils",
54    "//third_party/libuv:uv",
55  ]
56  part_name = "graphic_standard"
57  subsystem_name = "graphic"
58}
59
60# eventhandler }}}
61
62# hilog {{{
63group("hilog") {
64  public_deps = hilog_deps
65}
66
67# hilog }}}
68
69# image_native {{{
70group("image_native") {
71  if (platform == "ohos") {
72    public_deps = image_deps
73  } else {
74    public_deps = [ ":mock_image_native" ]
75  }
76}
77
78config("image_native_config") {
79  include_dirs = [ "image_native" ]
80}
81
82ohos_source_set("mock_image_native") {
83  public_configs = [ ":image_native_config" ]
84  sources = [
85    "image_native/pixel_map.cpp",
86    "image_native/pixel_map_rosen_utils.cpp",
87  ]
88  deps = [
89    ":ace_skia",
90    ":utils",
91 ]
92  part_name = "graphic_standard"
93  subsystem_name = "graphic"
94}
95
96# image_native }}}
97
98# ipc_core {{{
99group("ipc_core") {
100  if (platform == "ohos") {
101    public_deps = ipc_deps
102  } else {
103    public_deps = [ ":mock_ipc_core" ]
104  }
105}
106
107config("ipc_core_config") {
108  include_dirs = [ "ipc_core" ]
109}
110
111ohos_source_set("mock_ipc_core") {
112  public_configs = [ ":ipc_core_config" ]
113  sources = [
114    "ipc_core/ipc_object_stub.cpp",
115    "ipc_core/iremote_broker.cpp",
116    "ipc_core/iremote_object.cpp",
117    "ipc_core/message_option.cpp",
118    "ipc_core/message_parcel.cpp",
119    "ipc_core/peer_holder.cpp",
120  ]
121  deps = [ ":utils" ]
122  part_name = "graphic_standard"
123  subsystem_name = "graphic"
124}
125
126# ipc_core }}}
127
128# utils {{{
129group("utils") {
130  if (platform == "ohos") {
131    public_deps = utils_deps
132  } else {
133    public_deps = [ ":mock_utils" ]
134  }
135}
136
137config("utils_config") {
138  include_dirs = [ "utils" ]
139}
140
141ohos_source_set("mock_utils") {
142  public_configs = [ ":utils_config" ]
143  sources = [
144    "utils/directory_ex.cpp",
145    "utils/parcel.cpp",
146    "utils/refbase.cpp",
147  ]
148  public_deps = [ "//third_party/bounds_checking_function:libsec_shared" ]
149  part_name = "graphic_standard"
150  subsystem_name = "graphic"
151}
152# utils }}}
153