diff options
author | Chen Qi <Qi.Chen@windriver.com> | 2015-02-17 10:08:13 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-02-17 22:29:04 +0000 |
commit | 14e8d826c4a5231ef331d8064d150737fe3ed656 (patch) | |
tree | f71a3b6c7fb29203be56e445ba49098a8c61b868 | |
parent | 3fc812377baf95768cef0b7728a73a4b9e07f2ab (diff) | |
download | openembedded-core-14e8d826c4a5231ef331d8064d150737fe3ed656.tar.gz openembedded-core-14e8d826c4a5231ef331d8064d150737fe3ed656.tar.bz2 openembedded-core-14e8d826c4a5231ef331d8064d150737fe3ed656.zip |
package_manager.py: use 'purge' instead of 'remove' in case of deb
We need to use 'purge' instead of 'remove' for debian package backend when
removing packages at rootfs time. This is because that 'remove' command for
'dpkg' and 'apt-get' does not remove configuration files.
Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/lib/oe/package_manager.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py index 986ae54942..f801333e54 100644 --- a/meta/lib/oe/package_manager.py +++ b/meta/lib/oe/package_manager.py @@ -1631,10 +1631,10 @@ class DpkgPM(PackageManager): def remove(self, pkgs, with_dependencies=True): if with_dependencies: os.environ['APT_CONFIG'] = self.apt_conf_file - cmd = "%s remove %s" % (self.apt_get_cmd, ' '.join(pkgs)) + cmd = "%s purge %s" % (self.apt_get_cmd, ' '.join(pkgs)) else: cmd = "%s --admindir=%s/var/lib/dpkg --instdir=%s" \ - " -r --force-depends %s" % \ + " -P --force-depends %s" % \ (bb.utils.which(os.getenv('PATH'), "dpkg"), self.target_rootfs, self.target_rootfs, ' '.join(pkgs)) |