Skip to content

Add libwayland-client.so.0 to exclude list - #559

Merged
probonopd merged 2 commits into
AppImageCommunity:masterfrom
Zaraka:excludeWaylandClient
Nov 3, 2024
Merged

Add libwayland-client.so.0 to exclude list#559
probonopd merged 2 commits into
AppImageCommunity:masterfrom
Zaraka:excludeWaylandClient

Conversation

@Zaraka

@Zaraka Zaraka commented Oct 2, 2024

Copy link
Copy Markdown
Contributor

I have noticed that my Qt6 AppImage is failing on new distros such as Fedora 40, Arch etc.
It turns out an EGL/GLX integration is running into some issues, upon further inspection I found out about this issue here https://gitlab.freedesktop.org/mesa/mesa/-/issues/11316
After removing libwayland-client.so.0 from AppImage all issues were suddenly resolved

@probonopd

Copy link
Copy Markdown
Member

But what if the AppImage is run on a system that does not come with libwayland-client.so.0?

@gartnera

gartnera commented Oct 26, 2024

Copy link
Copy Markdown

I hit this today trying to run the Qt6 audacity AppImage today on Arch Linux with sway. It looks like several Qt6 projects already manually exclude this library:

New mesa libgl will call wl_display_create_queue_with_name which is not available in libwayland-client before https://gitlab.freedesktop.org/wayland/wayland/-/commit/b42218f790033c496c48c7d5ba1f8421db794d0b. So long as you exclude libgl I think you have to exclude this library too.

But what if the AppImage is run on a system that does not come with libwayland-client.so.0?

I wasn't able to find any supported distro version that didn't ship this library by default:

Details

image

image

image

image

@probonopd

@probonopd

probonopd commented Nov 3, 2024

Copy link
Copy Markdown
Member

Thanks for your investigation @gartnera. Appreciate it.

The whole Wayland thing has been driving me away from Linux big time.

