• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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.
13import("//build/ohos.gni")
14import("//device/board/${product_company}/${device_name}/device.gni")
15import("//drivers/peripheral/camera/camera.gni")
16import("../camera.gni")
17
18config("device_manager_config") {
19  visibility = [ ":*" ]
20
21  cflags_cc = [
22    "-Wall",
23    "-Wextra",
24    "-Werror",
25    "-Wno-error",
26    "-DGST_DISABLE_DEPRECATED",
27    "-DHAVE_CONFIG_H",
28    "-DCOLORSPACE=\"videoconvert\"",
29    "-fno-strict-aliasing",
30    "-Wno-sign-compare",
31    "-Wno-builtin-requires-header",
32    "-Wno-unused-variable",
33    "-Wno-unused-label",
34    "-Wno-implicit-function-declaration",
35    "-Wno-format",
36    "-Wno-int-conversion",
37    "-Wno-unused-function",
38    "-Wno-thread-safety-attributes",
39    "-Wno-inconsistent-missing-override",
40    "-fno-rtti",
41    "-fno-exceptions",
42    "-ffunction-sections",
43    "-fdata-sections",
44  ]
45}
46
47ohos_shared_library("camera_device_manager") {
48  sources = [
49    "$camera_device_name_path/camera/device_manager/src/rkispv5.cpp",
50    "$camera_path/adapter/platform/v4l2/src/device_manager/enumerator_manager.cpp",
51    "$camera_path/adapter/platform/v4l2/src/device_manager/flash_controller.cpp",
52    "$camera_path/adapter/platform/v4l2/src/device_manager/flash_manager.cpp",
53    "$camera_path/adapter/platform/v4l2/src/device_manager/idevice_manager.cpp",
54    "$camera_path/adapter/platform/v4l2/src/device_manager/isp_controller.cpp",
55    "$camera_path/adapter/platform/v4l2/src/device_manager/isp_manager.cpp",
56    "$camera_path/adapter/platform/v4l2/src/device_manager/sensor_controller.cpp",
57    "$camera_path/adapter/platform/v4l2/src/device_manager/sensor_manager.cpp",
58    "$camera_path/adapter/platform/v4l2/src/device_manager/v4l2_device_manager.cpp",
59    "$camera_path/device_manager/src/icontroller.cpp",
60    "$camera_path/device_manager/src/imanager.cpp",
61    "$camera_path/device_manager/src/isensor.cpp",
62  ]
63
64  include_dirs = [
65    "//base/hiviewdfx/interfaces/innerkits/libhilog/include",
66    "$camera_path/include",
67    "$camera_path/utils/event",
68    "$camera_path/device_manager/include",
69    "$camera_device_name_path/camera/device_manager/include",
70    "$camera_path/adapter/platform/v4l2/src/device_manager/include",
71    "$camera_path/adapter/platform/v4l2/src/driver_adapter/include/",
72    "//commonlibrary/c_utils/base/include",
73  ]
74
75  external_deps = [
76    "c_utils:utils",
77    "hdf_core:libhdf_utils",
78  ]
79  deps = [ "$board_camera_path/driver_adapter:camera_v4l2_adapter" ]
80
81  if (is_standard_system) {
82    external_deps += [ "hilog:libhilog" ]
83  } else {
84    external_deps += [ "hilog:libhilog" ]
85  }
86  external_deps += [ "drivers_interface_camera:metadata" ]
87  public_configs = [ ":device_manager_config" ]
88  subsystem_name = "device_yangfan"
89  part_name = "device_yangfan"
90}
91