Redirect the per-channel build scratch to /dev/shm and skip UPX, a big win when building from a USB stick / SD card (I/O-bound on flash): - TMPDIR + PIP_CACHE_DIR -> tmpfs - PyInstaller: --workpath -> tmpfs (PYI_WORKPATH); UPX off via TESTIUM_NO_UPX - Flatpak: build dir + ostree repo -> tmpfs (FLATPAK_BUILDDIR/REPODIR); the .flatpak-builder download cache stays on disk - AppImage: bind-mount a tmpfs dir at the in-container AppDir path (APPIMAGE_APPDIR_TMPFS) Scratch is freed on exit. Each build.sh honors the env vars with on-disk defaults, so behavior is unchanged without --ram. With --ram, prefer --serial on RAM-limited machines (flatpak+appimage are ~1 GB each). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
31 lines
1.1 KiB
Bash
Executable File
31 lines
1.1 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
# Prérequis : installer le runtime et SDK KDE
|
|
# flatpak install flathub org.kde.Platform//6.10
|
|
# flatpak install flathub org.kde.Sdk//6.10
|
|
# flatpak install flathub io.qt.PySide.BaseApp//6.10
|
|
|
|
set -e
|
|
|
|
# Build + install local. FLATPAK_BUILDDIR / FLATPAK_REPODIR (set by build_all
|
|
# --ram) redirect the build dir and the ostree repo to tmpfs. The
|
|
# .flatpak-builder cache stays local so source downloads persist between runs.
|
|
BUILDDIR="${FLATPAK_BUILDDIR:-build}"
|
|
REPODIR="${FLATPAK_REPODIR:-repo}"
|
|
flatpak-builder --user --verbose --force-clean --install --repo="$REPODIR" "$BUILDDIR" org.testium.Testium.yaml
|
|
|
|
# Génère le bundle distribuable
|
|
flatpak build-bundle "$REPODIR" testium.flatpak org.testium.Testium
|
|
echo "Bundle généré : $(pwd)/testium.flatpak"
|
|
|
|
# Crée ~/.local/bin/testium pour pouvoir taper "testium" en console
|
|
WRAPPER="$HOME/.local/bin/testium"
|
|
mkdir -p "$HOME/.local/bin"
|
|
cat > "$WRAPPER" <<'EOF'
|
|
#!/bin/sh
|
|
exec flatpak run org.testium.Testium "$@"
|
|
EOF
|
|
chmod +x "$WRAPPER"
|
|
echo "Wrapper installé : $WRAPPER"
|
|
echo "Assurez-vous que ~/.local/bin est dans votre PATH."
|