Skip to content

Commit

Permalink
fix: updated appimage script to follow symlinks for /usr/lib* (fix: #…
Browse files Browse the repository at this point in the history
…6992) (#6996)

* Updated appimage script to follow symlinks for /usr/lib*

* Added appimage-follow-symlinks change file
  • Loading branch information
Risto-Stevcev authored May 19, 2023
1 parent c7056d1 commit 0302138
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
6 changes: 6 additions & 0 deletions .changes/appimage-follow-symlinks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'tauri-bundler': 'patch'
---

- Updated the AppImage bundler to follow symlinks for `/usr/lib*`.
- Fixes AppImage bundling for Void Linux, which was failing to bundle webkit2gtk because the `/usr/lib64` is a symlink to `/usr/lib`.
8 changes: 4 additions & 4 deletions tooling/bundler/src/bundle/linux/templates/appimage
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@ if [[ "$TRAY_LIBRARY_PATH" != "0" ]]; then
fi
fi

# Copy WebKit files.
find /usr/lib* -name WebKitNetworkProcess -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true
find /usr/lib* -name WebKitWebProcess -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true
find /usr/lib* -name libwebkit2gtkinjectedbundle.so -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true
# Copy WebKit files. Follow symlinks in case `/usr/lib64` is a symlink to `/usr/lib`
find -L /usr/lib* -name WebKitNetworkProcess -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true
find -L /usr/lib* -name WebKitWebProcess -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true
find -L /usr/lib* -name libwebkit2gtkinjectedbundle.so -exec mkdir -p "$(dirname '{}')" \; -exec cp --parents '{}' "." \; || true

( cd "{{tauri_tools_path}}" && ( wget -q -4 -N https://github.com/AppImage/AppImageKit/releases/download/continuous/AppRun-${ARCH} || wget -q -4 -N https://github.com/AppImage/AppImageKit/releases/download/12/AppRun-${ARCH} ) )
chmod +x "{{tauri_tools_path}}/AppRun-${ARCH}"
Expand Down

0 comments on commit 0302138

Please sign in to comment.