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
16group("hdi_gralloc_stub") {
17  deps = [ ":libhdi_display_gralloc_stub" ]
18}
19
20ohos_shared_library("libhdi_display_gralloc_stub") {
21  include_dirs = [
22    "../../../interfaces/include",
23    "../include",
24  ]
25
26  sources = [
27    "allocator_host.cpp",
28    "allocator_service_impl.cpp",
29    "allocator_service_stub.cpp",
30  ]
31
32  deps = [ "../../../hal:hdi_display_gralloc" ]
33
34  if (is_standard_system) {
35    external_deps = [
36      "hdf_core:libhdf_host",
37      "hdf_core:libhdf_ipc_adapter",
38      "hdf_core:libhdf_utils",
39      "hdf_core:libhdi",
40      "hilog:libhilog",
41      "ipc:ipc_single",
42    ]
43  } else {
44    external_deps = [ "hilog:libhilog" ]
45  }
46  external_deps += [ "graphic_surface:surface" ]
47
48  shlib_type = "hdi"
49
50  # install_enable = true
51  install_images = [ chipset_base_dir ]
52  subsystem_name = "hdf"
53  part_name = "drivers_peripheral_display"
54}
55