1 py3 = import('python').find_installation()
3 qht_bench = executable('qht-bench',
4 sources: 'qht-bench.c',
5 dependencies: [qemuutil])
7 executable('atomic_add-bench',
8 sources: files('atomic_add-bench.c'),
9 dependencies: [qemuutil],
10 build_by_default: false)
12 executable('atomic64-bench',
13 sources: files('atomic64-bench.c'),
14 dependencies: [qemuutil],
15 build_by_default: false)
18 'qapi-builtin-types.c',
19 'qapi-builtin-types.h',
20 'qapi-builtin-visit.c',
21 'qapi-builtin-visit.h',
22 'test-qapi-commands-sub-sub-module.c',
23 'test-qapi-commands-sub-sub-module.h',
24 'test-qapi-commands.c',
25 'test-qapi-commands.h',
26 'test-qapi-emit-events.c',
27 'test-qapi-emit-events.h',
28 'test-qapi-events-sub-sub-module.c',
29 'test-qapi-events-sub-sub-module.h',
32 'test-qapi-init-commands.c',
33 'test-qapi-init-commands.h',
34 'test-qapi-introspect.c',
35 'test-qapi-introspect.h',
36 'test-qapi-types-sub-sub-module.c',
37 'test-qapi-types-sub-sub-module.h',
40 'test-qapi-visit-sub-sub-module.c',
41 'test-qapi-visit-sub-sub-module.h',
46 test_qapi_files = custom_target('Test QAPI files',
47 output: test_qapi_outputs,
48 input: files('qapi-schema/qapi-schema-test.json',
49 'qapi-schema/include/sub-module.json',
50 'qapi-schema/sub-sub-module.json'),
51 command: [ qapi_gen, '-o', meson.current_build_dir(),
52 '-b', '-p', 'test-', '@INPUT0@' ],
53 depend_files: qapi_gen_depends)
55 # meson doesn't like generated output in other directories
56 # perhaps change qapi_gen to replace / with _, like Meson itself does?
59 test_qapi_sources = []
60 test_qapi_headers = []
62 foreach o: test_qapi_files.to_list() + test_qapi_files_extra.to_list()
63 if o.full_path().endswith('.h')
64 test_qapi_headers += o
66 test_qapi_sources += o
69 libtestqapi = static_library('testqapi', sources: [genh, test_qapi_sources])
70 testqapi = declare_dependency(link_with: libtestqapi, sources: [genh, test_qapi_headers])
73 'test-qht-par': qht_bench,
80 'benchmark-crypto-hash': [crypto],
81 'benchmark-crypto-hmac': [crypto],
82 'benchmark-crypto-cipher': [crypto],
86 foreach bench_name, deps: benchs
87 exe = executable(bench_name, bench_name + '.c',
88 dependencies: [qemuutil] + deps)
89 benchmark(bench_name, exe,
90 args: ['--tap', '-k'],
96 if have_tools and 'CONFIG_VHOST_USER' in config_host and 'CONFIG_LINUX' in config_host
97 executable('vhost-user-bridge',
98 sources: files('vhost-user-bridge.c'),
99 dependencies: [qemuutil, vhost_user])
102 if have_system and 'CONFIG_POSIX' in config_host
103 subdir('qemu-iotests')
106 test('decodetree', sh,
107 args: [ files('decode/check.sh'), config_host['PYTHON'], files('../scripts/decodetree.py') ],
108 workdir: meson.current_source_dir() / 'decode',
111 if 'CONFIG_TCG' in config_all
115 if not get_option('tcg').disabled()
116 if 'CONFIG_PLUGIN' in config_host
122 subdir('qapi-schema')