summaryrefslogtreecommitdiff
path: root/src/make.bash
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2009-06-22 15:43:50 -0700
committerRuss Cox <rsc@golang.org>2009-06-22 15:43:50 -0700
commitcd9a3746d6e9d83d2b31d7f1f48e571ae759e56c (patch)
treeb21b652677457287d05336e9fea1a8c4b717a68e /src/make.bash
parent28c928ff9f63a4fb0c46cf79908ecd6d10f805b2 (diff)
downloadgo-cd9a3746d6e9d83d2b31d7f1f48e571ae759e56c.tar.gz
set -e does not apply to ( ) blocks,
so implement the check manually. sigh. R=r DELTA=17 (6 added, 0 deleted, 11 changed) OCL=30606 CL=30612
Diffstat (limited to 'src/make.bash')
-rwxr-xr-xsrc/make.bash28
1 files changed, 17 insertions, 11 deletions
diff --git a/src/make.bash b/src/make.bash
index 6b103c657..00cc6b4fd 100755
--- a/src/make.bash
+++ b/src/make.bash
@@ -19,17 +19,23 @@ cp quietgcc.bash $HOME/bin/quietgcc
chmod +x $HOME/bin/quietgcc
for i in lib9 libbio libmach_amd64 libregexp cmd pkg cmd/gobuild cmd/godoc cmd/gofmt
-do (
- echo; echo; echo %%%% making $i %%%%; echo
- cd $i
- case $i in
- cmd)
- bash make.bash
- ;;
- *)
- make install
- esac
-) done
+do
+ # The ( ) here are to preserve the current directory
+ # for the next round despite the cd $i below.
+ # set -e does not apply to ( ) so we must explicitly
+ # test the exit status.
+ (
+ echo; echo; echo %%%% making $i %%%%; echo
+ cd $i
+ case $i in
+ cmd)
+ bash make.bash
+ ;;
+ *)
+ make install
+ esac
+ ) || exit 1
+done
case "`uname`" in
Darwin)