1686862fbSopenharmony_ci# Copyright (c) 2022-2023 Huawei Device Co., Ltd.
2686862fbSopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License");
3686862fbSopenharmony_ci# you may not use this file except in compliance with the License.
4686862fbSopenharmony_ci# You may obtain a copy of the License at
5686862fbSopenharmony_ci#
6686862fbSopenharmony_ci#     http://www.apache.org/licenses/LICENSE-2.0
7686862fbSopenharmony_ci#
8686862fbSopenharmony_ci# Unless required by applicable law or agreed to in writing, software
9686862fbSopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS,
10686862fbSopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11686862fbSopenharmony_ci# See the License for the specific language governing permissions and
12686862fbSopenharmony_ci# limitations under the License.
13686862fbSopenharmony_ci
14686862fbSopenharmony_ciimport("//build/ohos.gni")
15686862fbSopenharmony_ciimport("//build/ohos_var.gni")
16686862fbSopenharmony_ciimport("//foundation/ability/dmsfwk/dmsfwk.gni")
17686862fbSopenharmony_ci
18686862fbSopenharmony_cigroup("unittest") {
19686862fbSopenharmony_ci  testonly = true
20686862fbSopenharmony_ci  deps = [ "test:unittest" ]
21686862fbSopenharmony_ci}
22686862fbSopenharmony_ci
23686862fbSopenharmony_ciconfig("distributed_ability_manager_config") {
24686862fbSopenharmony_ci  visibility = [ ":*" ]
25686862fbSopenharmony_ci  visibility += [ "./test/*" ]
26686862fbSopenharmony_ci  include_dirs = [ "include/" ]
27686862fbSopenharmony_ci  defines = []
28686862fbSopenharmony_ci  if (os_account_part) {
29686862fbSopenharmony_ci    defines += [ "OS_ACCOUNT_PART" ]
30686862fbSopenharmony_ci  }
31686862fbSopenharmony_ci}
32686862fbSopenharmony_ci
33686862fbSopenharmony_ciohos_shared_library("distributed_ability_manager_svr") {
34686862fbSopenharmony_ci  branch_protector_ret = "pac_ret"
35686862fbSopenharmony_ci  sanitize = {
36686862fbSopenharmony_ci    cfi = true
37686862fbSopenharmony_ci    cfi_cross_dso = true
38686862fbSopenharmony_ci    debug = false
39686862fbSopenharmony_ci  }
40686862fbSopenharmony_ci
41686862fbSopenharmony_ci  install_enable = true
42686862fbSopenharmony_ci  sources = [
43686862fbSopenharmony_ci    "src/continuation_manager/app_connection_stub.cpp",
44686862fbSopenharmony_ci    "src/continuation_manager/app_device_callback_stub.cpp",
45686862fbSopenharmony_ci    "src/continuation_manager/connect_status_info.cpp",
46686862fbSopenharmony_ci    "src/continuation_manager/continuation_extra_params.cpp",
47686862fbSopenharmony_ci    "src/continuation_manager/continuation_result.cpp",
48686862fbSopenharmony_ci    "src/continuation_manager/device_selection_notifier_proxy.cpp",
49686862fbSopenharmony_ci    "src/continuation_manager/device_selection_notifier_stub.cpp",
50686862fbSopenharmony_ci    "src/continuation_manager/notifier_death_recipient.cpp",
51686862fbSopenharmony_ci    "src/continuation_manager/notifier_info.cpp",
52686862fbSopenharmony_ci    "src/distributed_ability_manager_dumper.cpp",
53686862fbSopenharmony_ci    "src/distributed_ability_manager_service.cpp",
54686862fbSopenharmony_ci    "src/distributed_ability_manager_stub.cpp",
55686862fbSopenharmony_ci  ]
56686862fbSopenharmony_ci
57686862fbSopenharmony_ci  configs = [
58686862fbSopenharmony_ci    ":distributed_ability_manager_config",
59686862fbSopenharmony_ci    "//foundation/ability/dmsfwk/services/dtbschedmgr/test/resource:coverage_flags",
60686862fbSopenharmony_ci  ]
61686862fbSopenharmony_ci
62686862fbSopenharmony_ci  ldflags = [ "-rdynamic" ]
63686862fbSopenharmony_ci
64686862fbSopenharmony_ci  deps = [
65686862fbSopenharmony_ci    "../../interfaces/innerkits/common:common_sdk",
66686862fbSopenharmony_ci    "../../interfaces/innerkits/continuation_manager:continuation_manager",
67686862fbSopenharmony_ci  ]
68686862fbSopenharmony_ci
69686862fbSopenharmony_ci  external_deps = [
70686862fbSopenharmony_ci    "ability_base:want",
71686862fbSopenharmony_ci    "ability_runtime:ability_manager",
72686862fbSopenharmony_ci    "access_token:libaccesstoken_sdk",
73686862fbSopenharmony_ci    "bundle_framework:appexecfwk_base",
74686862fbSopenharmony_ci    "bundle_framework:appexecfwk_core",
75686862fbSopenharmony_ci    "c_utils:utils",
76686862fbSopenharmony_ci    "eventhandler:libeventhandler",
77686862fbSopenharmony_ci    "ffrt:libffrt",
78686862fbSopenharmony_ci    "hilog:libhilog",
79686862fbSopenharmony_ci    "init:libbegetutil",
80686862fbSopenharmony_ci    "ipc:ipc_core",
81686862fbSopenharmony_ci    "safwk:system_ability_fwk",
82686862fbSopenharmony_ci    "samgr:samgr_proxy",
83686862fbSopenharmony_ci  ]
84686862fbSopenharmony_ci  if (os_account_part) {
85686862fbSopenharmony_ci    external_deps += [ "os_account:os_account_innerkits" ]
86686862fbSopenharmony_ci  }
87686862fbSopenharmony_ci
88686862fbSopenharmony_ci  part_name = "dmsfwk"
89686862fbSopenharmony_ci  subsystem_name = "ability"
90686862fbSopenharmony_ci}
91