diff options
| -rw-r--r-- | meta/classes/buildhistory.bbclass | 3 | ||||
| -rw-r--r-- | meta/lib/oe/buildhistory_analysis.py | 16 |
2 files changed, 14 insertions, 5 deletions
diff --git a/meta/classes/buildhistory.bbclass b/meta/classes/buildhistory.bbclass index 63980f72a5..2e5213e66e 100644 --- a/meta/classes/buildhistory.bbclass +++ b/meta/classes/buildhistory.bbclass | |||
| @@ -77,6 +77,7 @@ python buildhistory_emit_pkghistory() { | |||
| 77 | 77 | ||
| 78 | import re | 78 | import re |
| 79 | import json | 79 | import json |
| 80 | import shlex | ||
| 80 | import errno | 81 | import errno |
| 81 | 82 | ||
| 82 | pkghistdir = d.getVar('BUILDHISTORY_DIR_PACKAGE') | 83 | pkghistdir = d.getVar('BUILDHISTORY_DIR_PACKAGE') |
| @@ -287,7 +288,7 @@ python buildhistory_emit_pkghistory() { | |||
| 287 | dictval = json.loads(val) | 288 | dictval = json.loads(val) |
| 288 | filelist = list(dictval.keys()) | 289 | filelist = list(dictval.keys()) |
| 289 | filelist.sort() | 290 | filelist.sort() |
| 290 | pkginfo.filelist = " ".join(filelist) | 291 | pkginfo.filelist = " ".join([shlex.quote(x) for x in filelist]) |
| 291 | 292 | ||
| 292 | pkginfo.size = int(pkgdata['PKGSIZE']) | 293 | pkginfo.size = int(pkgdata['PKGSIZE']) |
| 293 | 294 | ||
diff --git a/meta/lib/oe/buildhistory_analysis.py b/meta/lib/oe/buildhistory_analysis.py index ff7815d7c9..ad7fceb8bb 100644 --- a/meta/lib/oe/buildhistory_analysis.py +++ b/meta/lib/oe/buildhistory_analysis.py | |||
| @@ -13,6 +13,7 @@ import os.path | |||
| 13 | import difflib | 13 | import difflib |
| 14 | import git | 14 | import git |
| 15 | import re | 15 | import re |
| 16 | import shlex | ||
| 16 | import hashlib | 17 | import hashlib |
| 17 | import collections | 18 | import collections |
| 18 | import bb.utils | 19 | import bb.utils |
| @@ -115,10 +116,13 @@ class ChangeRecord: | |||
| 115 | aitems = pkglist_combine(depvera) | 116 | aitems = pkglist_combine(depvera) |
| 116 | bitems = pkglist_combine(depverb) | 117 | bitems = pkglist_combine(depverb) |
| 117 | else: | 118 | else: |
| 118 | aitems = self.oldvalue.split() | ||
| 119 | bitems = self.newvalue.split() | ||
| 120 | if self.fieldname == 'FILELIST': | 119 | if self.fieldname == 'FILELIST': |
| 120 | aitems = shlex.split(self.oldvalue) | ||
| 121 | bitems = shlex.split(self.newvalue) | ||
| 121 | renamed_dirs, aitems, bitems = detect_renamed_dirs(aitems, bitems) | 122 | renamed_dirs, aitems, bitems = detect_renamed_dirs(aitems, bitems) |
| 123 | else: | ||
| 124 | aitems = self.oldvalue.split() | ||
| 125 | bitems = self.newvalue.split() | ||
| 122 | 126 | ||
| 123 | removed = list(set(aitems) - set(bitems)) | 127 | removed = list(set(aitems) - set(bitems)) |
| 124 | added = list(set(bitems) - set(aitems)) | 128 | added = list(set(bitems) - set(aitems)) |
| @@ -409,9 +413,13 @@ def compare_dict_blobs(path, ablob, bblob, report_all, report_ver): | |||
| 409 | (depvera, depverb) = compare_pkg_lists(astr, bstr) | 413 | (depvera, depverb) = compare_pkg_lists(astr, bstr) |
| 410 | if depvera == depverb: | 414 | if depvera == depverb: |
| 411 | continue | 415 | continue |
| 412 | alist = astr.split() | 416 | if key == 'FILELIST': |
| 417 | alist = shlex.split(astr) | ||
| 418 | blist = shlex.split(bstr) | ||
| 419 | else: | ||
| 420 | alist = astr.split() | ||
| 421 | blist = bstr.split() | ||
| 413 | alist.sort() | 422 | alist.sort() |
| 414 | blist = bstr.split() | ||
| 415 | blist.sort() | 423 | blist.sort() |
| 416 | # We don't care about the removal of self-dependencies | 424 | # We don't care about the removal of self-dependencies |
| 417 | if pkgname in alist and not pkgname in blist: | 425 | if pkgname in alist and not pkgname in blist: |
