1# Copyright (c) 2023-2024 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################### 15SUBSYSTEM_DIR = "../../../.." 16import("//build/config/features.gni") 17import("//build/ohos.gni") 18import("//build/test.gni") 19 20##############################fuzztest########################################## 21ohos_fuzztest("VcardFuzzTest") { 22 module_output_path = "core_service/core_service" 23 module_out_path = module_output_path 24 fuzz_config_file = "$SUBSYSTEM_DIR/core_service/test/fuzztest/vcard_fuzzer" 25 26 include_dirs = [ "$SUBSYSTEM_DIR/core_service/test/fuzztest/common_fuzzer" ] 27 28 configs = [ "$SUBSYSTEM_DIR/core_service/utils:telephony_log_config" ] 29 30 deps = [ 31 "$SUBSYSTEM_DIR/core_service/interfaces/innerkits:tel_core_service_api", 32 ] 33 34 external_deps = [ 35 "access_token:libaccesstoken_sdk", 36 "access_token:libnativetoken", 37 "access_token:libtoken_setproc", 38 "core_service:libtel_vcard", 39 "data_share:datashare_common", 40 "data_share:datashare_consumer", 41 "hilog:libhilog", 42 ] 43 defines = [ 44 "TELEPHONY_LOG_TAG = \"CoreServiceFuzzTest\"", 45 "LOG_DOMAIN = 0xD001F00", 46 ] 47 48 cflags = [ 49 "-g", 50 "-O0", 51 "-Wno-unused-variable", 52 "-fno-omit-frame-pointer", 53 ] 54 sources = [ "vcard_fuzzer.cpp" ] 55} 56 57############################################################################### 58group("fuzztest") { 59 testonly = true 60 deps = [] 61 deps += [ 62 # deps file 63 ":VcardFuzzTest", 64 ] 65} 66############################################################################### 67