diff --git a/data/scripts/Linux-AppImage/AppRun b/data/scripts/Linux-AppImage/AppRun index 2933e154a..3158a282b 100755 --- a/data/scripts/Linux-AppImage/AppRun +++ b/data/scripts/Linux-AppImage/AppRun @@ -161,6 +161,13 @@ setup_vaapi() { fi } +setup_wayland() { + # use bundled Wayland libs only when not running on Wayland, otherwise system ones + if [ -z "${WAYLAND_DISPLAY-}" ]; then + LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$AI_LIB_PATH/wayland" + fi +} + add_whitelist() { if expr "$1" : /tmp >/dev/null; then printf -- "$separator--read-write=%s --mkdir=%s" "$1" "$1" @@ -202,6 +209,7 @@ get_firejail_whitelist() { } setup_vaapi +setup_wayland # shellcheck source=/dev/null . "$DIR/scripts/jack_preload.sh" diff --git a/data/scripts/Linux-AppImage/create-appimage.sh b/data/scripts/Linux-AppImage/create-appimage.sh index 14c4d947a..1eb5a643c 100755 --- a/data/scripts/Linux-AppImage/create-appimage.sh +++ b/data/scripts/Linux-AppImage/create-appimage.sh @@ -70,6 +70,12 @@ for n in "$APPPREFIX"/bin/* "$APPPREFIX"/lib/ultragrid/* $PLUGIN_LIBS; do done done +# hide Wayland libraries +if ls $APPPREFIX/lib/libwayland-* >/dev/null 2>&1; then + mkdir $APPPREFIX/lib/wayland + mv $APPPREFIX/lib/libwayland-* $APPPREFIX/lib/wayland +fi + if command wget >/dev/null && wget -V | grep -q https; then dl() { wget -O - ${GITHUB_TOKEN+--header "Authorization: token $GITHUB_TOKEN"} "$1"