diff options
author | Mikko Ylinen <mikko.ylinen@linux.intel.com> | 2017-09-27 11:08:15 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-10-06 12:03:32 +0100 |
commit | 1a90c97616698050529e169a83e6f07a255687df (patch) | |
tree | c44519372baa35f31d88ed5a90aba4dcd34ee575 /meta | |
parent | 0a8639593c11ef0cfb3a3a514b17e36318b8e8f2 (diff) | |
download | openembedded-core-contrib-1a90c97616698050529e169a83e6f07a255687df.tar.gz |
package_manager: rpm: improve logging
To be able to better debug remove() behaviour, add more logging
to rpm calls via bb.note(). The change also makes remove() logging
more consistent with other package managers' remove() (e.g., opkg).
Signed-off-by: Mikko Ylinen <mikko.ylinen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/lib/oe/package_manager.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py index 658c9642774..d458a9b01d5 100644 --- a/meta/lib/oe/package_manager.py +++ b/meta/lib/oe/package_manager.py @@ -614,10 +614,12 @@ class RpmPM(PackageManager): self._invoke_dnf(["remove"] + pkgs) else: cmd = bb.utils.which(os.getenv('PATH'), "rpm") - args = ["-e", "--nodeps", "--root=%s" %self.target_rootfs] + args = ["-e", "-v", "--nodeps", "--root=%s" %self.target_rootfs] try: + bb.note("Running %s" % ' '.join([cmd] + args + pkgs)) output = subprocess.check_output([cmd] + args + pkgs, stderr=subprocess.STDOUT).decode("utf-8") + bb.note(output) except subprocess.CalledProcessError as e: bb.fatal("Could not invoke rpm. Command " "'%s' returned %d:\n%s" % (' '.join([cmd] + args + pkgs), e.returncode, e.output.decode("utf-8"))) |