meson: add sparse support
Do not use cgcc; instead, extract compilation commands from compile_commands.json and invoke sparse directly. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
@@ -25,6 +25,13 @@ if host_machine.system() == 'darwin'
|
||||
add_languages('objc', required: false, native: false)
|
||||
endif
|
||||
|
||||
if 'SPARSE_CFLAGS' in config_host
|
||||
run_target('sparse',
|
||||
command: [find_program('scripts/check_sparse.py'),
|
||||
config_host['SPARSE_CFLAGS'].split(),
|
||||
'compile_commands.json'])
|
||||
endif
|
||||
|
||||
configure_file(input: files('scripts/ninjatool.py'),
|
||||
output: 'ninjatool',
|
||||
configuration: config_host)
|
||||
|
||||
Reference in New Issue
Block a user