From bc442de08ff2e45ae01cb74397ccf010ef9797af Mon Sep 17 00:00:00 2001 From: Patrick Williams Date: Wed, 18 Nov 2020 12:29:25 -0600 Subject: os-release: disable 'pseudo' for git bitbake recipes are run under a process monitor called 'pseudo'. We are observing cases where these are triggering a "Pseudo Abort" due to inode reuse (https://wiki.yoctoproject.org/wiki/Pseudo_Abort) of some sort. 'pseudo' is used for running operations which may require higher levels of privledge and recording them so they can be re-applied when building a file system. The `git` calls we are doing are to determine the revision of the repository and therefore do not need 'pseudo' support. Disable it with the PSEUDO_DISABLED=1 env var. Also, add a bb.warn call of any exception that is caused by the `git` call for future debugging. (From meta-phosphor rev: 64cdbcfa62b5009f7282091b54d10e1149cf0689) Signed-off-by: Patrick Williams Change-Id: I6ac3fbb1ee15f435ce53ce8f82830120446205a9 Signed-off-by: Andrew Geissler --- meta-phosphor/recipes-core/os-release/os-release.bbappend | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'meta-phosphor/recipes-core') diff --git a/meta-phosphor/recipes-core/os-release/os-release.bbappend b/meta-phosphor/recipes-core/os-release/os-release.bbappend index 0f938c392..5d4a4afbc 100644 --- a/meta-phosphor/recipes-core/os-release/os-release.bbappend +++ b/meta-phosphor/recipes-core/os-release/os-release.bbappend @@ -8,9 +8,11 @@ def run_git(d, cmd): try: oeroot = d.getVar('COREBASE', True) - return bb.process.run("git --work-tree %s --git-dir %s/.git %s" + return bb.process.run(("export PSEUDO_DISABLED=1; " + + "git --work-tree %s --git-dir %s/.git %s") % (oeroot, oeroot, cmd))[0].strip('\n') - except: + except Exception as e: + bb.warn("Unexpected exception from 'git' call: %s" % e) pass VERSION_ID := "${@run_git(d, 'describe --dirty --long')}" -- cgit v1.2.3