mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-07 00:08:39 +09:00
Move FUZZING definition from toolkit to js.
This commit is contained in:
parent
2a9f2dadee
commit
9a1685a422
2 changed files with 24 additions and 24 deletions
|
|
@ -236,3 +236,27 @@ def ctypes_and_compile_environment(ctypes, compile_environment, _):
|
|||
return ctypes and compile_environment
|
||||
|
||||
include('ffi.configure', when=ctypes_and_compile_environment)
|
||||
|
||||
# Support various fuzzing options
|
||||
# ==============================================================
|
||||
with only_when('--enable-compile-environment'):
|
||||
option('--enable-fuzzing', help='Enable fuzzing support')
|
||||
|
||||
@depends('--enable-fuzzing')
|
||||
def enable_fuzzing(value):
|
||||
if value:
|
||||
return True
|
||||
|
||||
@depends(enable_fuzzing,
|
||||
try_compile(body='__AFL_COMPILER;',
|
||||
check_msg='for AFL compiler',
|
||||
when='--enable-fuzzing'))
|
||||
def enable_libfuzzer(fuzzing, afl):
|
||||
if fuzzing and not afl:
|
||||
return True
|
||||
|
||||
set_config('FUZZING', enable_fuzzing)
|
||||
set_define('FUZZING', enable_fuzzing)
|
||||
|
||||
set_config('LIBFUZZER', enable_libfuzzer)
|
||||
set_define('LIBFUZZER', enable_libfuzzer)
|
||||
|
|
|
|||
|
|
@ -825,27 +825,3 @@ def skia_includes(skia, skia_gpu):
|
|||
return includes
|
||||
|
||||
set_config('SKIA_INCLUDES', skia_includes)
|
||||
|
||||
# Support various fuzzing options
|
||||
# ==============================================================
|
||||
with only_when('--enable-compile-environment'):
|
||||
option('--enable-fuzzing', help='Enable fuzzing support')
|
||||
|
||||
@depends('--enable-fuzzing')
|
||||
def enable_fuzzing(value):
|
||||
if value:
|
||||
return True
|
||||
|
||||
@depends(enable_fuzzing,
|
||||
try_compile(body='__AFL_COMPILER;',
|
||||
check_msg='for AFL compiler',
|
||||
when='--enable-fuzzing'))
|
||||
def enable_libfuzzer(fuzzing, afl):
|
||||
if fuzzing and not afl:
|
||||
return True
|
||||
|
||||
set_config('FUZZING', enable_fuzzing)
|
||||
set_define('FUZZING', enable_fuzzing)
|
||||
|
||||
set_config('LIBFUZZER', enable_libfuzzer)
|
||||
set_define('LIBFUZZER', enable_libfuzzer)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue