qemu-patch-raspberry4/audio/meson.build
Paolo Bonzini 87430d5b13 configure, meson: move audio driver detection to Meson
This brings a change that makes audio drivers more similar to all
other modules.  All drivers are built by default, while
--audio-drv-list only governs the default choice of the audio driver.

Meson options are added to disable the drivers, and the next patches
will fix the help messages and command line options, and especially
make the non-default drivers available via -audiodev.

Cc: Gerd Hoffman <kraxel@redhat.com>
Cc: Volker Rümelin <vr_qemu@t-online.de>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20211007130630.632028-4-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-10-14 09:50:56 +02:00

30 lines
748 B
Meson

softmmu_ss.add([spice_headers, files('audio.c')])
softmmu_ss.add(files(
'audio_legacy.c',
'mixeng.c',
'noaudio.c',
'wavaudio.c',
'wavcapture.c',
))
softmmu_ss.add(when: coreaudio, if_true: files('coreaudio.c'))
softmmu_ss.add(when: dsound, if_true: files('dsoundaudio.c', 'audio_win_int.c'))
audio_modules = {}
foreach m : [
['alsa', alsa, files('alsaaudio.c')],
['oss', oss, files('ossaudio.c')],
['pa', pulse, files('paaudio.c')],
['sdl', sdl, files('sdlaudio.c')],
['jack', jack, files('jackaudio.c')],
['spice', spice, files('spiceaudio.c')]
]
if m[1].found()
module_ss = ss.source_set()
module_ss.add(m[1], m[2])
audio_modules += {m[0] : module_ss}
endif
endforeach
modules += {'audio': audio_modules}