summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorAlexandru Vasiu <alexandru.vasiu@ni.com>2018-08-27 17:31:04 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-08-29 10:42:48 +0100
commit0dc9785c08939f3daa9d66741a4bb39f9fcc5fc8 (patch)
treeae5b6f7624927b52a59820a49929f66bcaa82bae /scripts
parent87943f2fe0d091e83061fe94a800fba9b7a44175 (diff)
downloadpoky-0dc9785c08939f3daa9d66741a4bb39f9fcc5fc8.tar.gz
isoimage-isohybrid: Fix variable names
initrd.cpio is created in initrd_dir, not in cr_workdir. Gzip will let initrd.cpio uncompressed if the path is not found. Also, grub_image variable doesn't exist, grub_src_image should be used instead. (From OE-Core rev: c88875b568a66297b1d3df380c590f20796c57f6) Signed-off-by: Alexandru Vasiu <alexandru.vasiu@ni.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/wic/plugins/source/isoimage-isohybrid.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/lib/wic/plugins/source/isoimage-isohybrid.py b/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
index 4a0a57ef9e..25a695da17 100644
--- a/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
+++ b/scripts/lib/wic/plugins/source/isoimage-isohybrid.py
@@ -194,7 +194,7 @@ class IsoImagePlugin(SourcePlugin):
194 exec_cmd("cd %s && find . | cpio -o -H newc -R root:root >./initrd.cpio " \ 194 exec_cmd("cd %s && find . | cpio -o -H newc -R root:root >./initrd.cpio " \
195 % initrd_dir, as_shell=True) 195 % initrd_dir, as_shell=True)
196 exec_cmd("gzip -f -9 -c %s/initrd.cpio > %s" \ 196 exec_cmd("gzip -f -9 -c %s/initrd.cpio > %s" \
197 % (cr_workdir, initrd), as_shell=True) 197 % (initrd_dir, initrd), as_shell=True)
198 shutil.rmtree(initrd_dir) 198 shutil.rmtree(initrd_dir)
199 199
200 return initrd 200 return initrd
@@ -317,7 +317,7 @@ class IsoImagePlugin(SourcePlugin):
317 grub_src = os.path.join(deploy_dir, grub_src_image) 317 grub_src = os.path.join(deploy_dir, grub_src_image)
318 if not os.path.exists(grub_src): 318 if not os.path.exists(grub_src):
319 raise WicError("Grub loader %s is not found in %s. " 319 raise WicError("Grub loader %s is not found in %s. "
320 "Please build grub-efi first" % (grub_image, deploy_dir)) 320 "Please build grub-efi first" % (grub_src_image, deploy_dir))
321 shutil.copy(grub_src, grub_target) 321 shutil.copy(grub_src, grub_target)
322 322
323 if not os.path.isfile(os.path.join(target_dir, "boot.cfg")): 323 if not os.path.isfile(os.path.join(target_dir, "boot.cfg")):