[yocto] [auh][PATCH 14/21] upgradehelper.py: do not include absolute paths in the generated tarball

Alexander Kanavin alexander.kanavin at linux.intel.com
Thu Dec 21 08:27:22 PST 2017


Signed-off-by: Alexander Kanavin <alexander.kanavin at linux.intel.com>
---
 upgradehelper.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/upgradehelper.py b/upgradehelper.py
index 9110efc..cb48c47 100755
--- a/upgradehelper.py
+++ b/upgradehelper.py
@@ -555,9 +555,11 @@ class Updater(object):
                     os.path.basename(self.uh_work_dir) + '.tar.gz')
             if publish_work_url:
                 I(" Generating work tarball in %s ..." % work_tarball)
+                tar_cmd = ["tar", "-chzf", work_tarball, "-C", self.uh_base_work_dir, os.path.basename(self.uh_work_dir)]
                 import subprocess
-                if subprocess.call(["tar", "-chzf", work_tarball, self.uh_work_dir]):
+                if subprocess.call(tar_cmd):
                     E(" Work tarball (%s) generation failed..." % (work_tarball))
+                    E(" Tar command: %s" % (" ".join(tar_cmd)))
                     publish_work_url = ''
 
             statistics_summary = self.statistics.get_summary(
-- 
2.15.1




More information about the yocto mailing list