summaryrefslogtreecommitdiffstats
path: root/meta/classes/package_tar.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/package_tar.bbclass')
-rw-r--r--meta/classes/package_tar.bbclass5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/classes/package_tar.bbclass b/meta/classes/package_tar.bbclass
index 854e645286..e217814af4 100644
--- a/meta/classes/package_tar.bbclass
+++ b/meta/classes/package_tar.bbclass
@@ -4,6 +4,9 @@ IMAGE_PKGTYPE ?= "tar"
4 4
5python do_package_tar () { 5python do_package_tar () {
6 import subprocess 6 import subprocess
7
8 oldcwd = os.getcwd()
9
7 workdir = d.getVar('WORKDIR', True) 10 workdir = d.getVar('WORKDIR', True)
8 if not workdir: 11 if not workdir:
9 bb.error("WORKDIR not defined, unable to package") 12 bb.error("WORKDIR not defined, unable to package")
@@ -49,6 +52,8 @@ python do_package_tar () {
49 ret = subprocess.call(args + [tarfn] + dlist) 52 ret = subprocess.call(args + [tarfn] + dlist)
50 if ret != 0: 53 if ret != 0:
51 bb.error("Creation of tar %s failed." % tarfn) 54 bb.error("Creation of tar %s failed." % tarfn)
55
56 os.chdir(oldcwd)
52} 57}
53 58
54python () { 59python () {