1# Copyright (c) 2022-2023 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 14import("//build/config/features.gni") 15import("//build/test.gni") 16import("./../../../multimedia_camera_framework.gni") 17 18ohos_fuzztest("PhotoOutputFuzzTest") { 19 module_out_path = "camera_framework/camera_framework" 20 fuzz_config_file = "../photooutput_fuzzer" 21 22 include_dirs = [ 23 "${driver_disply_path}/interfaces/include", 24 "${graphic_surface_path}/surface/include", 25 "${multimedia_camera_framework_path}/services/camera_service/include", 26 "${multimedia_camera_framework_path}/services/camera_service/binder/base/include", 27 "${multimedia_camera_framework_path}/services/camera_service/binder/client/include", 28 "${multimedia_camera_framework_path}/services/camera_service/binder/server/include", 29 "${multimedia_camera_framework_path}/interfaces/inner_api/native/camera/include", 30 "${multimedia_camera_framework_path}/interfaces/inner_api/native/camera/include/output/", 31 "${window_manager_path}/interfaces/innerkits/dm", 32 "${base_security_path}/interfaces/innerkits/accesstoken/include", 33 "${driver_peripheral_path}/interfaces/include", 34 "${driver_peripheral_path}/interfaces/hdi_ipc", 35 "${driver_peripheral_path}/interfaces/hdi_ipc/utils/include", 36 "${driver_peripheral_path}/interfaces/hdi_ipc/callback/device/include", 37 "${driver_peripheral_path}/interfaces/hdi_ipc/callback/operator/include", 38 "${driver_peripheral_path}/interfaces/hdi_ipc/callback/host/include", 39 "${base_security_path}/interfaces/innerkits/token_setproc/include", 40 "${system_safwk_path}/native/include", 41 "${driver_disply_path}/interfaces/include", 42 ] 43 44 cflags = [ 45 "-g", 46 "-O0", 47 "-Wno-unused-variable", 48 "-fno-omit-frame-pointer", 49 ] 50 51 sources = [ "photo_output_fuzzer.cpp" ] 52 53 deps = [ "../../../frameworks/native/camera:camera_framework" ] 54 external_deps = [ 55 "ability_base:want", 56 "access_token:libaccesstoken_sdk", 57 "access_token:libnativetoken", 58 "access_token:libprivacy_sdk", 59 "access_token:libtoken_setproc", 60 "bundle_framework:appexecfwk_base", 61 "bundle_framework:appexecfwk_core", 62 "c_utils:utils", 63 "drivers_interface_camera:libbuffer_handle_sequenceable_1.0", 64 "drivers_interface_camera:libcamera_proxy_1.0", 65 "drivers_interface_camera:libcamera_proxy_1.1", 66 "drivers_interface_camera:libmap_data_sequenceable_1.0", 67 "drivers_interface_camera:metadata", 68 "drivers_peripheral_display:hdi_gralloc_client", 69 "graphic_2d:librender_service_client", 70 "graphic_surface:surface", 71 "hdf_core:libhdi", 72 "hicollie:libhicollie", 73 "hilog:libhilog", 74 "hisysevent:libhisysevent", 75 "hitrace:hitrace_meter", 76 "ipc:ipc_core", 77 "ipc:ipc_single", 78 "safwk:system_ability_fwk", 79 "samgr:samgr_proxy", 80 "window_manager:libdm", 81 ] 82} 83 84group("fuzztest") { 85 testonly = true 86 deps = [ ":PhotoOutputFuzzTest" ] 87} 88