class NoRProvider(bb.BBHandledException):
"""Exception raised when no provider of a runtime dependency can be found"""
+class MultipleRProvider(bb.BBHandledException):
+ """Exception raised when multiple providers of a runtime dependency can be found"""
def findProviders(cfgData, dataCache, pkg_pn = None):
"""
providers_list.append(dataCache.pkg_fn[fn])
bb.event.fire(bb.event.MultipleProviders(item, providers_list, runtime=True), cfgData)
self.consider_msgs_cache.append(item)
+ raise bb.providers.MultipleRProvider(item)
# run through the list until we find one that we can build
for fn in eligible:
try:
self.add_rprovider(cfgData, dataCache, target)
added = added + 1
- except bb.providers.NoRProvider:
+ except (bb.providers.NoRProvider, bb.providers.MultipleRProvider):
self.remove_runtarget(self.getrun_id(target))
logger.debug(1, "Resolved " + str(added) + " extra dependencies")
if added == 0: