aboutsummaryrefslogtreecommitdiff
path: root/linaro_image_tools/media_create/chroot_utils.py
diff options
context:
space:
mode:
authorLoïc Minier <lool@dooz.org>2011-04-04 23:20:09 +0200
committerLoïc Minier <lool@dooz.org>2011-04-04 23:20:09 +0200
commit3628850b867637d6d7c3e8a1dcec1bce7ed3a00e (patch)
treefb03fd08c03d376121588eaa2cf0fecbff0c61a9 /linaro_image_tools/media_create/chroot_utils.py
parente620978a3cd0e03f1556f5b02443e1d5c99cf747 (diff)
Run apt-get clean after installing packages.
Diffstat (limited to 'linaro_image_tools/media_create/chroot_utils.py')
-rw-r--r--linaro_image_tools/media_create/chroot_utils.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/linaro_image_tools/media_create/chroot_utils.py b/linaro_image_tools/media_create/chroot_utils.py
index 487aa01..816bb6d 100644
--- a/linaro_image_tools/media_create/chroot_utils.py
+++ b/linaro_image_tools/media_create/chroot_utils.py
@@ -95,6 +95,9 @@ def install_packages(chroot_dir, tmp_dir, *packages):
print "Installing (apt-get) %s in target rootfs." % " ".join(packages)
args = ("apt-get", "--yes", "install") + packages
cmd_runner.run(args, as_root=True, chroot=chroot_dir).wait()
+ print "Cleaning up downloaded packages."
+ args = ("apt-get", "clean")
+ cmd_runner.run(args, as_root=True, chroot=chroot_dir).wait()
print "-" * 60
finally:
run_local_atexit_funcs()