[oe-commits] [bitbake] 02/05: bitbake: build.py: check dependendent task for addtask

git at git.openembedded.org git at git.openembedded.org
Mon Apr 29 13:17:29 UTC 2019


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

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

commit 7a1cfbfb6400e2a2e8e8b824e6ed8111e6f8b5fc
Author: Robert Yang <liezhi.yang at windriver.com>
AuthorDate: Mon Apr 29 16:11:59 2019 +0800

    bitbake: build.py: check dependendent task for addtask
    
    The following command is incorrect, but was ignored silently, that may suprise
    users:
    
    addtask task after task_not_existed
    
    This patch can check and warn for it. It would be better to also check "before"
    tasks, but there is no easier way to do it.
    
    [YOCTO #13282]
    
    Signed-off-by: Robert Yang <liezhi.yang at windriver.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bb/build.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/bb/build.py b/lib/bb/build.py
index 7571421..a83de8d 100644
--- a/lib/bb/build.py
+++ b/lib/bb/build.py
@@ -815,6 +815,9 @@ def add_tasks(tasklist, d):
         task_deps['parents'][task] = []
         if 'deps' in flags:
             for dep in flags['deps']:
+                # Check and warn for "addtask task after foo" while foo does not exist
+                if not dep in tasklist:
+                    bb.warn('%s: dependent task %s does not exist' % (d.getVar('PN'), dep))
                 dep = d.expand(dep)
                 task_deps['parents'][task].append(dep)
 

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


More information about the Openembedded-commits mailing list