Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

appimage: bundle libraries which may be absent on modern hosts #5203

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

buzzhuzz
Copy link
Contributor

Description

Bundle minimal set of libraries to run on modern hosts like Ubuntu 24.04, Fedora40, Aurora Linux.

Modify startup script and GUI_App to set current working dir to the appimage root in order to workaround webkit2gtk hard-coded paths.

Fixes #4616

Tests

Tested by community members at #4616

Do not cchange current working dir while application is running.
This is needed for AppImage to properly function with webkit2gtk
bundled in. We modify libwebkit2gtk.so to use relative dir to refer
for WebKit binaries.
Bundle set of essential libs which may be missing on modern hosts
since they likely to have newer versions of the same libs.

Modify startup script to set current working dir to the appimage root.
@buzzhuzz
Copy link
Contributor Author

This change may or may not be relevant depending on how long it would take to have #4175 integrated.

@@ -1937,9 +1937,6 @@ void GUI_App::init_app_config()
if (!boost::filesystem::exists(data_dir_path)){
boost::filesystem::create_directory(data_dir_path);
}

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need this otherwise some wired tuk log files will be generated in application folder if Bambu network plugin is used

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a problem then.

libwebkit2gtk refers to webkit binaries located at /usr/lib/x86_64-linux/gnu/webkit2gtk-4.0/ using absolute paths. I modify libwebkit2gtk-4.0.so replacing absolute path with relative one ././/lib/x86_64-linux-gnu/webkit2gtk-4.0 just like recommended by AppImage documentation so bundled webkit would be used instead on system-supplied at /usr/...

In theory it should be possible to intercept system calls using LD_PRELOAD trick, but I couldn't get it working using appimage-builder which is using hooks to manipulate file paths.

I'll look what could be done for this.

@chaotixtech
Copy link

Just tested on a new instal of Kubuntu 24.0. with Ryzen9 and AMD graphics. Runs without any problems, I was unable to get the latest release or nightly build to run without the webdevkit error. I don't use Bambu network plugin.

@NeoPrint3D
Copy link

Any luck?

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.

Appimage - error while loading shared libraries: libwebkit2gtk-4.0.so.37
4 participants