diff --git a/x11-toolkits/qt5-gui/Makefile b/x11-toolkits/qt5-gui/Makefile index aaf2e527362e..7d00383bf930 100644 --- a/x11-toolkits/qt5-gui/Makefile +++ b/x11-toolkits/qt5-gui/Makefile @@ -2,7 +2,7 @@ PORTNAME= gui DISTVERSION= ${QT5_VERSION} -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= x11-toolkits graphics PKGNAMEPREFIX= qt5- diff --git a/x11-toolkits/qt5-gui/files/patch-src_platformsupport_glxconvenience_qglxconvenience.cpp b/x11-toolkits/qt5-gui/files/patch-src_platformsupport_glxconvenience_qglxconvenience.cpp new file mode 100644 index 000000000000..5016237f08fc --- /dev/null +++ b/x11-toolkits/qt5-gui/files/patch-src_platformsupport_glxconvenience_qglxconvenience.cpp @@ -0,0 +1,17 @@ +Avoid selecting BGR visuals. On Intel i915 systems, selecting one of +these results in red-blue swapping later in the graphics pipeline. +PR 223638 has an extensive discussion. + +--- src/platformsupport/glxconvenience/qglxconvenience.cpp.orig 2018-01-16 06:53:43 UTC ++++ src/platformsupport/glxconvenience/qglxconvenience.cpp +@@ -220,6 +220,10 @@ GLXFBConfig qglx_findConfig(Display *dis + if (requestedAlpha && actualAlpha != requestedAlpha) + continue; + ++ // avoid BGR visuals due to bugs elsewhere ++ if ((visual->red_mask & 0x1) == 0x1) ++ continue; ++ + return candidate; + } + } while (qglx_reduceFormat(&format));