• 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
16ohos_prebuilt_etc("updater_sa.rc") {
17  if (use_musl) {
18    source = "etc/updater_sa.cfg"
19  } else {
20    source = "etc/updater_sa.rc"
21  }
22  relative_install_dir = "init"
23  part_name = "update_service"
24}
25
26ohos_shared_library("updateservice") {
27  defines = [
28    "DUAL_ADAPTER",
29    "UPDATE_SERVICE",
30  ]
31  sources = [
32    "//base/update/updateservice/callback/src/update_callback.cpp",
33    "//base/update/updateservice/callback/src/update_callback_proxy.cpp",
34    "//base/update/updateservice/callback/src/update_callback_stub.cpp",
35    "//base/update/updateservice/engine/src/progress_thread.cpp",
36    "//base/update/updateservice/engine/src/update_helper.cpp",
37    "//base/update/updateservice/engine/src/update_service.cpp",
38    "//base/update/updateservice/engine/src/update_service_stub.cpp",
39  ]
40
41  include_dirs = [
42    "//base/update/updater/services/include",
43    "//base/update/updater/utils/include",
44    "//base/update/updater/interfaces/kits/include",
45    "//utils/native/base/include",
46    "//utils/system/safwk/native/include",
47    "//base/update/updateservice/interfaces/innerkits/include",
48    "//base/update/updateservice/engine/include",
49    "//base/update/updateservice/callback/include",
50    "//foundation/distributedschedule/samgr/interfaces/innerkits/samgr_proxy/include",
51    "//foundation/distributedschedule/safwk/services/safwk/include",
52    "//foundation/distributedschedule/safwk/interfaces/innerkits/safwk",
53    "//foundation/distributedschedule/samgr/adapter/interfaces/innerkits/include",
54    "//foundation/distributedschedule/samgr/interfaces/innerkits/samgr_proxy/include",
55    "//third_party/cJSON",
56    "//third_party/libxml2/include",
57    "//third_party/curl/include",
58    "//third_party/openssl/include",
59    "//third_party/bounds_checking_function/include",
60  ]
61
62  deps = [
63    "//base/startup/syspara_lite/interfaces/innerkits/native/syspara:syspara",
64    "//base/update/updater/interfaces/kits/misc_info:libmiscinfo",
65    "//base/update/updater/interfaces/kits/packages:libpackageExt",
66    "//base/update/updater/interfaces/kits/updaterkits:libupdaterkits",
67    "//base/update/updater/services/log:libupdaterlog",
68    "//base/update/updater/utils:libutils",
69    "//third_party/bounds_checking_function:libsec_static",
70    "//third_party/cJSON:cjson_static",
71    "//third_party/curl:curl",
72    "//third_party/libxml2:xml2",
73    "//third_party/openssl:libcrypto_static",
74    "//third_party/openssl:ssl_source",
75    "//utils/native/base:utils",
76  ]
77
78  external_deps = [
79    "access_token:libaccesstoken_sdk",
80    "hiviewdfx_hilog_native:libhilog",
81    "ipc:ipc_core",
82    "ipc:ipc_single",
83    "safwk:system_ability_fwk",
84    "samgr_standard:samgr_proxy",
85    "startup_l2:syspara",
86  ]
87
88  part_name = "update_service"
89}
90