From patchwork Fri Jan 16 23:34:06 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?SsOpcsO0bWUgUG91aWxsZXI=?= X-Patchwork-Id: 430063 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id D3C8D1401EB for ; Sat, 17 Jan 2015 10:35:06 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 9CE34A1513; Fri, 16 Jan 2015 23:34:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PqxulHac-qFW; Fri, 16 Jan 2015 23:34:52 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id DAD0AA1527; Fri, 16 Jan 2015 23:34:48 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id DE7C61C29D1 for ; Fri, 16 Jan 2015 23:34:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id D62C99211E for ; Fri, 16 Jan 2015 23:34:27 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GvFqiJKgW8jH for ; Fri, 16 Jan 2015 23:34:23 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from lupi.sysmic.org (sysmic.org [62.210.89.17]) by whitealder.osuosl.org (Postfix) with ESMTPS id 7506392115 for ; Fri, 16 Jan 2015 23:34:22 +0000 (UTC) Received: from lupi.online.net (sysmic.org [62.210.89.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jezz) by lupi.sysmic.org (Postfix) with ESMTPSA id C16F741150; Sat, 17 Jan 2015 00:34:18 +0100 (CET) From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Pouiller?= To: buildroot@busybox.net Date: Sat, 17 Jan 2015 00:34:06 +0100 Message-Id: <1421451251-23366-11-git-send-email-jezz@sysmic.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1421451251-23366-1-git-send-email-jezz@sysmic.org> References: <1421451251-23366-1-git-send-email-jezz@sysmic.org> MIME-Version: 1.0 Cc: Thomas Petazzoni , =?UTF-8?q?J=C3=A9r=C3=B4me=20Pouiller?= Subject: [Buildroot] [PATCH v6 10/15] qt5base: fix "Unable to find an X11 visual" error X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Fix "Unable to find an X11 visual" bug that produce at runtime with Vivante drivers. Add a conditionnal patch and add variable QT5BASE_EXTRA_CFLAGS in order to enable workaround. Signed-off-by: Jérôme Pouiller Tested-by: Gary Bisson Reviewed-by: Gary Bisson --- .../qt5/qt5base/0001-Force_egl_visual_ID_33.patch | 26 ++++++++++++++++++++++ package/qt5/qt5base/qt5base.mk | 6 +++-- 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 package/qt5/qt5base/0001-Force_egl_visual_ID_33.patch diff --git a/package/qt5/qt5base/0001-Force_egl_visual_ID_33.patch b/package/qt5/qt5base/0001-Force_egl_visual_ID_33.patch new file mode 100644 index 0000000..e7e6c5e --- /dev/null +++ b/package/qt5/qt5base/0001-Force_egl_visual_ID_33.patch @@ -0,0 +1,26 @@ +Workaround EGL initialization failure due visual mismatch + +Error: + +Warning: EGL suggested using X Visual ID 33 (RGB888) for EGL config 28 (RGB444), but this is incompatable +Unable to find an X11 visual which matches EGL config 28 +Could not initialize EGL +Aborted + +Upstream-Status: Inappropriate [workaround] + +Signed-off-by: Otavio Salvador + +diff -Naur qtbase-opensource-src-5.1.1_original/src/platformsupport/eglconvenience/qxlibeglintegration.cpp qtbase-opensource-src-5.1.1/src/platformsupport/eglconvenience/qxlibeglintegration.cpp +--- qtbase-opensource-src-5.1.1_original/src/platformsupport/eglconvenience/qxlibeglintegration.cpp 2013-12-25 19:08:42.163895341 -0800 ++++ qtbase-opensource-src-5.1.1/src/platformsupport/eglconvenience/qxlibeglintegration.cpp 2013-12-25 19:09:37.207893799 -0800 +@@ -180,5 +180,9 @@ + } + + qWarning("Unable to find an X11 visual which matches EGL config %d", configId); ++#ifdef ENABLE_MX6_WORKAROUND ++ return (VisualID)33; ++#else + return (VisualID)0; ++#endif + } diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk index a36359d..4796785 100644 --- a/package/qt5/qt5base/qt5base.mk +++ b/package/qt5/qt5base/qt5base.mk @@ -172,6 +172,8 @@ QT5BASE_INSTALL_LIBS_$(BR2_PACKAGE_QT5BASE_PRINTSUPPORT) += Qt5PrintSupport QT5BASE_INSTALL_LIBS_$(BR2_PACKAGE_QT5BASE_DBUS) += Qt5DBus +QT5BASE_EXTRA_CFLAGS = $(if $(BR2_PACKAGE_GPU_VIV_BIN_MX6Q),-DENABLE_MX6_WORKAROUND) + define QT5BASE_CONFIGURE_CMDS (cd $(@D); \ PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \ @@ -192,8 +194,8 @@ define QT5BASE_CONFIGURE_CMDS -device buildroot \ -device-option CROSS_COMPILE="$(TARGET_CROSS)" \ -device-option BR_CCACHE="$(CCACHE)" \ - -device-option BR_COMPILER_CFLAGS="$(TARGET_CFLAGS)" \ - -device-option BR_COMPILER_CXXFLAGS="$(TARGET_CXXFLAGS)" \ + -device-option BR_COMPILER_CFLAGS="$(TARGET_CFLAGS)$(QT5BASE_EXTRA_CFLAGS)" \ + -device-option BR_COMPILER_CXXFLAGS="$(TARGET_CXXFLAGS)$(QT5BASE_EXTRA_CFLAGS)" \ -device-option EGLFS_PLATFORM_HOOKS_SOURCES="$(QT5BASE_EGLFS_PLATFORM_HOOKS_SOURCES)" \ -no-c++11 \ $(QT5BASE_CONFIGURE_OPTS) \