summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-20 11:56:05 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-02 08:24:00 +0100
commit642a997adee8f12ed640a03ead8fdd73ca0f6ab1 (patch)
tree7073db3254086641b0a33459ed897c6c5f6fab7c /meta
parent44e9a0d2fa759dea281fc32b602cd7878000c277 (diff)
downloadpoky-642a997adee8f12ed640a03ead8fdd73ca0f6ab1.tar.gz
classes/lib: Update xrange -> range for python3
xrange() no longer exists in python 3, use range() (From OE-Core rev: d022b4335100612d6596cc4c4956cb98ed5873cc) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/staging.bbclass2
-rw-r--r--meta/lib/oe/recipeutils.py4
-rw-r--r--meta/recipes-core/meta/uninative-tarball.bb2
-rwxr-xr-xmeta/recipes-rt/rt-tests/files/rt_bmark.py2
4 files changed, 5 insertions, 5 deletions
diff --git a/meta/classes/staging.bbclass b/meta/classes/staging.bbclass
index a0f82be4ab..30f2b507e1 100644
--- a/meta/classes/staging.bbclass
+++ b/meta/classes/staging.bbclass
@@ -187,7 +187,7 @@ def sysroot_checkhashes(covered, tasknames, fnids, fns, d, invalidtasks = None):
187 problems = set() 187 problems = set()
188 configurefnids = set() 188 configurefnids = set()
189 if not invalidtasks: 189 if not invalidtasks:
190 invalidtasks = xrange(len(tasknames)) 190 invalidtasks = range(len(tasknames))
191 for task in invalidtasks: 191 for task in invalidtasks:
192 if tasknames[task] == "do_configure" and task not in covered: 192 if tasknames[task] == "do_configure" and task not in covered:
193 configurefnids.add(fnids[task]) 193 configurefnids.add(fnids[task])
diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py
index 146fe83e18..632184fcd9 100644
--- a/meta/lib/oe/recipeutils.py
+++ b/meta/lib/oe/recipeutils.py
@@ -568,14 +568,14 @@ def bbappend_recipe(rd, destlayerdir, srcfiles, install=None, wildcardver=False,
568 raise Exception('Invalid extralines value passed') 568 raise Exception('Invalid extralines value passed')
569 569
570 def popline(varname): 570 def popline(varname):
571 for i in xrange(0, len(bbappendlines)): 571 for i in range(0, len(bbappendlines)):
572 if bbappendlines[i][0] == varname: 572 if bbappendlines[i][0] == varname:
573 line = bbappendlines.pop(i) 573 line = bbappendlines.pop(i)
574 return line 574 return line
575 return None 575 return None
576 576
577 def appendline(varname, op, value): 577 def appendline(varname, op, value):
578 for i in xrange(0, len(bbappendlines)): 578 for i in range(0, len(bbappendlines)):
579 item = bbappendlines[i] 579 item = bbappendlines[i]
580 if item[0] == varname: 580 if item[0] == varname:
581 bbappendlines[i] = (item[0], item[1], item[2] + ' ' + value) 581 bbappendlines[i] = (item[0], item[1], item[2] + ' ' + value)
diff --git a/meta/recipes-core/meta/uninative-tarball.bb b/meta/recipes-core/meta/uninative-tarball.bb
index a983e42c67..fb147a17f7 100644
--- a/meta/recipes-core/meta/uninative-tarball.bb
+++ b/meta/recipes-core/meta/uninative-tarball.bb
@@ -50,7 +50,7 @@ fakeroot tar_sdk() {
50 DEST="./${SDK_ARCH}-${SDK_OS}" 50 DEST="./${SDK_ARCH}-${SDK_OS}"
51 mv sysroots/${SDK_SYS} $DEST 51 mv sysroots/${SDK_SYS} $DEST
52 rm sysroots -rf 52 rm sysroots -rf
53 patchelf --set-interpreter ${@''.join('a' for n in xrange(1024))} $DEST/usr/bin/patchelf 53 patchelf --set-interpreter ${@''.join('a' for n in range(1024))} $DEST/usr/bin/patchelf
54 mv $DEST/usr/bin/patchelf $DEST/usr/bin/patchelf-uninative 54 mv $DEST/usr/bin/patchelf $DEST/usr/bin/patchelf-uninative
55 tar ${SDKTAROPTS} -c -j --file=${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.tar.bz2 . 55 tar ${SDKTAROPTS} -c -j --file=${SDK_DEPLOY}/${TOOLCHAIN_OUTPUTNAME}.tar.bz2 .
56} 56}
diff --git a/meta/recipes-rt/rt-tests/files/rt_bmark.py b/meta/recipes-rt/rt-tests/files/rt_bmark.py
index e2280e43e2..0e2b105e34 100755
--- a/meta/recipes-rt/rt-tests/files/rt_bmark.py
+++ b/meta/recipes-rt/rt-tests/files/rt_bmark.py
@@ -324,7 +324,7 @@ def run_cyclictest_suite():
324 t = time.time() 324 t = time.time()
325 max_list = [] 325 max_list = []
326 326
327 for i in xrange(0, suite_size): 327 for i in range(0, suite_size):
328 tmp_min, tmp_avg, tmp_max = run_cyclictest_once() 328 tmp_min, tmp_avg, tmp_max = run_cyclictest_once()
329 329
330 msg = "%2d/%2d:" % (i+1, suite_size) 330 msg = "%2d/%2d:" % (i+1, suite_size)