bitbake: Add bb.utils.join_deps to handle creation of dependency strings with versions

Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
This commit is contained in:
Richard Purdie 2010-06-30 09:47:36 +01:00
parent b180d7f488
commit 9a543b75ca
1 changed files with 12 additions and 0 deletions

View File

@ -138,6 +138,18 @@ def explode_dep_versions(s):
return r
def join_deps(deps):
"""
Take the result from explode_dep_versions and generate a dependency string
"""
result = []
for dep in deps:
if deps[dep]:
result.append(dep + " (" + deps[dep] + ")")
else:
result.append(dep)
return ", ".join(result)
def _print_trace(body, line):
"""
Print the Environment of a Text Body