Patchwork [bitbake-devel,2/5] fetch2/git.py: Use "protocol" parameter and warn user if recipe is using "proto"

login
register
mail settings
Submitter Andrei Gherzan
Date July 10, 2012, 11:16 a.m.
Message ID <9de1c29dc2b30bfd841529381b5419455ebde4de.1341918809.git.andrei@gherzan.ro>
Download mbox | patch
Permalink /patch/31611/
State New
Headers show

Comments

Andrei Gherzan - July 10, 2012, 11:16 a.m.
If SRC_URI uses the parameter "proto" while specifying the protocol, use this
value but warn the user about this problem.

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
---
 bitbake/lib/bb/fetch2/git.py |    4 ++++
 1 file changed, 4 insertions(+)

Patch

diff --git a/bitbake/lib/bb/fetch2/git.py b/bitbake/lib/bb/fetch2/git.py
index 384007c..354f3b1 100644
--- a/bitbake/lib/bb/fetch2/git.py
+++ b/bitbake/lib/bb/fetch2/git.py
@@ -92,6 +92,10 @@  class Git(FetchMethod):
         """
         if 'protocol' in ud.parm:
             ud.proto = ud.parm['protocol']
+        elif 'proto' in ud.parm:
+            logger.warn('Update %s recipe to use "protocol" not "proto".', d.getVar('PN', True))
+            # Use proto value for now
+            ud.proto = ud.parm['proto']
         elif not ud.host:
             ud.proto = 'file'
         else: