From 1c4d511987ace0b19082bc212eef3611579fd293 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=BCller?= Date: Sun, 10 Apr 2016 16:58:17 +0200 Subject: [PATCH] greenisland: RaspberryPi vc4 enhancements MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Andreas Müller --- recipes-hawaii/greenisland/greenisland.bb | 1 + ...t-suggest-closed-source-gles-driver-.patch | 65 +++++++++++++++++++ 2 files changed, 66 insertions(+) create mode 100644 recipes-hawaii/greenisland/greenisland/0002-RaspberryPi-Don-t-suggest-closed-source-gles-driver-.patch diff --git a/recipes-hawaii/greenisland/greenisland.bb b/recipes-hawaii/greenisland/greenisland.bb index 581f1a54..98ea9d5a 100644 --- a/recipes-hawaii/greenisland/greenisland.bb +++ b/recipes-hawaii/greenisland/greenisland.bb @@ -14,6 +14,7 @@ DEPENDS += " \ SRC_URI = " \ git://github.com/greenisland/${BPN}.git;protocol=git;branch=master \ file://0001-find-native-greenisland-wayland-scanner.patch \ + file://0002-RaspberryPi-Don-t-suggest-closed-source-gles-driver-.patch \ " # we don't have wayland-protocols yet - revisit diff --git a/recipes-hawaii/greenisland/greenisland/0002-RaspberryPi-Don-t-suggest-closed-source-gles-driver-.patch b/recipes-hawaii/greenisland/greenisland/0002-RaspberryPi-Don-t-suggest-closed-source-gles-driver-.patch new file mode 100644 index 00000000..a680f8fc --- /dev/null +++ b/recipes-hawaii/greenisland/greenisland/0002-RaspberryPi-Don-t-suggest-closed-source-gles-driver-.patch @@ -0,0 +1,65 @@ +From eee96e00715613232465319071d0b7ac20cd41c5 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Sat, 9 Apr 2016 23:01:18 +0200 +Subject: [PATCH] RaspberryPi: Don't suggest closed source gles driver when + using open source vc4 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +When building greenisland for RaspberryPi with open source GL drivers (vc4), +cmake does not find closed source drivers (which is correct) + +| -- The following OPTIONAL packages have not been found: +| +| * BcmHost , Broadcom OpenGLES graphics libraries. , + +Launching a hawaii session reports: + +| greenisland.qpa.deviceintegration: Preferred EGL device integration based on the hardware configuration: "brcm" + +which does not make sense - there were no integration libs for closed source +RaspberryPi GLES built. + +Signed-off-by: Andreas Müller +--- + cmake/FindBcmHost.cmake | 2 ++ + src/platform/deviceintegration/deviceintegration_p.cpp | 2 ++ + 2 files changed, 4 insertions(+) + +diff --git a/cmake/FindBcmHost.cmake b/cmake/FindBcmHost.cmake +index 99e5127..0322b1d 100644 +--- a/cmake/FindBcmHost.cmake ++++ b/cmake/FindBcmHost.cmake +@@ -90,6 +90,8 @@ find_package_handle_standard_args(BcmHost + if(BcmHost_FOUND) + set(BcmHost_LIBRARY_DIRS "${BcmHost_PREFIX}/lib") + set(BcmHost_INCLUDE_DIR ${BcmHost_INCLUDE_DIR} ${BcmHost_INCLUDE_DIR}/interface ${BcmHost_INCLUDE_DIR}/interface/vcos/pthreads) ++else() ++ add_definitions(-DWITHOUT_BRCM) + endif() + + if(BcmHost_FOUND) +diff --git a/src/platform/deviceintegration/deviceintegration_p.cpp b/src/platform/deviceintegration/deviceintegration_p.cpp +index 369f43d..278210e 100644 +--- a/src/platform/deviceintegration/deviceintegration_p.cpp ++++ b/src/platform/deviceintegration/deviceintegration_p.cpp +@@ -56,6 +56,7 @@ public: + if (!qEnvironmentVariableIsEmpty("DISPLAY")) + return QStringLiteral("x11"); + ++#ifndef WITHOUT_BRCM + // Detect Broadcom + bool found = deviceModel().startsWith(QLatin1String("Raspberry")); + if (!found) { +@@ -67,6 +68,7 @@ public: + } + if (found) + return QStringLiteral("brcm"); ++#endif + + // TODO: Detect Mali + // TODO: Detect Vivante +-- +2.5.5 +