diff options
author | Samuli Piippo <samuli.piippo@qt.io> | 2019-01-09 15:15:05 +0200 |
---|---|---|
committer | Samuli Piippo <samuli.piippo@qt.io> | 2019-01-10 11:56:08 +0000 |
commit | 88f5aca25ee842a60ba38f2e21e04dedf049ee3e (patch) | |
tree | b96c4fc5464b3dd2380bd500f0dcd6abf1926bac /meta-fsl-extras/recipes/qt5/qtbase | |
parent | 500e3a9564f232683a215dc685bc00d5a5d9d719 (diff) | |
download | meta-boot2qt-88f5aca25ee842a60ba38f2e21e04dedf049ee3e.tar.gz |
freescale: egl_viv: cast EGLNative types from vivante functions
All vivante functions return void* even when the actual native type
(EGLNativeDisplayType, EGLNativeWindowType, etc.) might be typedef'ed
as something else, as they do when the CFLAGS from egl.pc are now used.
Change-Id: I23bbe223a77d9233bbe0325c1e96f6e0612799cc
Reviewed-by: Mikko Gronoff <mikko.gronoff@qt.io>
Diffstat (limited to 'meta-fsl-extras/recipes/qt5/qtbase')
-rw-r--r-- | meta-fsl-extras/recipes/qt5/qtbase/0001-egl_viv-cast-EGLNative-types-from-vivante-functions.patch | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/meta-fsl-extras/recipes/qt5/qtbase/0001-egl_viv-cast-EGLNative-types-from-vivante-functions.patch b/meta-fsl-extras/recipes/qt5/qtbase/0001-egl_viv-cast-EGLNative-types-from-vivante-functions.patch new file mode 100644 index 0000000..dc56cfc --- /dev/null +++ b/meta-fsl-extras/recipes/qt5/qtbase/0001-egl_viv-cast-EGLNative-types-from-vivante-functions.patch | |||
@@ -0,0 +1,57 @@ | |||
1 | From 40e76307c1ee1ebe4e0142d623071d0f768f2450 Mon Sep 17 00:00:00 2001 | ||
2 | From: Samuli Piippo <samuli.piippo@qt.io> | ||
3 | Date: Wed, 9 Jan 2019 13:01:01 +0000 | ||
4 | Subject: [PATCH] egl_viv: cast EGLNative types from vivante functions | ||
5 | |||
6 | All vivante functions return void* even when the actual native type | ||
7 | (EGLNativeDisplayType, EGLNativeWindowType, etc.) might be typedef'ed | ||
8 | as something else, as they do when the CFLAGS from egl.pc are now used. | ||
9 | --- | ||
10 | .../deviceintegration/eglfs_viv/qeglfsvivintegration.cpp | 4 ++-- | ||
11 | .../deviceintegration/eglfs_viv_wl/qeglfsvivwlintegration.cpp | 4 ++-- | ||
12 | 2 files changed, 4 insertions(+), 4 deletions(-) | ||
13 | |||
14 | diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv/qeglfsvivintegration.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv/qeglfsvivintegration.cpp | ||
15 | index 763a4a462b..2fc076ad0c 100644 | ||
16 | --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv/qeglfsvivintegration.cpp | ||
17 | +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv/qeglfsvivintegration.cpp | ||
18 | @@ -65,7 +65,7 @@ void QEglFSVivIntegration::platformInit() | ||
19 | VivanteInit(); | ||
20 | mNativeDisplay = fbGetDisplay(); | ||
21 | #else | ||
22 | - mNativeDisplay = fbGetDisplayByIndex(framebufferIndex()); | ||
23 | + mNativeDisplay = static_cast<EGLNativeDisplayType>(fbGetDisplayByIndex(framebufferIndex())); | ||
24 | #endif | ||
25 | |||
26 | fbGetDisplayGeometry(mNativeDisplay, &width, &height); | ||
27 | @@ -88,7 +88,7 @@ EGLNativeWindowType QEglFSVivIntegration::createNativeWindow(QPlatformWindow *wi | ||
28 | Q_UNUSED(window) | ||
29 | Q_UNUSED(format) | ||
30 | |||
31 | - EGLNativeWindowType eglWindow = fbCreateWindow(mNativeDisplay, 0, 0, size.width(), size.height()); | ||
32 | + EGLNativeWindowType eglWindow = static_cast<EGLNativeWindowType>(fbCreateWindow(mNativeDisplay, 0, 0, size.width(), size.height())); | ||
33 | return eglWindow; | ||
34 | } | ||
35 | |||
36 | diff --git a/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv_wl/qeglfsvivwlintegration.cpp b/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv_wl/qeglfsvivwlintegration.cpp | ||
37 | index 61e2f17766..3bdae239cd 100644 | ||
38 | --- a/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv_wl/qeglfsvivwlintegration.cpp | ||
39 | +++ b/src/plugins/platforms/eglfs/deviceintegration/eglfs_viv_wl/qeglfsvivwlintegration.cpp | ||
40 | @@ -60,7 +60,7 @@ void QEglFSVivWaylandIntegration::platformInit() | ||
41 | } | ||
42 | |||
43 | mWaylandDisplay = wl_display_create(); | ||
44 | - mNativeDisplay = fbGetDisplay(mWaylandDisplay); | ||
45 | + mNativeDisplay = static_cast<EGLNativeDisplayType>(fbGetDisplay(mWaylandDisplay)); | ||
46 | fbGetDisplayGeometry(mNativeDisplay, &width, &height); | ||
47 | mScreenSize.setHeight(height); | ||
48 | mScreenSize.setWidth(width); | ||
49 | @@ -81,7 +81,7 @@ EGLNativeWindowType QEglFSVivWaylandIntegration::createNativeWindow(QPlatformWin | ||
50 | Q_UNUSED(window) | ||
51 | Q_UNUSED(format) | ||
52 | |||
53 | - EGLNativeWindowType eglWindow = fbCreateWindow(mNativeDisplay, 0, 0, size.width(), size.height()); | ||
54 | + EGLNativeWindowType eglWindow = static_cast<EGLNativeWindowType>(fbCreateWindow(mNativeDisplay, 0, 0, size.width(), size.height())); | ||
55 | return eglWindow; | ||
56 | } | ||
57 | |||