aboutsummaryrefslogtreecommitdiff
path: root/pbuilder-updatebuildenv
diff options
context:
space:
mode:
authorLoïc Minier <lool@dooz.org>2010-01-02 15:33:06 +0100
committerLoïc Minier <lool@dooz.org>2010-01-02 15:36:38 +0100
commit047b1efbfe6f14a71432e27baa7c55fe7819e219 (patch)
treecafdf42a51bfb3dc8be00171c71ddfa22eef24c0 /pbuilder-updatebuildenv
parent2a4fbaea3a1f86ab54f240f6b6d1cc1ac454ef95 (diff)
downloadpbuilder-047b1efbfe6f14a71432e27baa7c55fe7819e219.tar
pbuilder-047b1efbfe6f14a71432e27baa7c55fe7819e219.tar.gz
Only remove/install aptitude on create/update
Only install aptitude in pbuilder-createbuildenv or pbuilder-updatebuildenv, not in pbuilder-satisfydepends-aptitude, and only when $PBUILDERSATISFYDEPENDSCMD uses aptitude. Remove aptitude in pbuilder-createbuildenv and pbuilder-updatebuildenv otherwise; closes: #539578.
Diffstat (limited to 'pbuilder-updatebuildenv')
-rwxr-xr-xpbuilder-updatebuildenv10
1 files changed, 10 insertions, 0 deletions
diff --git a/pbuilder-updatebuildenv b/pbuilder-updatebuildenv
index 874b7ce..25bcf05 100755
--- a/pbuilder-updatebuildenv
+++ b/pbuilder-updatebuildenv
@@ -38,6 +38,16 @@ loadhooks
log "I: Refreshing the base.tgz "
log "I: upgrading packages"
$CHROOTEXEC /usr/bin/apt-get -q update
+
+case "`readlink -e "$PBUILDERSATISFYDEPENDSCMD"`" in
+ *-aptitude)
+ EXTRAPACKAGES="$EXTRAPACKAGES aptitude"
+ ;;
+ *)
+ REMOVEPACKAGES="$REMOVEPACKAGES aptitude"
+ ;;
+esac
+
if [ -n "$REMOVEPACKAGES" ]; then
$CHROOTEXEC /usr/bin/dpkg --purge $REMOVEPACKAGES
fi