meson: fix build if bluez5 option is disabled

Don't look up codecs dependencies and don't include 'bluez5' subdir if 'bluez5' option is disabled or libbluetooth is not found.
See https://gitlab.freedesktop.org/pipewire/pipewire/-/merge_requests/707.
This commit is contained in:
Huang-Huang Bao 2021-05-28 20:53:37 +08:00
parent 38bcec9022
commit e953bb3238
No known key found for this signature in database
GPG key ID: 33C3271387A13D1B
2 changed files with 10 additions and 6 deletions

View file

@ -13,7 +13,9 @@ endif
if not get_option('audiotestsrc').disabled()
subdir('audiotestsrc')
endif
subdir('bluez5')
if bluez_dep.found()
subdir('bluez5')
endif
if avcodec_dep.found()
subdir('ffmpeg')
endif