Skip to content

Commit fca2c0c

Browse files
authored
Fix Raspberry Pi Build - EGL_DISPMANX_WINDOW_T not defined (#3470)
See: https://forum.qt.io/topic/88588/qtbase-compilation-error-with-device-linux-rasp-pi3-g-qeglfskmsgbmwindow-cpp/9 for details of the fix
1 parent b4dbc12 commit fca2c0c

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/glcontext_egl.cpp

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,12 @@ WL_EGL_IMPORT
250250
};
251251

252252
# if BX_PLATFORM_RPI
253+
typedef uint32_t DISPMANX_ELEMENT_HANDLE_T;
254+
typedef struct {
255+
DISPMANX_ELEMENT_HANDLE_T element;
256+
int width; /* This is necessary because dispmanx elements are not queriable. */
257+
int height;
258+
} EGL_DISPMANX_WINDOW_T;
253259
static EGL_DISPMANX_WINDOW_T s_dispmanWindow;
254260
# endif // BX_PLATFORM_RPI
255261

@@ -384,7 +390,7 @@ WL_EGL_IMPORT
384390
s_dispmanWindow.element = dispmanElement;
385391
s_dispmanWindow.width = _width;
386392
s_dispmanWindow.height = _height;
387-
nwh = &s_dispmanWindow;
393+
nwh = (EGLNativeWindowType) &s_dispmanWindow;
388394

389395
vc_dispmanx_update_submit_sync(dispmanUpdate);
390396
# endif // BX_PLATFORM_ANDROID

0 commit comments

Comments
 (0)