]> code.ossystems Code Review - openembedded-core.git/commitdiff
insane: use clean_path for the host contamination warnings
authorRoss Burton <ross.burton@intel.com>
Wed, 3 Jul 2019 15:01:28 +0000 (16:01 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Fri, 5 Jul 2019 11:00:14 +0000 (12:00 +0100)
We've a nice function to clean up absolute build paths for display, so use it.

Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/insane.bbclass

index 0695a04438732be7b66088367b13c14b4aa1d458..891d3a8421840b1cbbd958168c6fce44a74d6376 100644 (file)
@@ -874,15 +874,14 @@ def package_qa_check_host_user(path, name, d, elf, messages):
         if exc.errno != errno.ENOENT:
             raise
     else:
-        rootfs_path = path[len(dest):]
         check_uid = int(d.getVar('HOST_USER_UID'))
         if stat.st_uid == check_uid:
-            package_qa_add_message(messages, "host-user-contaminated", "%s: %s is owned by uid %d, which is the same as the user running bitbake. This may be due to host contamination" % (pn, rootfs_path, check_uid))
+            package_qa_add_message(messages, "host-user-contaminated", "%s: %s is owned by uid %d, which is the same as the user running bitbake. This may be due to host contamination" % (pn, package_qa_clean_path(path, d, name), check_uid))
             return False
 
         check_gid = int(d.getVar('HOST_USER_GID'))
         if stat.st_gid == check_gid:
-            package_qa_add_message(messages, "host-user-contaminated", "%s: %s is owned by gid %d, which is the same as the user running bitbake. This may be due to host contamination" % (pn, rootfs_path, check_gid))
+            package_qa_add_message(messages, "host-user-contaminated", "%s: %s is owned by gid %d, which is the same as the user running bitbake. This may be due to host contamination" % (pn, package_qa_clean_path(path, d, name), check_gid))
             return False
     return True