Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/makepkg.sh.in11
1 files changed, 10 insertions, 1 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 4d33a9c0..f2c9b363 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -740,7 +740,16 @@ run_package() {
mv "$BUILDLOG" "$BUILDLOG.$i"
fi
- package 2>&1 | tee "$BUILDLOG"; ret=${PIPESTATUS[0]}
+ # ensure overridden package variables suvrive tee with split packages
+ logpipe=$(mktemp -u "$startdir/logpipe.XXXXXXXX")
+ mknod "$logpipe" p
+ exec 3>&1
+ tee "$BUILDLOG" < "$logpipe" &
+ exec 1>"$logpipe" 2>"$logpipe"
+ package 2>&1 || ret=$?
+ sync
+ exec 1>&3 2>&3 3>&-
+ rm "$logpipe"
else
package 2>&1 || ret=$?
fi