fix(deploy): serialize CLI/APK/AppImage builds to avoid cargo target contention
The v0.7.0 release surfaced a real bug: parallel cargo invocations
all writing to target/ caused linuxdeploy to fail mid-AppImage bundle
("Error failed to bundle project failed to run linuxdeploy"). Cargo's
own target-dir locking doesn't fully serialize three concurrent
cargo-front-ends across CLI + Android-cross-compile + tauri-bundle.
Solo cargo tauri build succeeded immediately after deploy.sh aborted,
confirming the parallel invocation was the root cause.
Switching to serial builds. The extra wall time is small because
cargo's incremental cache deduplicates compilation of the shared
itsgoin-core crate across the three builds.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
ad9282f24a
commit
ec393c7f85
1 changed files with 12 additions and 15 deletions
27
deploy.sh
27
deploy.sh
|
|
@ -21,23 +21,20 @@ KS_ALIAS="itsgoin"
|
|||
VERSION=$(grep '"version"' crates/tauri-app/tauri.conf.json | head -1 | sed 's/.*"\([0-9.]*\)".*/\1/')
|
||||
echo "=== Deploying v${VERSION} ==="
|
||||
|
||||
# Build CLI
|
||||
echo "=== Building CLI ==="
|
||||
cargo build -p itsgoin-cli --release &
|
||||
CLI_PID=$!
|
||||
# Builds run SERIALLY — parallel cargo invocations write to the same
|
||||
# target/ directory, which causes intermittent failures (linuxdeploy
|
||||
# blowing up mid-AppImage was the v0.7.0 release symptom). The extra
|
||||
# wall time vs. the parallel version is small because cargo's
|
||||
# incremental cache deduplicates the shared core crate compilation.
|
||||
|
||||
# Build APK
|
||||
echo "=== Building APK ==="
|
||||
cargo tauri android build --apk &
|
||||
APK_PID=$!
|
||||
|
||||
# Build AppImage (includes GStreamer patch)
|
||||
echo "=== Building AppImage ==="
|
||||
echo "=== Building AppImage (includes GStreamer patch) ==="
|
||||
./build-appimage.sh
|
||||
wait $CLI_PID
|
||||
echo "=== CLI build complete ==="
|
||||
wait $APK_PID
|
||||
echo "=== APK build complete ==="
|
||||
|
||||
echo "=== Building APK ==="
|
||||
cargo tauri android build --apk
|
||||
|
||||
echo "=== Building CLI ==="
|
||||
cargo build -p itsgoin-cli --release
|
||||
|
||||
# Sign APK
|
||||
echo "=== Signing APK ==="
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue