diff options
author | dancer <dancer> | 2002-01-24 01:20:47 +0000 |
---|---|---|
committer | dancer <dancer> | 2002-01-24 01:20:47 +0000 |
commit | 2947553d0cf463a35e29313b3397a7d4119803bb (patch) | |
tree | 46a2a2d06057ad9621b35ecb7bb79add7114941a /pbuilder-updatebuildenv | |
parent | 969fc109ee2db79c63309c2501b60b16eb7fca07 (diff) | |
download | pbuilder-2947553d0cf463a35e29313b3397a7d4119803bb.tar pbuilder-2947553d0cf463a35e29313b3397a7d4119803bb.tar.gz |
trap, instead of other methods
Diffstat (limited to 'pbuilder-updatebuildenv')
-rwxr-xr-x | pbuilder-updatebuildenv | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/pbuilder-updatebuildenv b/pbuilder-updatebuildenv index d53510b..cff78b6 100755 --- a/pbuilder-updatebuildenv +++ b/pbuilder-updatebuildenv @@ -22,18 +22,19 @@ if [ -n "$HOOKDIR" ]; then fi echo "Refreshing the base.tgz " echo " -> upgrading packages" -$CHROOTEXEC /usr/bin/apt-get update || abortprocess -$CHROOTEXEC /usr/bin/dpkg --purge lilo || abortprocess -$CHROOTEXEC /usr/bin/apt-get -y dist-upgrade || abortprocess -$CHROOTEXEC /usr/bin/apt-get -y install build-essential dpkg-dev apt $EXTRAPACKAGES || abortprocess -$CHROOTEXEC /usr/bin/apt-get clean || abortprocess +trap abortprocess exit +$CHROOTEXEC /usr/bin/apt-get update +$CHROOTEXEC /usr/bin/dpkg --purge lilo +$CHROOTEXEC /usr/bin/apt-get -y dist-upgrade +$CHROOTEXEC /usr/bin/apt-get -y install build-essential dpkg-dev apt $EXTRAPACKAGES +$CHROOTEXEC /usr/bin/apt-get clean if [ -n "$HOOKDIR" ]; then executehooks "X" unloadhooks fi - umountproc +trap cleanbuildplace exit echo " -> creating base.tgz" (cd "$BUILDPLACE"; tar cfz "$BASETGZ" *) cleanbuildplace |