fuzzer_exes = []
-if get_option('tests') != 'false'
+if fuzz_tests or fuzzer_build
foreach tuple : fuzzers
sources = tuple[0]
link_with = tuple[1].length() > 0 ? tuple[1] : [libshared]
if name != prev
if want_tests == 'false'
message('Not compiling @0@ because tests is set to false'.format(name))
- elif slow_tests or fuzz_tests
+ elif fuzz_tests
exe = custom_target(
name,
output : name,
'@OUTPUT@'],
build_by_default : true)
else
- message('Not compiling @0@ because slow-tests/fuzz-tests is set to false'.format(name))
+ message('Not compiling @0@ because fuzz-tests is set to false'.format(name))
endif
endif
prev = name
- if want_tests != 'false' and (slow_tests or fuzz_tests)
+ if fuzz_tests
test('@0@:@1@:@2@'.format(b, c, sanitizer),
env,
env : ['UBSAN_OPTIONS=print_stacktrace=1:print_summary=1:halt_on_error=1'],
project_source_root,
'@OUTPUT@',
'fuzzers',
- '-Db_lundef=false -Db_sanitize=address,undefined @0@'.format(optimization),
+ '-Dfuzz-tests=true -Db_lundef=false -Db_sanitize=address,undefined @0@'.format(optimization),
' '.join(cc.cmd_array()),
cxx_cmd])