diff options
Diffstat (limited to 'import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py')
-rw-r--r-- | import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py b/import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py index 295abf953b..2b4f7d9c13 100644 --- a/import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py +++ b/import-layers/yocto-poky/bitbake/lib/bb/fetch2/osc.py @@ -10,7 +10,6 @@ import os import sys import logging import bb -from bb import data from bb.fetch2 import FetchMethod from bb.fetch2 import FetchError from bb.fetch2 import MissingParameterError @@ -34,7 +33,7 @@ class Osc(FetchMethod): # Create paths to osc checkouts relpath = self._strip_leading_slashes(ud.path) - ud.pkgdir = os.path.join(d.getVar('OSCDIR', True), ud.host) + ud.pkgdir = os.path.join(d.getVar('OSCDIR'), ud.host) ud.moddir = os.path.join(ud.pkgdir, relpath, ud.module) if 'rev' in ud.parm: @@ -47,7 +46,7 @@ class Osc(FetchMethod): else: ud.revision = "" - ud.localfile = data.expand('%s_%s_%s.tar.gz' % (ud.module.replace('/', '.'), ud.path.replace('/', '.'), ud.revision), d) + ud.localfile = d.expand('%s_%s_%s.tar.gz' % (ud.module.replace('/', '.'), ud.path.replace('/', '.'), ud.revision)) def _buildosccommand(self, ud, d, command): """ @@ -55,7 +54,7 @@ class Osc(FetchMethod): command is "fetch", "update", "info" """ - basecmd = data.expand('${FETCHCMD_osc}', d) + basecmd = d.expand('${FETCHCMD_osc}') proto = ud.parm.get('protocol', 'ocs') @@ -84,7 +83,7 @@ class Osc(FetchMethod): logger.debug(2, "Fetch: checking for module directory '" + ud.moddir + "'") - if os.access(os.path.join(d.getVar('OSCDIR', True), ud.path, ud.module), os.R_OK): + if os.access(os.path.join(d.getVar('OSCDIR'), ud.path, ud.module), os.R_OK): oscupdatecmd = self._buildosccommand(ud, d, "update") logger.info("Update "+ ud.url) # update sources there @@ -112,7 +111,7 @@ class Osc(FetchMethod): Generate a .oscrc to be used for this run. """ - config_path = os.path.join(d.getVar('OSCDIR', True), "oscrc") + config_path = os.path.join(d.getVar('OSCDIR'), "oscrc") if (os.path.exists(config_path)): os.remove(config_path) @@ -121,8 +120,8 @@ class Osc(FetchMethod): f.write("apisrv = %s\n" % ud.host) f.write("scheme = http\n") f.write("su-wrapper = su -c\n") - f.write("build-root = %s\n" % d.getVar('WORKDIR', True)) - f.write("urllist = %s\n" % d.getVar("OSCURLLIST", True)) + f.write("build-root = %s\n" % d.getVar('WORKDIR')) + f.write("urllist = %s\n" % d.getVar("OSCURLLIST")) f.write("extra-pkgs = gzip\n") f.write("\n") f.write("[%s]\n" % ud.host) |