• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-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")
14
15ohos_shared_library("libagnss_interface_service_2.0") {
16  include_dirs = [
17    "//drivers/peripheral/location/agnss/hdi_service",
18  ]
19  sources = [ "agnss_interface_impl.cpp" ]
20
21  sanitize = {
22    cfi = true
23    cfi_cross_dso = true
24    debug = false
25  }
26  branch_protector_ret = "pac_ret"
27
28  cflags = [
29    "-Wall",
30    "-Wextra",
31    "-Werror",
32    "-fsigned-char",
33    "-fno-common",
34    "-fno-strict-aliasing",
35  ]
36
37  if (is_standard_system) {
38    external_deps = [
39      "c_utils:utils",
40      "drivers_interface_location_agnss:location_agnss_idl_headers",
41      "hdf_core:libhdi",
42      "hilog:libhilog",
43      "ipc:ipc_single",
44    ]
45  } else {
46    external_deps = [
47      "hilog:libhilog",
48      "ipc:ipc_single",
49    ]
50  }
51
52  external_deps +=
53      [ "drivers_peripheral_location_gnss:libgnss_interface_service_2.0" ]
54
55  install_images = [ chipset_base_dir ]
56  subsystem_name = "hdf"
57  part_name = "drivers_peripheral_location_agnss"
58}
59
60ohos_shared_library("liblocation_agnss_hdi_driver") {
61  include_dirs = [ "//drivers/peripheral/location/agnss/hdi_service" ]
62
63  sources = [ "agnss_interface_driver.cpp" ]
64
65  cflags = [
66    "-Wall",
67    "-Wextra",
68    "-Werror",
69    "-fsigned-char",
70    "-fno-common",
71    "-fno-strict-aliasing",
72  ]
73
74  if (is_standard_system) {
75    external_deps = [
76      "c_utils:utils",
77      "hdf_core:libhdf_host",
78      "hdf_core:libhdf_ipc_adapter",
79      "hdf_core:libhdf_utils",
80      "hdf_core:libhdi",
81      "hilog:libhilog",
82      "ipc:ipc_single",
83    ]
84  } else {
85    external_deps = [
86      "hilog:libhilog",
87      "ipc:ipc_single",
88    ]
89  }
90
91  external_deps +=
92      [ "drivers_interface_location_agnss:liblocation_agnss_stub_2.0" ]
93
94  shlib_type = "hdi"
95  install_images = [ chipset_base_dir ]
96  subsystem_name = "hdf"
97  part_name = "drivers_peripheral_location_agnss"
98}
99
100group("hdi_location_agnss_service") {
101  deps = [
102    ":libagnss_interface_service_2.0",
103    ":liblocation_agnss_hdi_driver",
104  ]
105}
106