• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2024 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("//base/location/config.gni")
15import("//build/ohos.gni")
16import("./signature/locationdialog.gni")
17
18ohos_hap("location_dialog_hap") {
19  if (location_feature_with_opp_switch == true) {
20    hap_profile = "entry/src/main/module.json"
21  } else {
22    hap_profile = "entry/src/main/pc/module.json"
23  }
24
25  deps = [
26    ":location_dialog_js_assets",
27    ":location_dialog_resources",
28  ]
29
30  publicity_file = "publicity.xml"
31  certificate_profile = "signature/locationdialog.p7b"
32  hap_name = "LocationDialog"
33  subsystem_name = "location"
34  part_name = "location"
35  module_install_dir = "app/LocationDialog"
36  if (defined(sign_hap_py_path)) {
37    certificate_profile = "${certificate_profile_path}"
38    key_alias = "LocationDialog Release"
39    private_key_path = "LocationDialog Release"
40    compatible_version = "10"
41  }
42}
43
44ohos_js_assets("location_dialog_js_assets") {
45  if (location_feature_with_opp_switch == true) {
46    hap_profile = "entry/src/main/module.json"
47  } else {
48    hap_profile = "entry/src/main/pc/module.json"
49  }
50  ets2abc = true
51  source_dir = "entry/src/main/ets"
52}
53
54ohos_app_scope("location_dialog_app_profile") {
55  app_profile = "AppScope/app.json"
56  sources = [ "AppScope/resources" ]
57}
58
59ohos_resources("location_dialog_resources") {
60  sources = [ "entry/src/main/resources" ]
61  deps = [ ":location_dialog_app_profile" ]
62  if (location_feature_with_opp_switch == true) {
63    hap_profile = "entry/src/main/module.json"
64  } else {
65    hap_profile = "entry/src/main/pc/module.json"
66  }
67}
68
69group("dialog_hap") {
70  deps = [ ":location_dialog_hap" ]
71}
72