summaryrefslogtreecommitdiff
path: root/bitbake/lib/bb/runqueue.py
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2007-09-02 14:10:08 +0000
committerRichard Purdie <richard@openedhand.com>2007-09-02 14:10:08 +0000
commite223238b1b88c9b6888972b7944b3854319e4928 (patch)
treeae78533078bd8e7382d50778cec144541eae65f6 /bitbake/lib/bb/runqueue.py
parent1cf731b1e3bb125449c2ef4e1194b6bf69e7b667 (diff)
downloadopenembedded-core-e223238b1b88c9b6888972b7944b3854319e4928.tar.gz
openembedded-core-e223238b1b88c9b6888972b7944b3854319e4928.tar.bz2
openembedded-core-e223238b1b88c9b6888972b7944b3854319e4928.zip
bitbake: Update to latest bitbake-1.8 branch
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2651 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'bitbake/lib/bb/runqueue.py')
-rw-r--r--bitbake/lib/bb/runqueue.py26
1 files changed, 25 insertions, 1 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index 3dfae219d2..f245fd6c1d 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -7,7 +7,7 @@ BitBake 'RunQueue' implementation
Handles preparation and execution of a queue of tasks
"""
-# Copyright (C) 2006 Richard Purdie
+# Copyright (C) 2006-2007 Richard Purdie
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
@@ -63,6 +63,7 @@ class RunQueue:
self.targets = targets
self.number_tasks = int(bb.data.getVar("BB_NUMBER_THREADS", cfgData) or 1)
+ self.multi_provider_whitelist = (bb.data.getVar("MULTI_PROVIDER_WHITELIST", cfgData) or "").split()
def reset_runqueue(self):
@@ -373,6 +374,29 @@ class RunQueue:
if runq_weight1[task] != 0:
bb.msg.fatal(bb.msg.domain.RunQueue, "Task %s (%s) count not zero!" % (task, self.get_user_idstring(task)))
+
+ # Check for mulitple taska building the same provider
+ prov_list = {}
+ seen_fn = []
+ for task in range(len(self.runq_fnid)):
+ fn = taskData.fn_index[self.runq_fnid[task]]
+ if fn in seen_fn:
+ continue
+ seen_fn.append(fn)
+ for prov in self.dataCache.fn_provides[fn]:
+ if prov not in prov_list:
+ prov_list[prov] = [fn]
+ elif fn not in prov_list[prov]:
+ prov_list[prov].append(fn)
+ error = False
+ for prov in prov_list:
+ if len(prov_list[prov]) > 1 and prov not in self.multi_provider_whitelist:
+ error = True
+ bb.msg.error(bb.msg.domain.RunQueue, "Multiple files due to be built which all provide %s (%s)" % (prov, " ".join(prov_list[prov])))
+ #if error:
+ # bb.msg.fatal(bb.msg.domain.RunQueue, "Corrupted metadata configuration detected, aborting...")
+
+
# Make a weight sorted map
from copy import deepcopy