]> code.ossystems Code Review - openembedded-core.git/commitdiff
toaster.bbclass: Correct parsing of installed-package-sizes.txt
authorPeter Kjellerstedt <peter.kjellerstedt@axis.com>
Sat, 11 Mar 2017 05:26:54 +0000 (06:26 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 17 Mar 2017 15:37:05 +0000 (15:37 +0000)
The recent change in buildhistory.bbclass to use a tab in
installed-package-sizes.txt between "KiB" and the package name caused
toaster_buildhistory_dump() to fail since it parses the file and
expected a space there.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/classes/toaster.bbclass

index a68557882c966fcfabf1de51514c53aa9d7d4cd4..4de380bce20dbd5e22e760b76299b6715a3e4e35 100644 (file)
@@ -265,8 +265,7 @@ python toaster_buildhistory_dump() {
             with open("%s/installed-package-sizes.txt" % installed_img_path, "r") as fin:
                 for line in fin:
                     line = line.rstrip(";")
-                    psize, px = line.split("\t")
-                    punit, pname = px.split(" ")
+                    psize, punit, pname = line.split()
                     # this size is "installed-size" as it measures how much space it takes on disk
                     images[target][pname.strip()] = {'size':int(psize)*1024, 'depends' : []}