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
14INPUT_ROOT_DIR = "./.."
15import("//build/ohos.gni")
16import("./../input.gni")
17
18ohos_shared_library("libinput_interfaces_service_1.0") {
19  include_dirs = [
20    "$INPUT_ROOT_DIR/interfaces/include/",
21    "$INPUT_ROOT_DIR/utils/include",
22    "$INPUT_ROOT_DIR/hal/include/",
23  ]
24  if (drivers_peripheral_input_feature_model) {
25    deps = [ "$INPUT_ROOT_DIR/hal:hdi_input" ]
26  }
27  if (drivers_peripheral_input_feature_udriver) {
28    include_dirs += [ "$INPUT_ROOT_DIR/udriver/include/" ]
29    deps = [ "$INPUT_ROOT_DIR/udriver:hdi_input_udriver" ]
30    defines = [ "DRIVERS_PERIPHERAL_INPUT_FEATURE_UDRIVER" ]
31  }
32
33  sources = [ "input_interfaces_impl.cpp" ]
34
35  if (is_standard_system) {
36    external_deps = [
37      "c_utils:utils",
38      "drivers_interface_input:input_idl_headers",
39      "hdf_core:libhdf_utils",
40      "hilog:libhilog",
41      "ipc:ipc_single",
42    ]
43  } else {
44    external_deps = [
45      "hilog:libhilog",
46      "ipc:ipc_single",
47    ]
48  }
49
50  install_images = [ chipset_base_dir ]
51  subsystem_name = "hdf"
52  innerapi_tags = [ "passthrough_indirect" ]
53  part_name = "drivers_peripheral_input"
54}
55
56group("hdi_input_service") {
57  deps = [ ":libinput_interfaces_service_1.0" ]
58}
59