14514f5e3Sopenharmony_ci# Copyright (c) 2024 Huawei Device Co., Ltd.
24514f5e3Sopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License");
34514f5e3Sopenharmony_ci# you may not use this file except in compliance with the License.
44514f5e3Sopenharmony_ci# You may obtain a copy of the License at
54514f5e3Sopenharmony_ci#
64514f5e3Sopenharmony_ci#     http://www.apache.org/licenses/LICENSE-2.0
74514f5e3Sopenharmony_ci#
84514f5e3Sopenharmony_ci# Unless required by applicable law or agreed to in writing, software
94514f5e3Sopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS,
104514f5e3Sopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
114514f5e3Sopenharmony_ci# See the License for the specific language governing permissions and
124514f5e3Sopenharmony_ci# limitations under the License.
134514f5e3Sopenharmony_ci
144514f5e3Sopenharmony_ciimport(
154514f5e3Sopenharmony_ci    "//arkcompiler/ets_runtime/compiler_service/test/compiler_service_test.gni")
164514f5e3Sopenharmony_ci
174514f5e3Sopenharmony_ciohos_fuzztest("AotCompilerArgsPrepareFuzzTest") {
184514f5e3Sopenharmony_ci  module_out_path = module_output_path
194514f5e3Sopenharmony_ci  fuzz_config_file =
204514f5e3Sopenharmony_ci      "${compiler_service_root}/test/fuzztest/aotcompilerargsprepare_fuzzer"
214514f5e3Sopenharmony_ci  cflags = [
224514f5e3Sopenharmony_ci    "-g",
234514f5e3Sopenharmony_ci    "-O0",
244514f5e3Sopenharmony_ci    "-Wno-unused-variable",
254514f5e3Sopenharmony_ci    "-fno-omit-frame-pointer",
264514f5e3Sopenharmony_ci  ]
274514f5e3Sopenharmony_ci  include_dirs = compiler_service_include_dirs
284514f5e3Sopenharmony_ci  sources = aot_compiler_service_sources
294514f5e3Sopenharmony_ci  external_deps = [
304514f5e3Sopenharmony_ci    "access_token:libaccesstoken_sdk",
314514f5e3Sopenharmony_ci    "access_token:libtokenid_sdk",
324514f5e3Sopenharmony_ci    "c_utils:utils",
334514f5e3Sopenharmony_ci    "common_event_service:cesfwk_innerkits",
344514f5e3Sopenharmony_ci    "eventhandler:libeventhandler",
354514f5e3Sopenharmony_ci    "hilog:libhilog",
364514f5e3Sopenharmony_ci    "hisysevent:libhisysevent",
374514f5e3Sopenharmony_ci    "hitrace:hitrace_meter",
384514f5e3Sopenharmony_ci    "icu:shared_icui18n",
394514f5e3Sopenharmony_ci    "icu:shared_icuuc",
404514f5e3Sopenharmony_ci    "ipc:ipc_core",
414514f5e3Sopenharmony_ci    "runtime_core:libarkfile_static",
424514f5e3Sopenharmony_ci    "safwk:system_ability_fwk",
434514f5e3Sopenharmony_ci    "samgr:samgr_proxy",
444514f5e3Sopenharmony_ci  ]
454514f5e3Sopenharmony_ci  defines = []
464514f5e3Sopenharmony_ci  if (defined(global_parts_info) &&
474514f5e3Sopenharmony_ci      !defined(global_parts_info.security_code_signature)) {
484514f5e3Sopenharmony_ci    external_deps += [ "code_signature:liblocal_code_sign_sdk" ]
494514f5e3Sopenharmony_ci    defines += [ "CODE_SIGN_ENABLE" ]
504514f5e3Sopenharmony_ci  }
514514f5e3Sopenharmony_ci  sources += [ "aotcompilerargsprepare_fuzzer.cpp" ]
524514f5e3Sopenharmony_ci}
53