From 32611395e1da21f6f7f7916fb8077e35ee81bb23 Mon Sep 17 00:00:00 2001 From: Aníbal Limón Date: Thu, 11 Feb 2016 16:08:05 -0600 Subject: classes/testsdk: do_testsdkext avoid STAGING_DIR/BASE_WORKDIR in PATH MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The inclusion of STAGING_DIR/BASE_WORKDIR in PATH is contaminating the environment, i.e. when try to sanity check perl (check_perl_modules) it takes perl from STAGING_DIR causing eSDK install to fail. Signed-off-by: Aníbal Limón Signed-off-by: Richard Purdie --- meta/classes/testsdk.bbclass | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'meta/classes/testsdk.bbclass') diff --git a/meta/classes/testsdk.bbclass b/meta/classes/testsdk.bbclass index 487f40cea4..a56ad5edfc 100644 --- a/meta/classes/testsdk.bbclass +++ b/meta/classes/testsdk.bbclass @@ -97,9 +97,18 @@ def testsdkext_main(d): # extensible sdk shows a warning if found bitbake in the path # because can cause problems so clean it new_path = '' + paths_to_avoid = ['bitbake/bin', 'poky/scripts', + d.getVar('STAGING_DIR', True), + d.getVar('BASE_WORKDIR', True)] for p in os.environ['PATH'].split(':'): - if 'bitbake/bin' in p or 'poky/scripts' in p: + avoid = False + for pa in paths_to_avoid: + if pa in p: + avoid = True + break + if avoid: continue + new_path = new_path + p + ':' new_path = new_path[:-1] os.environ['PATH'] = new_path -- cgit 1.2.3-korg