1# Copyright (c) 2023 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("../ecologicalrulemgrservice.gni")
15
16config("ecologicalrulemgrservice_config") {
17  visibility = [ ":*" ]
18  include_dirs = [
19    "include",
20    "./manager/include",
21    "../utils/include",
22    "${innerkits_path}/include",
23  ]
24}
25
26ohos_shared_library("ecologicalrulemgr_service") {
27  configs = [ "${ecologicalrulemgrservice_utils_path}:utils_config" ]
28
29  public_configs = [ ":ecologicalrulemgrservice_config" ]
30
31  cflags = [
32    "-fvisibility=hidden",
33    "-fdata-sections",
34    "-ffunction-sections",
35    "-Os",
36  ]
37  cflags_cc = [
38    "-fvisibility-inlines-hidden",
39    "-Os",
40  ]
41
42  sources = [
43    "${innerkits_path}/src/ecological_rule_mgr_service_param.cpp",
44    "manager/src/ecologic_rule_mgr_service.cpp",
45    "manager/src/ecologic_rule_mgr_service_stub.cpp",
46  ]
47
48  deps = []
49  external_deps = [
50    "ability_base:want",
51    "ability_base:zuri",
52    "ability_runtime:abilitykit_native",
53    "ability_runtime:runtime",
54    "ability_runtime:wantagent_innerkits",
55    "access_token:libaccesstoken_sdk",
56    "access_token:libtokenid_sdk",
57    "bundle_framework:appexecfwk_base",
58    "bundle_framework:appexecfwk_core",
59    "c_utils:utils",
60    "hilog:libhilog",
61    "ipc:ipc_core",
62    "safwk:system_ability_fwk",
63    "samgr:samgr_proxy",
64  ]
65  public_external_deps = [
66    "bundle_framework:appexecfwk_core",
67    "ipc:ipc_core",
68    "json:nlohmann_json_static",
69    "samgr:samgr_proxy",
70  ]
71  part_name = "ecological_rule_manager"
72  subsystem_name = "bundlemanager"
73  use_exceptions = true
74}
75