[oe-commits] [openembedded-core] 05/26: buildhistory: don't output ownership for the sysroot

git at git.openembedded.org git at git.openembedded.org
Tue Jul 9 22:37:09 UTC 2019


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit e4d822c1a4f42f2f912e760a0fe6c4b26ef86d73
Author: Ross Burton <ross.burton at intel.com>
AuthorDate: Tue Jul 9 00:46:43 2019 +0100

    buildhistory: don't output ownership for the sysroot
    
    As the sysroot isn't ran inside pseudo the ownership is whoever is running the
    builds.  In a setup where multiple builders all contribute to a shared
    buildhistory writing the ownership data isn't useful, so just replace it with "-
    -".
    
    Signed-off-by: Ross Burton <ross.burton at intel.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/classes/buildhistory.bbclass | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/meta/classes/buildhistory.bbclass b/meta/classes/buildhistory.bbclass
index baa7c8e..5bf2726 100644
--- a/meta/classes/buildhistory.bbclass
+++ b/meta/classes/buildhistory.bbclass
@@ -67,7 +67,7 @@ PATCH_GIT_USER_NAME ?= "OpenEmbedded"
 
 buildhistory_emit_sysroot() {
 	mkdir --parents ${BUILDHISTORY_DIR_PACKAGE}
-	buildhistory_list_files ${SYSROOT_DESTDIR} ${BUILDHISTORY_DIR_PACKAGE}/sysroot
+	buildhistory_list_files_no_owners ${SYSROOT_DESTDIR} ${BUILDHISTORY_DIR_PACKAGE}/sysroot
 }
 
 #
@@ -537,6 +537,20 @@ buildhistory_list_files() {
 	fi | sort -k5 | sed 's/ * -> $//' > $2 )
 }
 
+buildhistory_list_files_no_owners() {
+	# List the files in the specified directory, but exclude date/time etc.
+	# Also don't output the ownership data, but instead output just - - so
+	# that the same parsing code as for _list_files works.
+	# This is somewhat messy, but handles where the size is not printed for device files under pseudo
+	( cd $1
+	find_cmd='find . ! -path . -printf "%M -          -          %10s %p -> %l\n"'
+	if [ "$3" = "fakeroot" ] ; then
+		eval ${FAKEROOTENV} ${FAKEROOTCMD} "$find_cmd"
+	else
+		eval "$find_cmd"
+	fi | sort -k5 | sed 's/ * -> $//' > $2 )
+}
+
 buildhistory_list_pkg_files() {
 	# Create individual files-in-package for each recipe's package
 	for pkgdir in $(find ${PKGDEST}/* -maxdepth 0 -type d); do

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list