[pulseaudio-commits] [Git][pulseaudio/pulseaudio][master] build-sys: meson: Require bluez dependency if bluez5 feature is enabled
PulseAudio Marge Bot (@pulseaudio-merge-bot)
gitlab at gitlab.freedesktop.org
Mon Jun 21 10:53:08 UTC 2021
PulseAudio Marge Bot pushed to branch master at PulseAudio / pulseaudio
Commits:
c817dfb5 by Igor V. Kovalenko at 2021-06-21T10:50:08+00:00
build-sys: meson: Require bluez dependency if bluez5 feature is enabled
Build breaks if bluez5 and bluez5-native-headset are both enabled
but bluez headers are not available.
Fix this by changing `bluez5` to Meson feature requiring `bluez` dependency.
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/583>
- - - - -
4 changed files:
- meson.build
- meson_options.txt
- src/modules/bluetooth/meson.build
- src/modules/meson.build
Changes:
=====================================
meson.build
=====================================
@@ -706,7 +706,9 @@ endif
sbc_dep = dependency('sbc', version : '>= 1.0', required : false)
-if get_option('bluez5')
+bluez_dep = dependency('bluez', required : get_option('bluez5'))
+
+if bluez_dep.found()
assert(dbus_dep.found(), 'BlueZ requires D-Bus support')
assert(sbc_dep.found(), 'BlueZ requires SBC support')
cdata.set('HAVE_SBC', 1)
@@ -914,9 +916,9 @@ summary = [
'Enable Async DNS: @0@'.format(asyncns_dep.found()),
'Enable LIRC: @0@'.format(lirc_dep.found()),
'Enable D-Bus: @0@'.format(dbus_dep.found()),
- ' Enable BlueZ 5: @0@'.format(get_option('bluez5')),
- ' Enable native headsets: @0@'.format(get_option('bluez5-native-headset')),
- ' Enable ofono headsets: @0@'.format(get_option('bluez5-ofono-headset')),
+ ' Enable BlueZ 5: @0@'.format(cdata.has('HAVE_BLUEZ_5')),
+ ' Enable native headsets: @0@'.format(cdata.has('HAVE_BLUEZ_5_NATIVE_HEADSET')),
+ ' Enable ofono headsets: @0@'.format(cdata.has('HAVE_BLUEZ_5_OFONO_HEADSET')),
' Enable GStreamer based codecs: @0@'.format(have_bluez5_gstreamer),
'Enable udev: @0@'.format(udev_dep.found()),
' Enable HAL->udev compat: @0@'.format(get_option('hal-compat')),
=====================================
meson_options.txt
=====================================
@@ -85,7 +85,7 @@ option('avahi',
type : 'feature', value : 'auto',
description : 'Optional Avahi support')
option('bluez5',
- type : 'boolean', value : 'true',
+ type : 'feature', value : 'auto',
description : 'Optional BlueZ 5 support')
option('bluez5-gstreamer',
type : 'feature', value: 'auto',
=====================================
src/modules/bluetooth/meson.build
=====================================
@@ -35,7 +35,7 @@ libbluez5_util = shared_library('bluez5-util',
c_args : [pa_c_args, server_c_args],
link_args : [nodelete_link_args],
include_directories : [configinc, topinc],
- dependencies : [libpulse_dep, libpulsecommon_dep, libpulsecore_dep, dbus_dep, sbc_dep, libintl_dep, bluez5_gst_dep, bluez5_gstapp_dep],
+ dependencies : [libpulse_dep, libpulsecommon_dep, libpulsecore_dep, bluez_dep, dbus_dep, sbc_dep, libintl_dep, bluez5_gst_dep, bluez5_gstapp_dep],
install : true,
install_rpath : privlibdir,
install_dir : modlibexecdir,
=====================================
src/modules/meson.build
=====================================
@@ -118,7 +118,7 @@ if avahi_dep.found()
]
endif
-if get_option('bluez5')
+if cdata.has('HAVE_BLUEZ_5')
subdir('bluetooth')
all_modules += [
[ 'module-bluetooth-discover', 'bluetooth/module-bluetooth-discover.c' ],
View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/c817dfb5a438055c98449a4a2f34eb4ec341ccde
--
View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/commit/c817dfb5a438055c98449a4a2f34eb4ec341ccde
You're receiving this email because of your account on gitlab.freedesktop.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/pulseaudio-commits/attachments/20210621/946b0d87/attachment-0001.htm>
More information about the pulseaudio-commits
mailing list