From 58fa92e40bd3dd144101ed607b0030ed666b7083 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Fri, 23 Dec 2016 16:18:15 +0100 Subject: [PATCH] Pass EGL_PLATFORM=DRM to XWayland XWayland needs to create an eglDisplay for platform DRM. Depending on the mesa version eglInitialize expects that the passed native display is a Wayland display and crashes. This prevents KWin to startup. This patch sets EGL_PLATFORM for Xwayland. This is actually not KWin's job, but if it otherwise crashes it's better than nothing. As Xwayland only supports DRM, it's fine to use this. --- main_wayland.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/main_wayland.cpp b/main_wayland.cpp index ebc2c14a64..27ae358864 100644 --- a/main_wayland.cpp +++ b/main_wayland.cpp @@ -324,6 +324,7 @@ void ApplicationWayland::startXwaylandServer() m_xwaylandProcess->setProgram(QStringLiteral("Xwayland")); QProcessEnvironment env = m_environment; env.insert("WAYLAND_SOCKET", QByteArray::number(wlfd)); + env.insert("EGL_PLATFORM", QByteArrayLiteral("DRM")); m_xwaylandProcess->setProcessEnvironment(env); m_xwaylandProcess->setArguments({QStringLiteral("-displayfd"), QString::number(pipeFds[1]),