54c9e41d47
On oss-fuzz, we must use the LIB_FUZZING_ENGINE and CFLAGS environment variables, rather than -fsanitize=fuzzer. With this change, when LIB_FUZZING_ENGINE is set, the --enable-fuzzing configure option will use that environment variable during the linking stage, rather than -fsanitize=fuzzer Signed-off-by: Alexander Bulekov <alxndr@bu.edu> Message-Id: <20200902173652.307222-3-alxndr@bu.edu> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
33 lines
1.2 KiB
Meson
33 lines
1.2 KiB
Meson
specific_fuzz_ss.add(files('fuzz.c', 'fork_fuzz.c', 'qos_fuzz.c',
|
|
'qtest_wrappers.c'), qos)
|
|
|
|
# Targets
|
|
specific_fuzz_ss.add(when: 'CONFIG_I440FX', if_true: files('i440fx_fuzz.c'))
|
|
specific_fuzz_ss.add(when: 'CONFIG_VIRTIO_NET', if_true: files('virtio_net_fuzz.c'))
|
|
specific_fuzz_ss.add(when: 'CONFIG_VIRTIO_SCSI', if_true: files('virtio_scsi_fuzz.c'))
|
|
|
|
fork_fuzz = declare_dependency(
|
|
link_args: config_host['FUZZ_EXE_LDFLAGS'].split() +
|
|
['-Wl,-wrap,qtest_inb',
|
|
'-Wl,-wrap,qtest_inw',
|
|
'-Wl,-wrap,qtest_inl',
|
|
'-Wl,-wrap,qtest_outb',
|
|
'-Wl,-wrap,qtest_outw',
|
|
'-Wl,-wrap,qtest_outl',
|
|
'-Wl,-wrap,qtest_readb',
|
|
'-Wl,-wrap,qtest_readw',
|
|
'-Wl,-wrap,qtest_readl',
|
|
'-Wl,-wrap,qtest_readq',
|
|
'-Wl,-wrap,qtest_writeb',
|
|
'-Wl,-wrap,qtest_writew',
|
|
'-Wl,-wrap,qtest_writel',
|
|
'-Wl,-wrap,qtest_writeq',
|
|
'-Wl,-wrap,qtest_memread',
|
|
'-Wl,-wrap,qtest_bufread',
|
|
'-Wl,-wrap,qtest_memwrite',
|
|
'-Wl,-wrap,qtest_bufwrite',
|
|
'-Wl,-wrap,qtest_memset']
|
|
)
|
|
|
|
specific_fuzz_ss.add(fork_fuzz)
|