• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021 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")
15
16## Build libvsync_client.so {{{
17config("libvsync_client_config") {
18  visibility = [ ":*" ]
19
20  include_dirs = [
21    "include",
22    "//utils/system/safwk/native/include",
23  ]
24
25  cflags = [
26    "-Wall",
27    "-Werror",
28    "-g3",
29  ]
30}
31
32config("libvsync_client_public_config") {
33  include_dirs = [
34    "//foundation/graphic/standard/interfaces/innerkits/vsync",
35    "//utils/native/base/include",
36  ]
37}
38
39ohos_shared_library("libvsync_client") {
40  sources = [
41    "src/return_value_tester.cpp",
42    "src/static_call.cpp",
43    "src/vsync_callback_stub.cpp",
44    "src/vsync_helper.cpp",
45    "src/vsync_helper_impl.cpp",
46    "src/vsync_manager_proxy.cpp",
47  ]
48
49  configs = [ ":libvsync_client_config" ]
50
51  public_configs = [ ":libvsync_client_public_config" ]
52
53  deps = [
54    "//base/hiviewdfx/hilog/interfaces/native/innerkits:libhilog",
55    "//foundation/distributedschedule/samgr/interfaces/innerkits/samgr_proxy:samgr_proxy",
56    "//foundation/graphic/standard/utils:libgraphic_utils",
57  ]
58
59  external_deps = [ "ipc:ipc_core" ]
60
61  public_deps = [
62    "//foundation/appexecfwk/standard/interfaces/innerkits/libeventhandler:libeventhandler",
63    "//foundation/graphic/standard:libgraphic_dumper_client",
64    "//utils/native/base:utils",
65  ]
66
67  part_name = "graphic_standard"
68  subsystem_name = "graphic"
69}
70
71## Build libvsync_client.so }}}
72
73## Build libvsync_module.z.so {{{
74config("libvsync_module_config") {
75  visibility = [ ":*" ]
76
77  include_dirs = [
78    "include",
79    "//utils/system/safwk/native/include",
80  ]
81
82  cflags = [
83    "-Wall",
84    "-Werror",
85    "-g3",
86  ]
87}
88
89config("libvsync_module_public_config") {
90  include_dirs = [
91    "//foundation/graphic/standard/interfaces/innerkits/common",
92    "//foundation/graphic/standard/interfaces/innerkits/vsync_module",
93  ]
94}
95
96ohos_shared_library("libvsync_module") {
97  sources = [
98    "src/drm_module.cpp",
99    "src/return_value_tester.cpp",
100    "src/vsync_callback_death_recipient.cpp",
101    "src/vsync_callback_proxy.cpp",
102    "src/vsync_manager.cpp",
103    "src/vsync_module.cpp",
104    "src/vsync_module_c.cpp",
105    "src/vsync_module_impl.cpp",
106  ]
107
108  configs = [ ":libvsync_module_config" ]
109
110  public_configs = [ ":libvsync_module_public_config" ]
111
112  deps = [
113    "//base/hiviewdfx/hilog/interfaces/native/innerkits:libhilog",
114    "//foundation/communication/ipc/interfaces/innerkits/ipc_core:ipc_core",
115    "//foundation/distributedschedule/samgr/interfaces/innerkits/samgr_proxy:samgr_proxy",
116    "//foundation/graphic/standard/utils:libgraphic_utils",
117    "//third_party/libdrm:libdrm",
118  ]
119
120  public_deps = [
121    "//foundation/graphic/standard/utils:semaphore",
122    "//utils/native/base:utils",
123  ]
124
125  part_name = "graphic_standard"
126  subsystem_name = "graphic"
127}
128
129## Build libvsync_module.z.so }}}
130
131## Build vsync_server {{{
132ohos_executable("vsync_server") {
133  install_enable = false
134
135  sources = [ "src/module_main.cpp" ]
136
137  deps = [
138    ":libvsync_module",
139    "//foundation/communication/ipc/interfaces/innerkits/ipc_core:ipc_core",
140  ]
141
142  part_name = "graphic_standard"
143  subsystem_name = "graphic"
144}
145
146## Build vsync_server }}}
147
148## Build vsync_test {{{
149ohos_executable("vsync_test") {
150  install_enable = false
151
152  sources = [ "test/nativetest/main.cpp" ]
153
154  deps = [ ":libvsync_client" ]
155
156  part_name = "graphic_standard"
157  subsystem_name = "graphic"
158}
159