aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunichi Uekawa <dancer@netfort.gr.jp>2009-06-19 23:25:45 +0900
committerJunichi Uekawa <dancer@netfort.gr.jp>2009-06-19 23:25:45 +0900
commitbee2c543671251097eabdd124c62396edca82e87 (patch)
treee9f9318d17e7d2388356fdfc26857c89cd211814
parent0a1cf29fa210b5d90880d4b4d6b668bb81007f94 (diff)
downloadpbuilder-bee2c543671251097eabdd124c62396edca82e87.tar
pbuilder-bee2c543671251097eabdd124c62396edca82e87.tar.gz
Do not error out on etch apt for apt-get autoremove (closes: #531454)
Just ignore the error for now. '|| true' should be removed after etch is no longer supported. There are other solutions like checking for versions, but I don't like the complexity required just to support an old version.
-rwxr-xr-xpbuilder-updatebuildenv5
1 files changed, 4 insertions, 1 deletions
diff --git a/pbuilder-updatebuildenv b/pbuilder-updatebuildenv
index 2cbc8a9..92ccd0f 100755
--- a/pbuilder-updatebuildenv
+++ b/pbuilder-updatebuildenv
@@ -45,7 +45,10 @@ recover_aptcache
$TRAP saveaptcache_umountproc_cleanbuildplace_trap exit sighup
$CHROOTEXEC /usr/bin/apt-get -y --force-yes "${FORCE_CONFNEW[@]}" dist-upgrade
-$CHROOTEXEC /usr/bin/apt-get -y --force-yes autoremove
+# autoremove: Ignore error in case of etch because apt in etch doesn't
+# support autoremove. TODO: Do not ignore error when etch is no longer
+# supported.
+$CHROOTEXEC /usr/bin/apt-get -y --force-yes autoremove || true
$CHROOTEXEC /usr/bin/apt-get -y --force-yes install build-essential dpkg-dev apt aptitude $EXTRAPACKAGES
save_aptcache