diff -urN mir-1.8.2+dfsg/debian/patches/1004_xlib-workaround.patch mir-1.8.2+dfsg-thomaslee/debian/patches/1004_xlib-workaround.patch
--- mir-1.8.2+dfsg/debian/patches/1004_xlib-workaround.patch	1969-12-31 16:00:00.000000000 -0800
+++ mir-1.8.2+dfsg-thomaslee/debian/patches/1004_xlib-workaround.patch	2022-02-24 20:28:22.555990220 -0800
@@ -0,0 +1,47 @@
+Description: work around Xlib/capnproto naming conflict in capnproto 0.9.1
+Origin: https://github.com/MirServer/mir/pull/2267
+
+--- a/src/platforms/mesa/server/x11/graphics/egl_helper.h
++++ b/src/platforms/mesa/server/x11/graphics/egl_helper.h
+@@ -19,6 +19,8 @@
+ #ifndef MIR_GRAPHICS_X11_EGL_HELPER_H_
+ #define MIR_GRAPHICS_X11_EGL_HELPER_H_
+ 
++#include <kj/one-of.h> // HACK for https://github.com/capnproto/capnproto/issues/1393
++
+ #include <memory>
+ #include <functional>
+ 
+--- a/src/platforms/mesa/server/x11/graphics/platform.h
++++ b/src/platforms/mesa/server/x11/graphics/platform.h
+@@ -19,6 +19,8 @@
+ #ifndef MIR_GRAPHICS_X_PLATFORM_H_
+ #define MIR_GRAPHICS_X_PLATFORM_H_
+ 
++#include <kj/one-of.h> // HACK for https://github.com/capnproto/capnproto/issues/1393
++
+ #include "mir/graphics/display_report.h"
+ #include "mir/graphics/platform.h"
+ #include "display_helpers.h"
+--- a/src/platforms/mesa/server/x11/input/input_platform.h
++++ b/src/platforms/mesa/server/x11/input/input_platform.h
+@@ -18,6 +18,8 @@
+ #ifndef MIR_INPUT_X_INPUT_PLATFORM_H_
+ #define MIR_INPUT_X_INPUT_PLATFORM_H_
+ 
++#include <kj/one-of.h> // HACK for https://github.com/capnproto/capnproto/issues/1393
++
+ #include "mir/input/platform.h"
+ #include <memory>
+ #include <X11/Xlib.h>
+--- a/tests/include/mir/test/doubles/mock_x11.h
++++ b/tests/include/mir/test/doubles/mock_x11.h
+@@ -19,6 +19,8 @@
+ #ifndef MIR_TEST_DOUBLES_MOCK_X11_H_
+ #define MIR_TEST_DOUBLES_MOCK_X11_H_
+ 
++#include <kj/one-of.h> // HACK for https://github.com/capnproto/capnproto/issues/1393
++
+ #include <gmock/gmock.h>
+ 
+ #include <X11/Xlib.h>
diff -urN mir-1.8.2+dfsg/debian/patches/series mir-1.8.2+dfsg-thomaslee/debian/patches/series
--- mir-1.8.2+dfsg/debian/patches/series	2022-01-25 14:47:38.000000000 -0800
+++ mir-1.8.2+dfsg-thomaslee/debian/patches/series	2022-02-24 19:52:28.216285976 -0800
@@ -5,3 +5,4 @@
 0008_Fix-more-missing-includes-for-GCC-11.patch
 0009_use-python3.patch
 1003-workaround-gcc-ICE-bug.patch
+1004_xlib-workaround.patch
