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("//base/web/webview/web_aafwk.gni") 16import("//build/config/features.gni") 17import("//build/test.gni") 18import("$webview_path/config.gni") 19 20##############################fuzztest########################################## 21ohos_fuzztest("ReleasePixelMapFuzzTest") { 22 module_out_path = webview_fuzz_test_path 23 fuzz_config_file = "$webview_path/test/fuzztest/ohos_adapter/ohosimagedecoderadapterimpl_fuzzer/releasepixelmap_fuzzer" 24 include_dirs = [ 25 "$webview_path/ohos_adapter/interfaces", 26 "$webview_path/ohos_adapter/ohos_image_adapter/include", 27 "$webview_path/test/fuzztest", 28 ] 29 cflags = [ 30 "-g", 31 "-O0", 32 "-Wno-unused-variable", 33 "-fno-omit-frame-pointer", 34 ] 35 36 include_dirs += [ 37 "../ohos_nweb/include", 38 "aafwk_adapter/include", 39 "access_token_adapter/include", 40 "audio_adapter/include", 41 "battery_mgr_adapter/include", 42 "camera_adapter/include", 43 "cert_mgr_adapter/include", 44 "datashare_adapter/include", 45 "date_time_format_adapter/include", 46 "display_manager_adapter/include", 47 "distributeddatamgr_adapter/webdatabase/include", 48 "enterprise_device_management_adapter/include", 49 "event_handler_adapter/include", 50 "flowbuffer_adapter/include", 51 "graphic_adapter/include", 52 "hiviewdfx_adapter/include", 53 "inputmethodframework_adapter/include", 54 "keystore_adapter/include", 55 "location_adapter/include", 56 "media_adapter/include", 57 "multimodalinput_adapter/include", 58 "net_connect_adapter/include", 59 "net_proxy_adapter/include", 60 "ohos_adapter_helper/include", 61 "ohos_image_adapter/include", 62 "ohos_init_web_adapter/include", 63 "ohos_resource_adapter/include", 64 "pasteboard_adapter/include", 65 "power_mgr_adapter/include", 66 "print_manager_adapter/include", 67 "screen_capture_adapter/include", 68 "soc_perf_adapter/include", 69 "system_properties_adapter/include", 70 ] 71 72 sources = [ "releasepixelmap_fuzzer.cpp" ] 73 deps = [ 74 "$webview_path/ohos_adapter:nweb_ohos_adapter", 75 "$webview_path/ohos_nweb:libnweb", 76 ] 77 78 external_deps = [ 79 "c_utils:utils", 80 "eventhandler:libeventhandler", 81 "image_framework:image", 82 "image_framework:image_native", 83 ] 84} 85 86############################################################################### 87group("fuzztest") { 88 testonly = true 89 deps = [] 90 deps += [ 91 # deps file 92 ":ReleasePixelMapFuzzTest", 93 ] 94} 95############################################################################### 96