From 8ceb6f45d5596cebe5678350ea1f03ca73571d5f Mon Sep 17 00:00:00 2001 From: Siavash Sameni Date: Fri, 10 Apr 2026 16:16:07 +0400 Subject: [PATCH] fix(build): declare VARIANT in local script half (was remote-only) The VARIANT variable was set inside the REMOTE_SCRIPT heredoc for naming artifacts during the cargo tauri build, but never declared in the local half of the script where it's used to rename downloaded files. Under `set -u` strict mode this aborted the local downloads with "unbound variable: VARIANT" after a successful remote build. Co-Authored-By: Claude Opus 4.6 (1M context) --- scripts/build-linux-desktop-docker.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/scripts/build-linux-desktop-docker.sh b/scripts/build-linux-desktop-docker.sh index ccd20c4..8fb7c22 100755 --- a/scripts/build-linux-desktop-docker.sh +++ b/scripts/build-linux-desktop-docker.sh @@ -31,7 +31,7 @@ SSH_OPTS="-o ConnectTimeout=15 -o ServerAliveInterval=15 -o ServerAliveCountMax= REBUILD_RUST=0 DO_PULL=1 IMAGE_BUILD=0 -# WITH_AEC=1 enables the wzp-client `linux-aec` feature (WebRTC AEC3 via +# WITH_AEC=1 enables the wzp-client `linux-aec` feature (WebRTC AEC via # webrtc-audio-processing) and renames the output artifacts with an `-aec` # suffix so both variants can coexist on disk. WITH_AEC=0 @@ -49,6 +49,15 @@ for arg in "$@"; do esac done +# Variant suffix used locally to rename downloaded artifacts so the noAEC +# baseline and the AEC build can coexist in $LOCAL_OUTPUT. Mirrors the +# same VARIANT declaration inside the remote REMOTE_SCRIPT heredoc. +if [ "$WITH_AEC" = "1" ]; then + VARIANT="aec" +else + VARIANT="noAEC" +fi + log() { echo -e "\033[1;36m>>> $*\033[0m"; } ssh_cmd() { ssh $SSH_OPTS "$REMOTE_HOST" "$@"; }