If we exclude this library, then we can't run those AppImages on systems that are intentionally Wayland-free anymore. I understand that the situation is not ideal, but forcing everyone onto the Wayland bandwaggon isn't, either. Especially those of use who want to stay Wayland-free should imho not be forced to install a Wayland library on the system. (But I guess that's already the fact... Wayland is getting shoved down our throat if we want it or not.)

@gartnera

gartnera commented Nov 3, 2024

Copy link
Copy Markdown

systems that are intentionally Wayland-free

At least for QT apps, libwayland-client.so.0 will only be dlopen()'d if the wayland platform is needed and loaded. The top level binary does not link it directly:

2024-11-03-111056_screenshot

I suspect it works like this on most other UI toolkits. SDL seems to have similar options.

But I still don't think this even matters because mesa libegl is going to force you to install libwayland-client0 anyway:

root@0730a7d9f1a4:/# apt install libegl-mesa0
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following additional packages will be installed:
  libbsd0 libdrm-common libdrm2 libexpat1 libgbm1 libwayland-client0 libwayland-server0 libx11-6 libx11-data libx11-xcb1 libxau6 libxcb-dri2-0 libxcb-dri3-0 libxcb-present0 libxcb-randr0 libxcb-sync1 libxcb-xfixes0 libxcb1
  libxdmcp6 libxshmfence1
The following NEW packages will be installed:
  libbsd0 libdrm-common libdrm2 libegl-mesa0 libexpat1 libgbm1 libwayland-client0 libwayland-server0 libx11-6 libx11-data libx11-xcb1 libxau6 libxcb-dri2-0 libxcb-dri3-0 libxcb-present0 libxcb-randr0 libxcb-sync1 libxcb-xfixes0
  libxcb1 libxdmcp6 libxshmfence1
0 upgraded, 21 newly installed, 0 to remove and 3 not upgraded.
Need to get 1296 kB of archives.
After this operation, 4809 kB of additional disk space will be used.
Do you want to continue? [Y/n]

@gartnera

gartnera commented Nov 3, 2024

Copy link
Copy Markdown

Also I'm beginning to understand more about how musescore works around this. First, they only use linuxdeploy (and linuxdeploy-qt) to build the initial appdir. Then they have some custom (?) logic which allows "fallback" libraries:

@probonopd

Copy link
Copy Markdown
Member

Well then. Let's see where this leads us. Thanks everyone!

@probonopd
probonopd merged commit 15a64c2 into AppImageCommunity:master Nov 3, 2024
@TheAssassin

Copy link
Copy Markdown
Member

I released a new version of linuxdeploy based on this change.

@TheOneRing

Copy link
Copy Markdown

I released a new version of linuxdeploy based on this change.

Thanks, that should also resolve the issue we experienced with KDE Craft on Debian testing.

@Samueru-sama

Copy link
Copy Markdown
Contributor

Also I'm beginning to understand more about how musescore works around this. First, they only use linuxdeploy (and linuxdeploy-qt) to build the initial appdir. Then they have some custom (?) logic which allows "fallback" libraries:

* https://github.com/musescore/MuseScore/blob/master/buildscripts/ci/linux/tools/make_appimage.sh#L243

* https://github.com/musescore/MuseScore/blob/master/buildscripts/packaging/Linux%2BBSD/portable/AppRun.in

I recommend that you deploy all the libraries with the dynamic linker instead, you avoid all of these issues plus it actually works on any linux system, see examples here.

arrdalan pushed a commit to secluso/core that referenced this pull request Jul 22, 2026
Exclude libwayland: new version of Mesa has some dependency issues with
libwayland-client if it is bundled,
AppImageCommunity/pkg2appimage#559,
https://gitlab.freedesktop.org/mesa/mesa/-/issues/11316

tauri-apps/tauri#9304: webkit2gtk is broken
under 2.44 with Nvidia GPUs, disable via WEBKIT_DISABLE_DMABUF_RENDERER
for fallback to portable compositing




fixes #113
mauropereiira pushed a commit to mauropereiira/Moldavite that referenced this pull request Sep 6, 2026
…s on Fedora

Tauri fetches a July 2024 linuxdeploy into ~/.cache/tauri and reuses it.
That build copies Ubuntu 24.04's libwayland-client.so.0 (wayland 1.22)
into the AppImage, and Fedora's and Arch's Mesa libEGL_mesa need
wl_display_create_queue_with_name from wayland 1.23, so the symbol lookup
fails, EGL reports EGL_BAD_PARAMETER and WebKit exits its web process
before the first paint. The previous commit's smoke-linux-fedora run
shows exactly that: "Could not create default EGL display", no web
process, a two-color window.

linuxdeploy has excluded the library since November 2024
(AppImageCommunity/pkg2appimage#559). Seed Tauri's cache in CI and in the
release workflow with linuxdeploy 1-alpha-20251107-1, pinned by SHA-256,
and have build-linux assert the library is absent from the extracted
AppImage so the regression cannot come back quietly.

Closes #130

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
mauropereiira added a commit to mauropereiira/Moldavite that referenced this pull request Sep 6, 2026
* ci: smoke-test the Linux bundles on Fedora and ship an rpm

The 2.6.0 AppImage opens a blank white window on Fedora (#130): the
WebKit web process aborts with "Could not create default EGL display:
EGL_BAD_PARAMETER" before the first paint. Nothing in CI could see it,
because the only Linux that ever ran the bundles was the Ubuntu that
built them.

Add a smoke-linux-fedora job that launches the AppImage and an rpm
under Xvfb in a Fedora 44 container and fails on that EGL abort, on a
dead web process, or on a window with nothing painted in it. This
commit carries the test only; on the current bundler it is expected to
fail on the AppImage, which is the reproduction. The fix follows.

The rpm answers the reporter's other point, that a Fedora user cannot
try the deb. It depends on webkit2gtk4.1 and gtk3, is signed and listed
like the deb, and the release verification now expects it.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

* fix(linux): leave libwayland-client to the host so the AppImage paints on Fedora

Tauri fetches a July 2024 linuxdeploy into ~/.cache/tauri and reuses it.
That build copies Ubuntu 24.04's libwayland-client.so.0 (wayland 1.22)
into the AppImage, and Fedora's and Arch's Mesa libEGL_mesa need
wl_display_create_queue_with_name from wayland 1.23, so the symbol lookup
fails, EGL reports EGL_BAD_PARAMETER and WebKit exits its web process
before the first paint. The previous commit's smoke-linux-fedora run
shows exactly that: "Could not create default EGL display", no web
process, a two-color window.

linuxdeploy has excluded the library since November 2024
(AppImageCommunity/pkg2appimage#559). Seed Tauri's cache in CI and in the
release workflow with linuxdeploy 1-alpha-20251107-1, pinned by SHA-256,
and have build-linux assert the library is absent from the extracted
AppImage so the regression cannot come back quietly.

Closes #130

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

---------

Co-authored-by: Mauro Pereira <maurob.pereira@icloud.com>
Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants