• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021-2022 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 snapshot {{{
17config("snapshot_config") {
18  visibility = [ ":*" ]
19  include_dirs = [ "include" ]
20}
21
22ohos_executable("snapshot_display") {
23  branch_protector_ret = "pac_ret"
24  sanitize = {
25    cfi = true
26    cfi_cross_dso = true
27    debug = false
28  }
29  install_enable = true
30  sources = [ "src/snapshot_display.cpp" ]
31
32  configs = [
33    ":snapshot_config",
34    "../resources/config/build:coverage_flags",
35  ]
36
37  deps = [
38    ":libsnapshot_util",
39    "../dm:libdm",
40  ]
41
42  external_deps = [
43    "c_utils:utils",
44    "image_framework:image_native",
45  ]
46
47  part_name = "window_manager"
48  subsystem_name = "window"
49}
50
51ohos_shared_library("libsnapshot_util") {
52  branch_protector_ret = "pac_ret"
53  sanitize = {
54    cfi = true
55    cfi_cross_dso = true
56    debug = false
57  }
58  sources = [ "src/snapshot_utils.cpp" ]
59
60  configs = [
61    ":snapshot_config",
62    "../resources/config/build:coverage_flags",
63  ]
64
65  deps = [
66    "../dm:libdm",
67    "//third_party/libjpeg-turbo:turbojpeg_static",
68  ]
69
70  external_deps = [
71    "c_utils:utils",
72    "hitrace:hitrace_meter",
73    "image_framework:image_native",
74  ]
75
76  part_name = "window_manager"
77  subsystem_name = "window"
78}
79
80## Build snapshot }}}
81
82group("test") {
83  testonly = true
84  deps = [ "test:test" ]
85}
86