• 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.
13import("//build/ohos.gni")
14import("//build/test.gni")
15import("//drivers/hdf_core/adapter/uhdf2/uhdf.gni")
16import("//test/xts/hats/build.gni")
17import("//test/xts/tools/build/suite.gni")
18
19module_output_path = "hats/codec"
20
21ohos_moduletest_suite("HatsHdfOmxCodecTest") {
22  module_out_path = module_output_path
23  include_dirs = [
24    "//drivers/hdf_core/adapter/uhdf2/include/hdi",
25    "//drivers/peripheral/codec/interfaces/include",
26    "//drivers/peripheral/codec/hal/include",
27    "//third_party/openmax/api/1.1.2",
28    "//drivers/peripheral/display/hdi_service/gralloc/include",
29  ]
30  sources = [
31    "codec_hdi_manger_test.cpp",
32    "codec_hdi_omx_test.cpp",
33  ]
34
35  cflags = [
36    "-Wall",
37    "-Wextra",
38    "-Werror",
39    "-fsigned-char",
40    "-fno-common",
41    "-fno-strict-aliasing",
42  ]
43
44  deps = [
45    "//drivers/peripheral/codec/hal:libcodec_hdi_omx_client",
46    "//third_party/googletest:gtest_main",
47  ]
48
49  if (is_standard_system) {
50    external_deps = [
51      "c_utils:utils",
52      "drivers_peripheral_display:hdi_gralloc_client",
53      "graphic_chipsetsdk:buffer_handle",
54      "hdf_core:libhdf_host",
55      "hdf_core:libhdf_ipc_adapter",
56      "hdf_core:libhdf_utils",
57      "hdf_core:libhdi",
58      "hiviewdfx_hilog_native:libhilog",
59    ]
60  } else {
61    external_deps = [ "hilog:libhilog" ]
62  }
63
64  if (xts_hats_rich == false) {
65    cflags += [ "-DSUPPORT_OMX" ]
66  }
67
68  defines = []
69  if (xts_hats_rich) {
70    defines += [ "SUPPORT_OMX" ]
71  }
72  subsystem_name = "hdf"
73  part_name = "drivers_peripheral_codec"
74}
75