mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-03-09 15:50:02 +00:00
Simplify exit status fix, restore interruptability
The exit status fix introduced in cherry-picked commit 22c3a6e1 introduced a problem: interrupting the build only interrupted the main process, and the background job would happily continue. bin/package, src/cmd/INIT/package.sh: - Give up on the idea of a background job and put up with not cleaning up the FIFO. It's in a build directory that is going to get cleaned up anyway.
This commit is contained in:
parent
7a8a46700c
commit
936802f92a
2 changed files with 6 additions and 6 deletions
|
@ -3969,6 +3969,8 @@ capture() # file command ...
|
||||||
0) if executable ! $TEE
|
0) if executable ! $TEE
|
||||||
then TEE=tee
|
then TEE=tee
|
||||||
fi
|
fi
|
||||||
|
# Connect 'tee' to a FIFO instead of a pipe, so that the build is invoked from
|
||||||
|
# the main shell environment and its exit status can be used for $error_status
|
||||||
rm -f $o.fifo
|
rm -f $o.fifo
|
||||||
mkfifo -m 600 $o.fifo || exit
|
mkfifo -m 600 $o.fifo || exit
|
||||||
$TEE -a $o < $o.fifo &
|
$TEE -a $o < $o.fifo &
|
||||||
|
@ -3978,9 +3980,7 @@ capture() # file command ...
|
||||||
esac
|
esac
|
||||||
showenv $action
|
showenv $action
|
||||||
"$@"
|
"$@"
|
||||||
} > $o.fifo 2>&1 &
|
} < /dev/null > $o.fifo 2>&1
|
||||||
rm $o.fifo # unlink early
|
|
||||||
wait "$!" # get build's exit status
|
|
||||||
;;
|
;;
|
||||||
*) {
|
*) {
|
||||||
case $s in
|
case $s in
|
||||||
|
|
|
@ -3968,6 +3968,8 @@ capture() # file command ...
|
||||||
0) if executable ! $TEE
|
0) if executable ! $TEE
|
||||||
then TEE=tee
|
then TEE=tee
|
||||||
fi
|
fi
|
||||||
|
# Connect 'tee' to a FIFO instead of a pipe, so that the build is invoked from
|
||||||
|
# the main shell environment and its exit status can be used for $error_status
|
||||||
rm -f $o.fifo
|
rm -f $o.fifo
|
||||||
mkfifo -m 600 $o.fifo || exit
|
mkfifo -m 600 $o.fifo || exit
|
||||||
$TEE -a $o < $o.fifo &
|
$TEE -a $o < $o.fifo &
|
||||||
|
@ -3977,9 +3979,7 @@ capture() # file command ...
|
||||||
esac
|
esac
|
||||||
showenv $action
|
showenv $action
|
||||||
"$@"
|
"$@"
|
||||||
} > $o.fifo 2>&1 &
|
} < /dev/null > $o.fifo 2>&1
|
||||||
rm $o.fifo # unlink early
|
|
||||||
wait "$!" # get build's exit status
|
|
||||||
;;
|
;;
|
||||||
*) {
|
*) {
|
||||||
case $s in
|
case $s in
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue