diff options
Diffstat (limited to 'meta/classes-global')
-rw-r--r-- | meta/classes-global/base.bbclass | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/meta/classes-global/base.bbclass b/meta/classes-global/base.bbclass index dbbf6cef8c..cb3460a8ee 100644 --- a/meta/classes-global/base.bbclass +++ b/meta/classes-global/base.bbclass | |||
@@ -542,6 +542,20 @@ python () { | |||
542 | d.setVarFlag('do_devshell', 'fakeroot', '1') | 542 | d.setVarFlag('do_devshell', 'fakeroot', '1') |
543 | d.appendVarFlag('do_devshell', 'depends', ' virtual/fakeroot-native:do_populate_sysroot') | 543 | d.appendVarFlag('do_devshell', 'depends', ' virtual/fakeroot-native:do_populate_sysroot') |
544 | 544 | ||
545 | # Handle recipe level PREFERRED_PROVIDERs | ||
546 | depends = (d.getVar("DEPENDS") or "").split() | ||
547 | virtprovs = (d.getVar("RECIPE_VIRTUAL_PROVIDERS") or "").split() | ||
548 | newdeps = [] | ||
549 | for dep in depends: | ||
550 | if dep in virtprovs: | ||
551 | newdep = d.getVar("PREFERRED_PROVIDER_" + dep) | ||
552 | if not newdep: | ||
553 | bb.fatal("Error, recipe virtual provider PREFERRED_PROVIDER_%s not set" % dep) | ||
554 | newdeps.append(newdep) | ||
555 | else: | ||
556 | newdeps.append(dep) | ||
557 | d.setVar("DEPENDS", " ".join(newdeps)) | ||
558 | |||
545 | need_machine = d.getVar('COMPATIBLE_MACHINE') | 559 | need_machine = d.getVar('COMPATIBLE_MACHINE') |
546 | if need_machine and not bb.utils.to_boolean(d.getVar('PARSE_ALL_RECIPES', False)): | 560 | if need_machine and not bb.utils.to_boolean(d.getVar('PARSE_ALL_RECIPES', False)): |
547 | import re | 561 | import re |