Add portable packaging: AppImage for Linux, zip for Windows

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
AgelandClaude Sonnet 4.6 committed 2026-03-16 21:05:54 +01:00
1 parent ca307e6383
commit 4e8cc5063a
5 files changed
+210 -5

No files matched your search

+31
View File
@@ -0,0 +1,31 @@
#!/bin/bash
# Package Linux build as AppImage
# Usage: package-linux.sh <build-dir> <qt-dir> <output-dir>
set -euo pipefail
BUILD_DIR="${1:?Usage: package-linux.sh <build-dir> <qt-dir> <output-dir>}"
QT_DIR="${2:?}"
OUTPUT_DIR="${3:?}"
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
PROJECT_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
APPDIR="${BUILD_DIR}/AppDir"
rm -rf "$APPDIR"
# linuxdeploy handles AppDir structure, library bundling, and AppRun
export QMAKE="$QT_DIR/bin/qmake"
export QML_SOURCES_PATHS="$PROJECT_DIR/src/qml"
export LD_LIBRARY_PATH="$QT_DIR/lib:${LD_LIBRARY_PATH:-}"
export OUTPUT="Asteria-x86_64.AppImage"
linuxdeploy \
--appdir "$APPDIR" \
--executable "$BUILD_DIR/asteria-qt" \
--desktop-file "$PROJECT_DIR/packaging/asteria-qt.desktop" \
--icon-file "$PROJECT_DIR/src/assets/moon1.svg" \
--plugin qt \
--output appimage
mkdir -p "$OUTPUT_DIR"
mv "$OUTPUT" "$OUTPUT_DIR/"