diff options
Diffstat (limited to 'bitbake/lib/bb/fetch')
-rw-r--r-- | bitbake/lib/bb/fetch/git.py | 5 | ||||
-rw-r--r-- | bitbake/lib/bb/fetch/wget.py | 6 |
2 files changed, 7 insertions, 4 deletions
diff --git a/bitbake/lib/bb/fetch/git.py b/bitbake/lib/bb/fetch/git.py index 21259a23b..9cc7f4e08 100644 --- a/bitbake/lib/bb/fetch/git.py +++ b/bitbake/lib/bb/fetch/git.py @@ -50,6 +50,8 @@ class Git(Fetch): if 'protocol' in ud.parm: ud.proto = ud.parm['protocol'] + ud.branch = ud.parm.get("branch", "") + tag = Fetch.srcrev_internal_helper(ud, d) if tag is True: ud.tag = self.latest_revision(url, ud, d) @@ -130,7 +132,8 @@ class Git(Fetch): def _latest_revision(self, url, ud, d): - output = runfetchcmd("git ls-remote %s://%s%s" % (ud.proto, ud.host, ud.path), d, True) + bb.msg.note(1, bb.msg.domain.Fetcher, "Calling git ls-remote %s://%s%s %s" % (ud.proto, ud.host, ud.path, ud.branch ) ) + output = runfetchcmd("git ls-remote %s://%s%s %s" % (ud.proto, ud.host, ud.path, ud.branch), d, True) return output.split()[0] def _build_revision(self, url, ud, d): diff --git a/bitbake/lib/bb/fetch/wget.py b/bitbake/lib/bb/fetch/wget.py index 2d590ad0b..f8ade45da 100644 --- a/bitbake/lib/bb/fetch/wget.py +++ b/bitbake/lib/bb/fetch/wget.py @@ -66,10 +66,10 @@ class Wget(Fetch): if ret != 0: return False - # check if sourceforge did send us to the mirror page + # Sanity check since wget can pretend it succeed when it didn't + # Also, this used to happen if sourceforge sent us to the mirror page if not os.path.exists(ud.localpath): - os.system("rm %s*" % ud.localpath) # FIXME shell quote it - bb.msg.debug(2, bb.msg.domain.Fetcher, "sourceforge.net send us to the mirror on %s" % ud.basename) + bb.msg.debug(2, bb.msg.domain.Fetcher, "The fetch command for %s returned success but %s doesn't exist?..." % (uri, ud.localpath)) return False return True |