1# Copyright (c) 2021 - 2023 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("./camera.gni") 15 16if (defined(ohos_lite)) { 17 group("camera_hal") { 18 deps = [ 19 "hdi_service/v1_0:camera_host_service_1.0", 20 "vdi_base/common/adapter/platform/v4l2/src/driver_adapter:peripheral_camera_v4l2_adapter", 21 "vdi_base/common/buffer_manager:peripheral_camera_buffer_manager", 22 "vdi_base/common/device_manager:peripheral_camera_device_manager", 23 "vdi_base/common/metadata_manager:peripheral_camera_metadata_manager", 24 "vdi_base/common/pipeline_core:peripheral_camera_pipeline_core", 25 "vdi_base/common/utils:peripheral_camera_utils", 26 ] 27 } 28 group("camera_hal_unittest") { 29 deps = [] 30 } 31} else if (is_standard_system) { 32 group("camera_hal") { 33 if (target_cpu == "x86_64") { 34 deps = [] 35 } else { 36 deps = [ 37 "hdi_service/v1_0:camera_host_service_1.0", 38 "vdi_base/common/metadata_manager:camera_example_vendor_tag_impl", 39 "vdi_base/common/utils:peripheral_camera_utils", 40 "vdi_base/usb_camera:usb_camera_vdi_impl", 41 ] 42 if (drivers_peripheral_camera_feature_usb == false) { 43 deps += [ 44 "vdi_base/common/adapter/platform/v4l2/src/driver_adapter:peripheral_camera_v4l2_adapter", 45 "vdi_base/common/buffer_manager:peripheral_camera_buffer_manager", 46 "vdi_base/common/device_manager:peripheral_camera_device_manager", 47 "vdi_base/common/metadata_manager:peripheral_camera_metadata_manager", 48 "vdi_base/common/pipeline_core:peripheral_camera_pipeline_core", 49 ] 50 } 51 } 52 } 53 group("camera_hal_unittest") { 54 if (target_cpu == "x86_64") { 55 deps = [] 56 } else { 57 testonly = true 58 if (drivers_peripheral_camera_feature_usb == true) { 59 deps = [ "test/ut/usb_camera:camera_usb_test_ut" ] 60 } else { 61 deps = [ 62 # acceptance unit test 63 "test/hdi/metadata_test:camera_metadata_operator_ut", 64 "test/hdi/v1_0:camera_test_at", 65 66 # benchmark test 67 "test/benchmarktest/v1_0:hdf_camera_benchmark_test", 68 69 # v4l2 unit test 70 "test/ut/v4l2:camera_test_v4l2_ut", 71 72 # buffer manager unit test 73 "test/ut/buffer_manager:camera_buffer_manager_ut", 74 75 # usb camera unit test 76 "test/ut/usb_camera:camera_usb_test_ut", 77 ] 78 } 79 } 80 } 81} 82