From: Richard Purdie Date: Tue, 10 Mar 2020 13:02:07 +0000 (+0000) Subject: oeqa/selftest: Ensure buildtools in environment variables isn't replaced X-Git-Tag: 2020-04-dunfell~211 X-Git-Url: https://code.ossystems.io/gitweb?a=commitdiff_plain;h=04ee0e8b95cd8ed890374e0007f976684206b630;p=openembedded-core.git oeqa/selftest: Ensure buildtools in environment variables isn't replaced This avoids the seeing broken replacements like: oe-selftest-centos/build/build-st-926tools/sysroots/x86_64-pokysdk-linux/etc/ssl/certs/ca-certificates.crt which understandably break builds. Signed-off-by: Richard Purdie --- diff --git a/meta/lib/oeqa/selftest/context.py b/meta/lib/oeqa/selftest/context.py index 409698d57c..48ec5d419c 100644 --- a/meta/lib/oeqa/selftest/context.py +++ b/meta/lib/oeqa/selftest/context.py @@ -46,7 +46,7 @@ class OESelftestTestContext(OETestContext): oe.path.copytree(selftestdir, newselftestdir) for e in os.environ: - if builddir in os.environ[e]: + if builddir + "/" in os.environ[e] or os.environ[e].endswith(builddir): os.environ[e] = os.environ[e].replace(builddir, newbuilddir) subprocess.check_output("git init; git add *; git commit -a -m 'initial'", cwd=newselftestdir, shell=True)