summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2013-05-07 10:23:40 (GMT)
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-05-16 22:32:39 (GMT)
commitbda68e63e2b002069200b8c810225bcba109dce3 (patch)
treef3de4b522ecba538a3c881e67cc329b85e24d2ff
parent93925f7875197e08b9e91019096c196bac2f0e3f (diff)
downloadpoky-bda68e63e2b002069200b8c810225bcba109dce3.tar.gz
meta: Convert to use python3 octal syntax
(From OE-Core rev: 2502a4c65b45d02b606cb790d48b7bcf2e066366) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/base.bbclass10
-rw-r--r--meta/classes/package_rpm.bbclass6
-rw-r--r--meta/classes/sanity.bbclass4
-rw-r--r--meta/classes/sstate.bbclass6
-rw-r--r--meta/classes/terminal.bbclass2
-rw-r--r--meta/lib/oe/patch.py2
6 files changed, 15 insertions, 15 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index a7ca3a6..e5c58b1 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -453,15 +453,15 @@ python () {
453 # If we're building a target package we need to use fakeroot (pseudo) 453 # If we're building a target package we need to use fakeroot (pseudo)
454 # in order to capture permissions, owners, groups and special files 454 # in order to capture permissions, owners, groups and special files
455 if not bb.data.inherits_class('native', d) and not bb.data.inherits_class('cross', d): 455 if not bb.data.inherits_class('native', d) and not bb.data.inherits_class('cross', d):
456 d.setVarFlag('do_unpack', 'umask', '022') 456 d.setVarFlag('do_unpack', 'umask', '0o022')
457 d.setVarFlag('do_configure', 'umask', '022') 457 d.setVarFlag('do_configure', 'umask', '0o022')
458 d.setVarFlag('do_compile', 'umask', '022') 458 d.setVarFlag('do_compile', 'umask', '0o022')
459 d.appendVarFlag('do_install', 'depends', ' virtual/fakeroot-native:do_populate_sysroot') 459 d.appendVarFlag('do_install', 'depends', ' virtual/fakeroot-native:do_populate_sysroot')
460 d.setVarFlag('do_install', 'fakeroot', '1') 460 d.setVarFlag('do_install', 'fakeroot', '1')
461 d.setVarFlag('do_install', 'umask', '022') 461 d.setVarFlag('do_install', 'umask', '0o022')
462 d.appendVarFlag('do_package', 'depends', ' virtual/fakeroot-native:do_populate_sysroot') 462 d.appendVarFlag('do_package', 'depends', ' virtual/fakeroot-native:do_populate_sysroot')
463 d.setVarFlag('do_package', 'fakeroot', '1') 463 d.setVarFlag('do_package', 'fakeroot', '1')
464 d.setVarFlag('do_package', 'umask', '022') 464 d.setVarFlag('do_package', 'umask', '0o022')
465 d.setVarFlag('do_package_setscene', 'fakeroot', '1') 465 d.setVarFlag('do_package_setscene', 'fakeroot', '1')
466 d.appendVarFlag('do_package_setscene', 'depends', ' virtual/fakeroot-native:do_populate_sysroot') 466 d.appendVarFlag('do_package_setscene', 'depends', ' virtual/fakeroot-native:do_populate_sysroot')
467 d.setVarFlag('do_devshell', 'fakeroot', '1') 467 d.setVarFlag('do_devshell', 'fakeroot', '1')
diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
index 7d523a1..f9398a9 100644
--- a/meta/classes/package_rpm.bbclass
+++ b/meta/classes/package_rpm.bbclass
@@ -63,7 +63,7 @@ def write_rpm_perfiledata(srcname, d):
63 dump_filerdeps('RDEPENDS', dependsfile, d) 63 dump_filerdeps('RDEPENDS', dependsfile, d)
64 64
65 dependsfile.close() 65 dependsfile.close()
66 os.chmod(outdepends, 0755) 66 os.chmod(outdepends, 0o755)
67 67
68 # OE-core / RPM Provides 68 # OE-core / RPM Provides
69 outprovides = workdir + "/" + srcname + ".provides" 69 outprovides = workdir + "/" + srcname + ".provides"
@@ -76,7 +76,7 @@ def write_rpm_perfiledata(srcname, d):
76 dump_filerdeps('RPROVIDES', providesfile, d) 76 dump_filerdeps('RPROVIDES', providesfile, d)
77 77
78 providesfile.close() 78 providesfile.close()
79 os.chmod(outprovides, 0755) 79 os.chmod(outprovides, 0o755)
80 80
81 return (outdepends, outprovides) 81 return (outdepends, outprovides)
82 82
@@ -702,7 +702,7 @@ python do_package_rpm () {
702 pkgarch = d.expand('${PACKAGE_ARCH_EXTEND}${HOST_VENDOR}-${HOST_OS}') 702 pkgarch = d.expand('${PACKAGE_ARCH_EXTEND}${HOST_VENDOR}-${HOST_OS}')
703 magicfile = d.expand('${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc') 703 magicfile = d.expand('${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc')
704 bb.utils.mkdirhier(pkgwritedir) 704 bb.utils.mkdirhier(pkgwritedir)
705 os.chmod(pkgwritedir, 0755) 705 os.chmod(pkgwritedir, 0o755)
706 706
707 cmd = rpmbuild 707 cmd = rpmbuild
708 cmd = cmd + " --nodeps --short-circuit --target " + pkgarch + " --buildroot " + pkgd 708 cmd = cmd + " --nodeps --short-circuit --target " + pkgarch + " --buildroot " + pkgd
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 77813e4..27e061d 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -829,8 +829,8 @@ def check_sanity_everybuild(status, d):
829 829
830 check_supported_distro(d) 830 check_supported_distro(d)
831 831
832 omask = os.umask(022) 832 omask = os.umask(0o022)
833 if omask & 0755: 833 if omask & 0o755:
834 status.addresult("Please use a umask which allows a+rx and u+rwx\n") 834 status.addresult("Please use a umask which allows a+rx and u+rwx\n")
835 os.umask(omask) 835 os.umask(omask)
836 836
diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 8c62327..ab8ca6e 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -661,9 +661,9 @@ python sstate_task_postfunc () {
661 sstate_install(shared_state, d) 661 sstate_install(shared_state, d)
662 for intercept in shared_state['interceptfuncs']: 662 for intercept in shared_state['interceptfuncs']:
663 bb.build.exec_func(intercept, d, (d.getVar("WORKDIR", True),)) 663 bb.build.exec_func(intercept, d, (d.getVar("WORKDIR", True),))
664 omask = os.umask(002) 664 omask = os.umask(0o002)
665 if omask != 002: 665 if omask != 0o002:
666 bb.note("Using umask 002 (not %0o) for sstate packaging" % omask) 666 bb.note("Using umask 0o002 (not %0o) for sstate packaging" % omask)
667 sstate_package(shared_state, d) 667 sstate_package(shared_state, d)
668 os.umask(omask) 668 os.umask(omask)
669} 669}
diff --git a/meta/classes/terminal.bbclass b/meta/classes/terminal.bbclass
index 9f4c24e..a94f755 100644
--- a/meta/classes/terminal.bbclass
+++ b/meta/classes/terminal.bbclass
@@ -29,7 +29,7 @@ def emit_terminal_func(command, envdata, d):
29 bb.data.emit_func(cmd_func, script, envdata) 29 bb.data.emit_func(cmd_func, script, envdata)
30 script.write(cmd_func) 30 script.write(cmd_func)
31 script.write("\n") 31 script.write("\n")
32 os.chmod(runfile, 0755) 32 os.chmod(runfile, 0o755)
33 33
34 return runfile 34 return runfile
35 35
diff --git a/meta/lib/oe/patch.py b/meta/lib/oe/patch.py
index 9d36172..add4104 100644
--- a/meta/lib/oe/patch.py
+++ b/meta/lib/oe/patch.py
@@ -672,7 +672,7 @@ class UserResolver(Resolver):
672 f.write("echo 'Run \"quilt refresh\" when patch is corrected, press CTRL+D to exit.'\n") 672 f.write("echo 'Run \"quilt refresh\" when patch is corrected, press CTRL+D to exit.'\n")
673 f.write("echo ''\n") 673 f.write("echo ''\n")
674 f.write(" ".join(patchcmd) + "\n") 674 f.write(" ".join(patchcmd) + "\n")
675 os.chmod(rcfile, 0775) 675 os.chmod(rcfile, 00775)
676 676
677 self.terminal("bash --rcfile " + rcfile, 'Patch Rejects: Please fix patch rejects manually', self.patchset.d) 677 self.terminal("bash --rcfile " + rcfile, 'Patch Rejects: Please fix patch rejects manually', self.patchset.d)
678 678