Fix AppImage GStreamer and GResource loading failures#3
Merged
Conversation
The AppImage crashes on startup with two issues: 1. GStreamer symbol mismatch: the bundled libmedia-gstreamer.so tries to load system GStreamer libraries built against a newer GLib (with g_sort_array from GLib 2.82+) than what the AppImage bundles. Fixed by setting GTK_MEDIA=none and clearing GST_PLUGIN_SYSTEM_PATH in the AppRun hook, since the app doesn't need media playback. 2. GResource not found: UI template files aren't loaded, causing a crash when GTK tries to instantiate widgets. Added exe-relative fallback logic in main.rs so the gresource file is found even if the ADVENTURE_MODS_PKGDATADIR env var isn't set correctly. Also improved error reporting from silent .ok() to an eprintln warning. https://claude.ai/code/session_01X2YjHosc7qFY61uwzeRYND
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
GTK_MEDIA=noneand clearGST_PLUGIN_SYSTEM_PATHin the AppRun hook to prevent the bundled GStreamer media backend from loading system GStreamer libraries built against an incompatible (newer) GLib version. The app doesn't use media playback, so this has no functional impact.main.rsso the.gresourcefile is found even when theADVENTURE_MODS_PKGDATADIRenv var isn't set correctly. The binary at<prefix>/bin/now looks for resources at../share/adventure-mods/relative to itself..ok()swallowing of GResource load errors to aneprintlnwarning, making future debugging easier.Test plan
build-aux/appimage/build-appimage.shmain.rschanges)https://claude.ai/code/session_01X2YjHosc7qFY61uwzeRYND