• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2025 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
14#####################hydra-fuzz###################
15import("//build/config/features.gni")
16import("//build/ohos.gni")
17import("//build/test.gni")
18import("//foundation/ability/ability_runtime/ability_runtime.gni")
19module_output_path = "ability_runtime/appmgr"
20
21##############################fuzztest##########################################
22ohos_fuzztest("AbilityResidentProcessRdbFuzzTest") {
23  module_out_path = module_output_path
24
25  fuzz_config_file =
26      "${ability_runtime_test_path}/fuzztest/abilityresidentprocessrdb_fuzzer"
27  include_dirs = [ "${ability_runtime_services_path}/abilitymgr/include" ]
28  cflags = [
29    "-g",
30    "-O0",
31    "-Wno-unused-variable",
32    "-fno-omit-frame-pointer",
33  ]
34  sources = [
35    "${ability_runtime_services_path}/abilitymgr/src/insight_intent/insight_intent_rdb_data_mgr.cpp",
36    "${ability_runtime_services_path}/abilitymgr/src/rdb/ability_resident_process_rdb.cpp",
37    "${ability_runtime_services_path}/abilitymgr/src/rdb/parser_util.cpp",
38    "${ability_runtime_services_path}/abilitymgr/src/rdb/rdb_data_manager.cpp",
39    "abilityresidentprocessrdb_fuzzer.cpp",
40  ]
41
42  configs = [ "${ability_runtime_innerkits_path}/ability_manager:ability_manager_public_config" ]
43
44  deps = [
45    "${ability_runtime_abilitymgr_path}/:abilityms",
46    "${ability_runtime_services_path}/common:app_util",
47  ]
48
49  external_deps = [
50    "ability_base:base",
51    "ability_base:configuration",
52    "ability_base:extractortool",
53    "ability_base:session_info",
54    "ability_base:view_data",
55    "ability_base:want",
56    "ability_base:zuri",
57    "access_token:libaccesstoken_sdk",
58    "access_token:libtokenid_sdk",
59    "bundle_framework:appexecfwk_base",
60    "bundle_framework:appexecfwk_core",
61    "bundle_framework:libappexecfwk_common",
62    "cJSON:cjson",
63    "c_utils:utils",
64    "common_event_service:cesfwk_core",
65    "common_event_service:cesfwk_innerkits",
66    "config_policy:configpolicy_util",
67    "dsoftbus:softbus_client",
68    "eventhandler:libeventhandler",
69    "faultloggerd:libbacktrace_local",
70    "ffrt:libffrt",
71    "hicollie:libhicollie",
72    "hilog:libhilog",
73    "hisysevent:libhisysevent",
74    "hitrace:hitrace_meter",
75    "icu:shared_icuuc",
76    "init:libbeget_proxy",
77    "init:libbegetutil",
78    "ipc:ipc_core",
79    "kv_store:distributeddata_inner",
80    "os_account:os_account_innerkits",
81    "qos_manager:concurrent_task_client",
82    "relational_store:native_appdatafwk",
83    "relational_store:native_dataability",
84    "relational_store:native_rdb",
85    "safwk:system_ability_fwk",
86    "samgr:samgr_proxy",
87    "window_manager:libmodal_system_ui_extension_client",
88    "window_manager:libwsutils",
89    "window_manager:scene_session",
90    "window_manager:session_manager_lite",
91    "window_manager:sms",
92  ]
93
94  if (ability_runtime_graphics) {
95    external_deps += [ "input:libmmi-client" ]
96  }
97}
98
99###############################################################################
100group("fuzztest") {
101  testonly = true
102  deps = []
103  deps += [
104    # deps file
105    ":AbilityResidentProcessRdbFuzzTest",
106  ]
107}
108###############################################################################
109