1686862fbSopenharmony_ci# Copyright (c) 2024 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_ci#####################hydra-fuzz################### 15686862fbSopenharmony_ciimport("//build/config/features.gni") 16686862fbSopenharmony_ciimport("//build/ohos.gni") 17686862fbSopenharmony_ciimport("//build/test.gni") 18686862fbSopenharmony_ciimport("//foundation/ability/dmsfwk/dmsfwk.gni") 19686862fbSopenharmony_ciohos_fuzztest("DSchedTransportSoftbusAdapterFuzzTest") { 20686862fbSopenharmony_ci module_out_path = module_output_path 21686862fbSopenharmony_ci 22686862fbSopenharmony_ci visibility = [ ":*" ] 23686862fbSopenharmony_ci include_dirs = [ 24686862fbSopenharmony_ci "${dms_path}/test/fuzztest/dschedtransportsoftbusadapter_fuzzer", 25686862fbSopenharmony_ci "${dms_path}/services/dtbschedmgr/include/", 26686862fbSopenharmony_ci "${dms_path}/interfaces/innerkits/common/include/", 27686862fbSopenharmony_ci "${dms_path}/services/dtbschedmgr/include/collaborate/", 28686862fbSopenharmony_ci "${dms_path}/common/include/", 29686862fbSopenharmony_ci "${dms_path}/services/dtbschedmgr/include/softbus_adapter/transport", 30686862fbSopenharmony_ci "${dms_path}/services/dtbschedmgr/include/continue", 31686862fbSopenharmony_ci "${dms_path}/services/dtbschedmgr/include/continue/state", 32686862fbSopenharmony_ci ] 33686862fbSopenharmony_ci 34686862fbSopenharmony_ci fuzz_config_file = 35686862fbSopenharmony_ci "${dms_path}/test/fuzztest/dschedtransportsoftbusadapter_fuzzer" 36686862fbSopenharmony_ci 37686862fbSopenharmony_ci configs = [ "${dms_path}/services/dtbschedmgr/test/resource:coverage_flags" ] 38686862fbSopenharmony_ci 39686862fbSopenharmony_ci cflags = [ 40686862fbSopenharmony_ci "-g", 41686862fbSopenharmony_ci "-O0", 42686862fbSopenharmony_ci "-Wno-unused-variable", 43686862fbSopenharmony_ci "-fno-omit-frame-pointer", 44686862fbSopenharmony_ci "-Dprivate=public", 45686862fbSopenharmony_ci ] 46686862fbSopenharmony_ci 47686862fbSopenharmony_ci sources = [ "dschedtransportsoftbusadapter_fuzzer.cpp" ] 48686862fbSopenharmony_ci 49686862fbSopenharmony_ci deps = [ "${dms_path}/services/dtbschedmgr:distributedschedsvr" ] 50686862fbSopenharmony_ci 51686862fbSopenharmony_ci defines = [] 52686862fbSopenharmony_ci if (dmsfwk_mission_manager) { 53686862fbSopenharmony_ci defines += [ "SUPPORT_DISTRIBUTED_MISSION_MANAGER" ] 54686862fbSopenharmony_ci } 55686862fbSopenharmony_ci 56686862fbSopenharmony_ci if (os_account_part) { 57686862fbSopenharmony_ci defines += [ "OS_ACCOUNT_PART" ] 58686862fbSopenharmony_ci } 59686862fbSopenharmony_ci external_deps = [ 60686862fbSopenharmony_ci "ability_base:base", 61686862fbSopenharmony_ci "ability_base:want", 62686862fbSopenharmony_ci "ability_base:zuri", 63686862fbSopenharmony_ci "ability_runtime:ability_manager", 64686862fbSopenharmony_ci "ability_runtime:app_manager", 65686862fbSopenharmony_ci "ability_runtime:dataobs_manager", 66686862fbSopenharmony_ci "ability_runtime:mission_info", 67686862fbSopenharmony_ci "access_token:libaccesstoken_sdk", 68686862fbSopenharmony_ci "access_token:libnativetoken_shared", 69686862fbSopenharmony_ci "access_token:libtokensetproc_shared", 70686862fbSopenharmony_ci "bundle_framework:appexecfwk_base", 71686862fbSopenharmony_ci "bundle_framework:appexecfwk_core", 72686862fbSopenharmony_ci "cJSON:cjson", 73686862fbSopenharmony_ci "c_utils:utils", 74686862fbSopenharmony_ci "data_share:datashare_consumer", 75686862fbSopenharmony_ci "device_auth:deviceauth_sdk", 76686862fbSopenharmony_ci "device_info_manager:distributed_device_profile_common", 77686862fbSopenharmony_ci "device_info_manager:distributed_device_profile_sdk", 78686862fbSopenharmony_ci "device_manager:devicemanagersdk", 79686862fbSopenharmony_ci "device_security_level:dslm_sdk", 80686862fbSopenharmony_ci "distributed_bundle_framework:dbms_fwk", 81686862fbSopenharmony_ci "dsoftbus:softbus_client", 82686862fbSopenharmony_ci "eventhandler:libeventhandler", 83686862fbSopenharmony_ci "hilog:libhilog", 84686862fbSopenharmony_ci "hisysevent:libhisysevent", 85686862fbSopenharmony_ci "hitrace:hitrace_meter", 86686862fbSopenharmony_ci "hitrace:libhitracechain", 87686862fbSopenharmony_ci "init:libbegetutil", 88686862fbSopenharmony_ci "ipc:ipc_core", 89686862fbSopenharmony_ci "kv_store:distributeddata_inner", 90686862fbSopenharmony_ci "os_account:libaccountkits", 91686862fbSopenharmony_ci "safwk:system_ability_fwk", 92686862fbSopenharmony_ci "samgr:samgr_proxy", 93686862fbSopenharmony_ci ] 94686862fbSopenharmony_ci if (os_account_part) { 95686862fbSopenharmony_ci external_deps += [ "os_account:os_account_innerkits" ] 96686862fbSopenharmony_ci } 97686862fbSopenharmony_ci} 98686862fbSopenharmony_ci 99686862fbSopenharmony_cigroup("fuzztest") { 100686862fbSopenharmony_ci testonly = true 101686862fbSopenharmony_ci deps = [ ":DSchedTransportSoftbusAdapterFuzzTest" ] 102686862fbSopenharmony_ci} 103