wxGTK fails to build if X11/GLX is not available (Issue #26145)

6 views
Skip to first unread message

Chris Mayo

unread,
Feb 1, 2026, 2:28:43 PM (11 hours ago) Feb 1
to wx-...@googlegroups.com, Subscribed
cjmayo created an issue (wxWidgets/wxWidgets#26145)

Description

Building master for GTK fails when EGL/GDK_Wayland is available but GLX/GDK_X11 is not.

Seen with 7ba5acc, didn't happen with ace3d4d.
Presumably due to d9df7db.

Bug description:

src/unix/glcanvas.cpp:235:13: error: ‘wxGLBackendX11’ has not been declared; did you mean ‘wxGLBackend’?
  235 |     return &wxGLBackendX11::Get();
      |             ^~~~~~~~~~~~~~
      |             wxGLBackend

...

src/gtk/glcanvas.cpp:52:15: error: ‘XVisualInfo’ does not name a type
   52 |         const XVisualInfo* xvi = static_cast<XVisualInfo*>(win->GetXVisualInfo());
      |               ^~~~~~~~~~~
src/gtk/glcanvas.cpp:54:13: error: ‘GDK_VISUAL_XVISUAL’ was not declared in this scope; did you mean ‘GDK_IS_VISUAL’?
   54 |         if (GDK_VISUAL_XVISUAL(visual)->visualid != xvi->visualid)
      |             ^~~~~~~~~~~~~~~~~~
      |             GDK_IS_VISUAL
src/gtk/glcanvas.cpp:54:53: error: ‘xvi’ was not declared in this scope
   54 |         if (GDK_VISUAL_XVISUAL(visual)->visualid != xvi->visualid)
      |                                                     ^~~
src/gtk/glcanvas.cpp:57:22: error: ‘gdk_x11_screen_lookup_visual’ was not declared in this scope; did you mean ‘gdk_screen_list_visuals’?
   57 |             visual = gdk_x11_screen_lookup_visual(screen, xvi->visualid);
      |                      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                      gdk_screen_list_visuals

To Reproduce:

-DCMAKE_INSTALL_PREFIX=/usr -DwxUSE_SYS_LIBS=ON -DwxBUILD_COMPATIBILITY=3.2 -DwxUSE_XRC=ON -DwxUSE_LIBLZMA=yes -DwxUSE_SECRETSTORE=ON -DwxUSE_WEBREQUEST=no -DwxBUILD_PRECOMP=OFF -DwxUSE_GLCANVAS_EGL=ON -DwxUSE_GRAPHICS_CONTEXT=ON -DwxUSE_GTKPRINT=ON -DwxUSE_GUI=ON -DwxDEFAULT_TOOLKIT=gtk3 -DwxUSE_LIBPNG=sys -DwxUSE_LIBJPEG=sys -DwxUSE_LIBMSPACK=ON -DwxUSE_LIBWEBP=sys -DwxUSE_NANOSVG=sys -DwxUSE_LIBGNOMEVFS=OFF -DwxUSE_LIBSDL=yes -DwxUSE_MEDIACTRL=yes -DwxUSE_WEBVIEW=yes -DwxUSE_LIBNOTIFY=yes -DwxUSE_OPENGL=yes -DwxUSE_SPELLCHECK=yes -DwxUSE_WAYLAND=yes -DwxBUILD_TESTS=OFF -DwxUSE_UIACTIONSIMULATOR=no -DwxUSE_XTEST=no -DCMAKE_BUILD_TYPE=RelWithDebInfo

Platform and version information

  • wxWidgets version: master
  • wxWidgets port wxGTK
  • OS Gentoo Linux
    • GTK version: 3.24.51
    • GDK Wayland backend is used
    • Desktop environment GNOME


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/issues/26145@github.com>

Reply all
Reply to author
Forward
0 new messages