summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/fetch/__init__.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/fetch/__init__.py')
-rw-r--r--bitbake/lib/bb/fetch/__init__.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/bitbake/lib/bb/fetch/__init__.py b/bitbake/lib/bb/fetch/__init__.py
index 3333a278e1..39a8180a89 100644
--- a/bitbake/lib/bb/fetch/__init__.py
+++ b/bitbake/lib/bb/fetch/__init__.py
@@ -514,7 +514,7 @@ class Fetch(object):
514 raise ParameterError 514 raise ParameterError
515 515
516 pd = persist_data.PersistData(d) 516 pd = persist_data.PersistData(d)
517 key = self._revision_key(url, ud, d) 517 key = self.generate_revision_key(url, ud, d)
518 rev = pd.getValue("BB_URI_HEADREVS", key) 518 rev = pd.getValue("BB_URI_HEADREVS", key)
519 if rev != None: 519 if rev != None:
520 return str(rev) 520 return str(rev)
@@ -527,11 +527,13 @@ class Fetch(object):
527 """ 527 """
528 528
529 """ 529 """
530 if hasattr(self, "_sortable_revision"): 530 has_sortable = hasattr(self, "_sortable_revision")
531 if has_sortable:
531 return self._sortable_revision(url, ud, d) 532 return self._sortable_revision(url, ud, d)
532 533
533 pd = persist_data.PersistData(d) 534 pd = persist_data.PersistData(d)
534 key = self._revision_key(url, ud, d) 535 key = self.generate_revision_key(url, ud, d)
536
535 latest_rev = self._build_revision(url, ud, d) 537 latest_rev = self._build_revision(url, ud, d)
536 last_rev = pd.getValue("BB_URI_LOCALCOUNT", key + "_rev") 538 last_rev = pd.getValue("BB_URI_LOCALCOUNT", key + "_rev")
537 count = pd.getValue("BB_URI_LOCALCOUNT", key + "_count") 539 count = pd.getValue("BB_URI_LOCALCOUNT", key + "_count")
@@ -549,6 +551,9 @@ class Fetch(object):
549 551
550 return str(count + "+" + latest_rev) 552 return str(count + "+" + latest_rev)
551 553
554 def generate_revision_key(self, url, ud, d):
555 key = self._revision_key(url, ud, d)
556 return "%s-%s" % (key, bb.data.getVar("PN", d, True) or "")
552 557
553import cvs 558import cvs
554import git 559import git