-
-
Notifications
You must be signed in to change notification settings - Fork 0
Pattern AppImage
m-wells edited this page Feb 21, 2026
·
2 revisions
Example: rpi-imager
AppImages are self-contained Linux applications. We extract and repackage them for system integration.
arch=('x86_64')
depends=('fuse2' 'zlib')
options=('!strip')
source=("App-${pkgver}.AppImage::https://example.com/releases/App-${pkgver}.AppImage")
prepare() {
chmod +x "App-${pkgver}.AppImage"
"./App-${pkgver}.AppImage" --appimage-extract
}
package() {
# Install AppImage
install -Dm755 "App-${pkgver}.AppImage" "$pkgdir/opt/$pkgname/app.AppImage"
# Wrapper script
install -Dm755 /dev/stdin "$pkgdir/usr/bin/$pkgname" <<'EOF'
#!/bin/bash
exec /opt/pkgname/app.AppImage "$@"
EOF
# Desktop integration (extracted from AppImage)
install -Dm644 "squashfs-root/app.desktop" "$pkgdir/usr/share/applications/$pkgname.desktop"
install -Dm644 "squashfs-root/app.png" "$pkgdir/usr/share/pixmaps/$pkgname.png"
}-
arch=('x86_64')- AppImages are architecture-specific -
options=('!strip')- Don't strip the AppImage binary - Requires
fuse2for execution - Extract
.desktopand icons with--appimage-extract
For apps requiring root (like disk imaging tools), use pkexec:
#!/bin/bash
pkexec --disable-internal-agent /opt/pkgname/app.AppImage "$@"# scripts/packages/example.sh
check_github_release "example" "org/repo"Navigation
Build Patterns
Infrastructure