fix(build): disable pipefail around tar head pipe to prevent SIGPIPE
Some checks failed
Build CLI with Embedded SQLite / build (arm64, aarch64-linux) (push) Waiting to run
Build CLI with Embedded SQLite / build (x86_64, x86_64-linux) (push) Waiting to run
Build CLI with Embedded SQLite / build-macos (arm64) (push) Waiting to run
Build CLI with Embedded SQLite / build-macos (x86_64) (push) Waiting to run
CI with Native Libraries / Build and Test Native Libraries (push) Blocked by required conditions
CI with Native Libraries / Build Release Libraries (push) Blocked by required conditions
Documentation / build-and-publish (push) Waiting to run
Security Scan / Security Analysis (push) Waiting to run
Security Scan / Native Library Security (push) Waiting to run
Checkout test / test (push) Successful in 5s
CI with Native Libraries / Check Build Environment (push) Successful in 11s
CI/CD Pipeline / Test (push) Failing after 1m3s
CI/CD Pipeline / Dev Compose Smoke Test (push) Has been skipped
CI/CD Pipeline / Build (push) Has been skipped
CI/CD Pipeline / Test Scripts (push) Has been skipped
CI/CD Pipeline / Security Scan (push) Has been cancelled
CI/CD Pipeline / Docker Build (push) Has been cancelled

The tar | head -n 1 | cut pipeline causes SIGPIPE (error 141)

when head closes the pipe before tar finishes writing
This commit is contained in:
Jeremie Fraeys 2026-02-21 20:46:15 -05:00
parent 7bc1c8a982
commit 2e2bba47a2
No known key found for this signature in database

View file

@ -73,7 +73,9 @@ if [[ "${verified}" -ne 1 ]]; then
fi
tar -C "${tmp}" -xzf "${tmp}/rsync.tar.gz"
set +o pipefail
extract_dir="$(tar -tzf "${tmp}/rsync.tar.gz" | head -n 1 | cut -d/ -f1)"
set -o pipefail
cd "${tmp}/${extract_dir}"
CC=musl-gcc CFLAGS="-O2" LDFLAGS="-static" ./configure --disable-xxhash --disable-zstd --disable-lz4