• 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.
13import("//base/startup/init/begetd.gni")
14import("//build/ohos.gni")
15
16ohos_prebuilt_etc("param_watcher.rc") {
17  source = "etc/param_watcher.cfg"
18  relative_install_dir = "init"
19  part_name = "init"
20  subsystem_name = "startup"
21}
22
23ohos_shared_library("param_watcher") {
24  sources = [
25    "//base/startup/init/services/param/linux/param_message.c",
26    "proxy/watcher_manager.cpp",
27  ]
28
29  include_dirs = [
30    "//base/startup/init/services/param/include",
31    "//base/startup/init/interfaces/innerkits/include/param",
32    "//base/startup/init/services/param/linux",
33    "//base/startup/init/services/param/watcher/proxy",
34    "//base/startup/init/services/param/watcher/include",
35    "//base/startup/init/interfaces/innerkits/include",
36    "//base/startup/init/services/log",
37    "//base/startup/init/services/loopevent/include",
38  ]
39
40  deps = [
41    "//base/startup/init/interfaces/innerkits:libbegetutil",
42    "//base/startup/init/interfaces/innerkits/:param_watcher_stub",
43    "//base/startup/init/services/log:agent_log",
44  ]
45
46  branch_protector_ret = "pac_ret"
47  sanitize = {
48    cfi = true
49    cfi_cross_dso = true
50    debug = false
51  }
52
53  external_deps = [
54    "bounds_checking_function:libsec_shared",
55    "cJSON:cjson",
56    "c_utils:utils",
57    "hilog:libhilog",
58    "ipc:ipc_single",
59    "safwk:system_ability_fwk",
60    "samgr:samgr_proxy",
61  ]
62
63  if (init_paramwatcher_hicollie_enable) {
64    external_deps += [ "hicollie:libhicollie" ]
65    defines = [ "HICOLLIE_ENABLE" ]
66  }
67  shlib_type = "sa"
68  install_images = [ "system" ]
69  part_name = "init"
70  subsystem_name = "startup"
71}
72