• 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("//base/notification/distributed_notification_service/notification.gni")
15import("//build/ohos.gni")
16
17cflags = []
18
19config("native_module_config") {
20  visibility = [ ":*" ]
21
22  include_dirs = []
23
24  if (target_cpu == "arm") {
25    cflags += [ "-DBINDER_IPC_32BIT" ]
26  }
27}
28
29ohos_shared_library("notificationsubscribe") {
30  include_dirs = [
31    "${ability_runtime_path}/interfaces/kits/native/ability/native",
32    "${ability_runtime_napi_path}/inner/napi_common",
33    "//foundation/multimedia/image_framework/interfaces/kits/js/common/include/",
34    "../../include",
35    "../../include/subscribe",
36    "//third_party/node/src",
37    "//third_party/libuv/include",
38  ]
39
40  configs = [ ":native_module_config" ]
41
42  sources = [
43    "../common.cpp",
44    "../constant.cpp",
45    "../remove.cpp",
46    "../subscribe.cpp",
47    "../unsubscribe.cpp",
48    "init_module.cpp",
49    "napi_remove.cpp",
50    "napi_subscribe.cpp",
51  ]
52
53  deps = [
54    "${ability_runtime_napi_path}/inner/napi_common:napi_common",
55    "${core_path}:ans_core",
56    "//foundation/multimedia/image_framework/interfaces/kits/js/common:image",
57  ]
58
59  external_deps = [
60    "ability_base:want",
61    "ability_base:zuri",
62    "ability_runtime:abilitykit_native",
63    "ability_runtime:wantagent_innerkits",
64    "c_utils:utils",
65    "hiviewdfx_hilog_native:libhilog",
66    "napi:ace_napi",
67    "relational_store:native_rdb",
68  ]
69
70  relative_install_dir = "module"
71  subsystem_name = "${subsystem_name}"
72  part_name = "${component_name}"
73}
74