1# Copyright (c) 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_var.gni") 15import("//drivers/hdf_core/adapter/uhdf2/uhdf.gni") 16import("//drivers/peripheral/audio/audio.gni") 17import("//test/xts/tools/build/suite.gni") 18 19import("//build/ohos.gni") 20import("//build/test.gni") 21import("//drivers/peripheral/camera/hal/camera.gni") 22 23module_output_path = "hats/camera" 24 25config("cameraTest_config") { 26 visibility = [ ":*" ] 27} 28 29ohos_moduletest_suite("HatsHdfCameraPipelineTest") { 30 testonly = true 31 module_out_path = module_output_path 32 sources = [ 33 "./pipeline_core_test.cpp", 34 "./stream_pipeline_builder_test.cpp", 35 "./stream_pipeline_dispatcher_test.cpp", 36 "./stream_pipeline_strategy_test.cpp", 37 ] 38 39 include_dirs = [ 40 "//third_party/googletest/googletest/include/gtest", 41 "$camera_path/../interfaces/include", 42 "$camera_path/../interfaces/hdi_ipc", 43 "$camera_path/../interfaces/hdi_ipc/utils/include", 44 "$camera_path/../interfaces/hdi_ipc/callback/host/include", 45 "$camera_path/../interfaces/hdi_ipc/callback/device/include", 46 "$camera_path/../interfaces/hdi_ipc/callback/operator/include", 47 "$camera_path/include", 48 "$camera_path/hdi_impl", 49 "$camera_path/hdi_impl/include", 50 "$camera_path/hdi_impl/include/camera_host", 51 "$camera_path/hdi_impl/include/camera_device", 52 "$camera_path/hdi_impl/include/stream_operator", 53 "$camera_path/hdi_impl/include/offline_stream_operator", 54 "$camera_path/hdi_impl/src/stream_operator/stream_tunnel/standard", 55 "$camera_path/device_manager/include/", 56 "$camera_path/device_manager/include/v4l2", 57 "$camera_path/utils/event", 58 "//drivers/peripheral/camera/interfaces/metadata/include", 59 "//drivers/peripheral/display/interfaces/include", 60 "//drivers/peripheral/display/hdi_service/gralloc/include", 61 "//drivers/peripheral/base", 62 "//base/hiviewdfx/interfaces/innerkits/libhilog/include", 63 64 #producer 65 "//commonlibrary/c_utils/base/include", 66 "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", 67 "$camera_path/pipeline_core/utils", 68 "$camera_path/pipeline_core/include", 69 "$camera_path/pipeline_core/host_stream/include", 70 "$camera_path/pipeline_core/nodes/include", 71 "$camera_path/pipeline_core/nodes/src/node_base", 72 "$camera_path/pipeline_core/nodes/src/dummy_node", 73 "$camera_path/pipeline_core/pipeline_impl/src/strategy/config", 74 "$camera_path/pipeline_core/pipeline_impl/include", 75 "$camera_path/pipeline_core/pipeline_impl/src", 76 "$camera_path/pipeline_core/pipeline_impl/src/builder", 77 "$camera_path/pipeline_core/pipeline_impl/src/dispatcher", 78 "$camera_path/pipeline_core/pipeline_impl/src/parser", 79 "$camera_path/pipeline_core/pipeline_impl/src/strategy", 80 "$camera_path/pipeline_core/ipp/include", 81 82 # hcs parser 83 "//system/core/include/cutils", 84 ] 85 86 deps = [ 87 "$camera_path/buffer_manager:camera_buffer_manager", 88 "$camera_path/device_manager:camera_device_manager", 89 "$camera_path/hdi_impl:camera_host_service_1.0", 90 "$camera_path/pipeline_core:camera_pipeline_core", 91 "//drivers/interface/camera/v1_0:libcamera_proxy_1.0", 92 "//drivers/peripheral/camera/interfaces/metadata:metadata", 93 "//third_party/googletest:gmock", 94 "//third_party/googletest:gmock_main", 95 "//third_party/googletest:gtest", 96 "//third_party/googletest:gtest_main", 97 ] 98 99 if (is_standard_system) { 100 external_deps = [ 101 "c_utils:utils", 102 "graphic_chipsetsdk:surface", 103 "hdf_core:libhdf_host", 104 "hdf_core:libhdf_ipc_adapter", 105 "hdf_core:libhdf_utils", 106 "hdf_core:libhdi", 107 "hiviewdfx_hilog_native:libhilog", 108 "ipc:ipc_single", 109 ] 110 } else { 111 external_deps = [ "hilog:libhilog" ] 112 } 113 114 external_deps += [ 115 "init:libbegetutil", 116 "ipc:ipc_single", 117 "samgr:samgr_proxy", 118 ] 119 120 public_configs = [ ":cameraTest_config" ] 121 subsystem_name = "hdf" 122 part_name = "drivers_peripheral_camera" 123} 124