bitbake: fetch2/__init__.py: Warn user if SRC_URI is using "proto" and not "protocol"

As well, if "proto" is used, get the associated value as "protocol"

(Bitbake rev: 53e6b630f0463d2d07cdaa9c9eb36794dc9b6b69)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Andrei Gherzan 2012-07-11 00:34:17 +03:00 committed by Richard Purdie
parent c26f6b2b94
commit a3a697c425
1 changed files with 4 additions and 0 deletions

View File

@ -755,6 +755,10 @@ class FetchData(object):
if localonly and not isinstance(self.method, local.Local):
raise NonLocalMethod()
if self.parm.get("proto", None) and "protocol" not in self.parm:
logger.warn('Consider updating %s recipe to use "protocol" not "proto" in SRC_URI.', d.getVar('PN', True))
self.parm["protocol"] = self.parm.get("proto", None)
if hasattr(self.method, "urldata_init"):
self.method.urldata_init(self, d)