• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021 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.gni")
15
16###############################################################################
17
18declare_args() {
19  paramapi_feature_watcher = true
20}
21
22config("syspara_config") {
23  visibility = [ ":*" ]
24  include_dirs = [
25    "//utils/native/base/include",
26    "//base/startup/syspara_lite/hals/parameter/include",
27    "include",
28    "//third_party/openssl/include/",
29  ]
30}
31
32config("syspara_public_config") {
33  include_dirs = [
34    "include",
35    "//base/startup/syspara_lite/adapter/native/syspara/include",
36  ]
37}
38
39ohos_shared_library("syspara") {
40  include_dirs = [
41    "include",
42    "//base/startup/init_lite/services/include/param",
43    "//base/startup/syspara_lite/adapter/native/syspara/include",
44  ]
45  sources = [
46    "//base/startup/syspara_lite/adapter/native/syspara/src/parameters.cpp",
47    "//base/startup/syspara_lite/interfaces/innerkits/native/syspara/src/param_wrapper.cpp",
48    "//base/startup/syspara_lite/interfaces/innerkits/native/syspara/src/parameter.c",
49    "//base/startup/syspara_lite/interfaces/innerkits/native/syspara/src/sysversion.c",
50  ]
51  configs = [ ":syspara_config" ]
52  public_configs = [ ":syspara_public_config" ]
53  deps = [
54    "//base/startup/init_lite/services/param:param_client",
55    "//base/startup/syspara_lite/hals/parameter:sysparam_hal",
56    "//utils/native/base:utils",
57  ]
58  subsystem_name = "startup"
59  part_name = "startup_l2"
60  install_images = [
61    "system",
62    "updater",
63  ]
64}
65
66ohos_shared_library("syspara_watchagent") {
67  include_dirs = [
68    "include",
69    "//base/startup/init_lite/services/include/param",
70    "//base/startup/syspara_lite/interfaces/innerkits/native/syspara/include",
71  ]
72  sources = [ "//base/startup/syspara_lite/interfaces/innerkits/native/syspara/src/param_watchagent.cpp" ]
73  configs = [ ":syspara_config" ]
74  public_configs = [ ":syspara_public_config" ]
75  if (paramapi_feature_watcher) {
76    deps = [
77      "//base/startup/init_lite/services/param/watcher:param_watcheragent",
78      "//utils/native/base:utils",
79    ]
80  } else {
81    defines = [ "NO_PARAM_WATCHER" ]
82  }
83  subsystem_name = "startup"
84  part_name = "startup_l2"
85}
86