From 03b938efa3b7589d2345978c2bc1bfc831e8eb36 Mon Sep 17 00:00:00 2001 From: CRT Date: Sat, 10 Oct 2026 21:52:50 +0000 Subject: [PATCH] desktop.yml: preset the bun sidecar's rpath so linuxdeploy's patchelf does not corrupt it in the AppImage --- .forgejo/workflows/desktop.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.forgejo/workflows/desktop.yml b/.forgejo/workflows/desktop.yml index eaeda011..2a3dff80 100644 --- a/.forgejo/workflows/desktop.yml +++ b/.forgejo/workflows/desktop.yml @@ -66,6 +66,11 @@ jobs: bun install --frozen-lockfile bun tools/desktop-version.ts bun tools/build-sidecars.ts --target bun-linux-x64 + # linuxdeploy (AppImage) sets the rpath of every executable with its own patchelf, which corrupts the bun + # sidecar (segfault, then ldd fails in the gtk plugin). With the rpath already set (Ubuntu's patchelf, which + # keeps it working), linuxdeploy leaves the file as it is. The sidecar needs only libc, so the rpath is inert. + patchelf --set-rpath '$ORIGIN/../lib' apps/desktop/src-tauri/binaries/storebound-x86_64-unknown-linux-gnu + apps/desktop/src-tauri/binaries/storebound-x86_64-unknown-linux-gnu version - name: Build AppImage and deb (path-free) working-directory: apps/desktop run: bun ../../tools/desktop-release.ts exec -- bunx tauri build --bundles appimage,deb --ci --verbose