summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorIgor V. Kovalenko <igor.v.kovalenko@gmail.com>2020-12-22 20:54:40 +0300
committerPulseAudio Marge Bot <pulseaudio-maintainers@lists.freedesktop.org>2021-01-04 15:59:22 +0000
commitb6396dbe9c97be844553dd748e7cf9c3efdc0086 (patch)
treea02004ada71ae16c3faff3a4bb18ced84421b3d3 /meson.build
parent28f646fd87e824ba5e89377cd9aedde74e6be96c (diff)
x11: gracefully handle X11 connection error
Perform X11 connection recovery via XSetIOErrorExitHandler mechanism. Implementation is largely inspired by this change to GNOME/mutter https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1447 Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/441>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build4
1 files changed, 4 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index cd617c602..23e04ef46 100644
--- a/meson.build
+++ b/meson.build
@@ -650,6 +650,9 @@ if x11_dep.found()
sm_dep = dependency('sm', required : true)
xtst_dep = dependency('xtst', required : true)
cdata.set('HAVE_X11', 1)
+ if cc.has_function('XSetIOErrorExitHandler', dependencies: x11_dep)
+ cdata.set('HAVE_XSETIOERROREXITHANDLER', 1)
+ endif
endif
# Module dependencies
@@ -847,6 +850,7 @@ summary = [
'',
'Enable memfd shared memory: @0@'.format(cdata.has('HAVE_MEMFD')),
'Enable X11: @0@'.format(x11_dep.found()),
+ ' Safe X11 I/O errors: @0@'.format(cdata.has('HAVE_XSETIOERROREXITHANDLER')),
'Enable OSS Output: @0@'.format(cdata.has('HAVE_OSS_OUTPUT')),
'Enable OSS Wrapper: @0@'.format(cdata.has('HAVE_OSS_WRAPPER')),
# 'Enable EsounD: @0@'.format(${ENABLE_ESOUND}),