1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-09 03:40:18 +00:00

bitbake: Update SRCREV fetcher code to cope better with multiple SCM packages

git-svn-id: https://svn.o-hand.com/repos/poky/trunk@3145 311d38ba-8fff-0310-9ca6-ca027cbcb966
This commit is contained in:
Richard Purdie
2007-11-13 23:03:21 +00:00
parent 0fa37f2d05
commit e13102cd66
3 changed files with 48 additions and 14 deletions
+10 -7
View File
@@ -50,13 +50,14 @@ class Git(Fetch):
if 'protocol' in ud.parm:
ud.proto = ud.parm['protocol']
tag = data.getVar("SRCREV", d, 1)
if 'tag' in ud.parm:
ud.tag = ud.parm['tag']
elif tag is "SRCREVINACTION":
ud.tag = self.latest_revision(url, ud, d)
else:
ud.tag = tag
tag = Fetch.srcrev_internal_helper(ud, d)
if tag is True:
ud.tag = self.latest_revision(url, ud, d)
elif tag:
ud.tag = tag
if not ud.tag:
ud.tag = self.latest_revision(url, ud, d)
if ud.tag == "master":
ud.tag = self.latest_revision(url, ud, d)
@@ -132,3 +133,5 @@ class Git(Fetch):
output = runfetchcmd("git ls-remote %s://%s%s" % (ud.proto, ud.host, ud.path), d, True)
return output.split()[0]
def _build_revision(self, url, ud, d):
return ud.tag