Patchwork [1/3] package_manager.py: fix installed package list creation for Opkg/Dpkg

login
register
mail settings
Submitter Laurentiu Palcu
Date Feb. 19, 2014, 10:51 a.m.
Message ID <6c2e8a6b62170b58e9513494203d24d3ae2df2c9.1392806896.git.laurentiu.palcu@intel.com>
Download mbox | patch
Permalink /patch/66969/
State New
Headers show

Comments

Laurentiu Palcu - Feb. 19, 2014, 10:51 a.m.
Small error in the package list creation routine. Buildhistory was
supposed to use this but was never called. Hence, it escaped tests...

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
---
 meta/lib/oe/package_manager.py |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

Patch

diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 6dc8fbd..a3c0a8e 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -1134,7 +1134,8 @@  class OpkgPM(PackageManager):
 
         if format == "file":
             tmp_output = ""
-            for pkg, pkg_file, pkg_arch in tuple(output.split('\n')):
+            for line in output.split('\n'):
+                pkg, pkg_file, pkg_arch = line.split()
                 full_path = os.path.join(self.deploy_dir, pkg_arch, pkg_file)
                 if os.path.exists(full_path):
                     tmp_output += "%s %s %s\n" % (pkg, full_path, pkg_arch)
@@ -1435,7 +1436,8 @@  class DpkgPM(PackageManager):
 
         if format == "file":
             tmp_output = ""
-            for pkg, pkg_file, pkg_arch in tuple(output.split('\n')):
+            for line in tuple(output.split('\n')):
+                pkg, pkg_file, pkg_arch = line.split()
                 full_path = os.path.join(self.deploy_dir, pkg_arch, pkg_file)
                 if os.path.exists(full_path):
                     tmp_output += "%s %s %s\n" % (pkg, full_path, pkg_arch)