• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022 Shenzhen Kaihong Digital Industry Development 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
16updater_usb_init_cfg_path = "//base/startup/init/services/etc/init.usb.cfg"
17updater_init_usb_configfs_path_cfg =
18    "//drivers/peripheral/usb/cfg/init.usb.configfs.cfg"
19updater_faultloggerd_cfg =
20    "//base/hiviewdfx/faultloggerd/services/config/faultloggerd.cfg"
21updater_hilog_cfg = "//base/hiviewdfx/hilog/services/hilogd/etc/hilogd.cfg"
22ohos_prebuilt_etc("updater_hilog.cfg") {
23  source = "${updater_hilog_cfg}"
24  install_images = [ "updater" ]
25  part_name = "kaihong_products"
26}
27ohos_prebuilt_etc("updater_faultloggerd.cfg") {
28  source = "${updater_faultloggerd_cfg}"
29  install_images = [ "updater" ]
30  part_name = "kaihong_products"
31}
32ohos_prebuilt_etc("updater_init.cfg") {
33  source = "config/init.cfg"
34  install_images = [ "updater" ]
35  part_name = "kaihong_products"
36}
37
38ohos_prebuilt_etc("updater_init_usb.cfg") {
39  source = "${updater_usb_init_cfg_path}"
40  install_images = [ "updater" ]
41  part_name = "kaihong_products"
42}
43
44ohos_prebuilt_etc("updater_init_usb_configfs.cfg") {
45  source = "${updater_init_usb_configfs_path_cfg}"
46  install_images = [ "updater" ]
47  part_name = "kaihong_products"
48}
49
50# ohos_prebuilt_etc("updater_init_rk3568_usb.cfg") {
51#   source = "config/init.rk3568.usb.cfg"
52#   install_images = [ "updater" ]
53#   part_name = "kaihong_products"
54# }
55ohos_prebuilt_etc("signing_cert.crt") {
56  source = "config/signing_cert.crt"
57  module_install_dir = "etc/certificate"
58  install_images = [
59    "system",
60    "updater",
61  ]
62  part_name = "kaihong_products"
63}
64
65ohos_prebuilt_etc("fstab.updater") {
66  source = "config/fstab.updater"
67  install_images = [ "updater" ]
68  part_name = "kaihong_products"
69}
70
71if (enable_ramdisk) {
72  ohos_copy("updater_ramdisk_resource_config.ini") {
73    sources = [ "updater_ramdisk_resource_config.ini" ]
74    outputs =
75        [ "$product_output_dir/phone/updater_ramdisk_resource_config.ini" ]
76  }
77}
78
79group("updater_files") {
80  deps = [
81    ":fstab.updater",
82    ":signing_cert.crt",
83    ":updater_faultloggerd.cfg",
84    ":updater_hilog.cfg",
85    ":updater_init.cfg",
86    ":updater_init_usb_configfs.cfg",
87  ]
88  if (enable_ramdisk) {
89    deps += [ ":updater_ramdisk_resource_config.ini" ]
90  }
91}
92