Merge pull request #117 from xclaesse/meson-fuzz

Meson: Fix fuzz test names
This commit is contained in:
Tim Rühsen 2018-12-08 16:57:24 +01:00 committed by GitHub
commit 22f3ecdb12
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 11 additions and 2 deletions

View File

@ -3,8 +3,17 @@ fuzzer_cargs = [
'-DTEST_RUN', '-DTEST_RUN',
] ]
foreach test_name : ['fuzzer', 'load_fuzzer', 'load_dafsa_fuzzer'] foreach test_case : ['fuzzer', 'load_fuzzer', 'load_dafsa_fuzzer']
source_file = 'libpsl_@0@.c'.format(test_name) if enable_runtime == 'libidn2'
test_name = 'libpsl_idn2_' + test_case
elif enable_runtime == 'libicu'
test_name = 'libpsl_icu_' + test_case
elif enable_runtime == 'libidn'
test_name = 'libpsl_idn_' + test_case
else
test_name = 'libpsl_' + test_case
endif
source_file = 'libpsl_@0@.c'.format(test_case)
exe = executable(test_name, source_file, 'main.c', exe = executable(test_name, source_file, 'main.c',
link_with : libpsl, link_with : libpsl,
c_args : fuzzer_cargs, c_args : fuzzer_cargs,