diff options
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/insane.bbclass | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass index 2cb8cc0abf..67729445a9 100644 --- a/meta/classes/insane.bbclass +++ b/meta/classes/insane.bbclass @@ -179,9 +179,14 @@ def package_qa_get_machine_dict(d): return machdata -def package_qa_clean_path(path,d): - """ Remove the common prefix from the path. In this case it is the TMPDIR""" - return path.replace(d.getVar("TMPDIR", True) + "/", "") +def package_qa_clean_path(path, d, pkg=None): + """ + Remove redundant paths from the path for display. If pkg isn't set then + TMPDIR is stripped, otherwise PKGDEST/pkg is stripped. + """ + if pkg: + path = path.replace(os.path.join(d.getVar("PKGDEST", True), pkg), "/") + return path.replace(d.getVar("TMPDIR", True), "/").replace("//", "/") def package_qa_write_error(type, error, d): logfile = d.getVar('QA_LOGFILE', True) |