]> code.ossystems Code Review - openembedded-core.git/commitdiff
base/sstate.bbclass: Rename fetcher "go" method to "download" when using fetch v2
authorYu Ke <ke.yu@intel.com>
Tue, 18 Jan 2011 15:17:50 +0000 (23:17 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 25 Jan 2011 12:25:47 +0000 (12:25 +0000)
Signed-off-by: Yu Ke <ke.yu@intel.com>
meta/classes/base.bbclass
meta/classes/sstate.bbclass

index ec55d4aa726471c69295ffe3361249be8595b0e9..42291557b054831d2f5ed55673e280604188d11f 100644 (file)
@@ -135,7 +135,10 @@ python base_do_fetch() {
                raise bb.build.FuncFailed("Malformed URL: %s" % value)
 
        try:
-               bb.fetch.go(localdata)
+               if bb.fetch.__version__ == "1":
+                       bb.fetch.go(localdata)
+               else:
+                       bb.fetch.download(localdata)
        except bb.fetch.MissingParameterError:
                (type, value, traceback) = sys.exc_info()
                raise bb.build.FuncFailed("Missing parameters: %s" % value)
index 807e8e39aa19062e5d5615da4e78c6351ba87441..dbe0e46b548785606e7a418bf3ab34e899918bd4 100644 (file)
@@ -344,7 +344,10 @@ def pstaging_fetch(sstatepkg, d):
         # we will build the package
         try:
             bb.fetch.init([srcuri], localdata)
-            bb.fetch.go(localdata, [srcuri])
+            if bb.fetch.__version__ == "1":
+                bb.fetch.go(localdata, [srcuri])
+            else:
+                bb.fetch.download(localdata, [srcuri])
             # Need to optimise this, if using file:// urls, the fetcher just changes the local path
             # For now work around by symlinking
             localpath = bb.data.expand(bb.fetch.localpath(srcuri, localdata), localdata)