summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorTom Zanussi <tom.zanussi@linux.intel.com>2014-10-29 17:04:22 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-10-30 13:03:41 +0000
commit38400617febd61a1594969c86a6f1712a9d80516 (patch)
tree1d1894aec294a639489730ed7b1c971a8d5e8e7e /scripts
parentd1f8b8f5d010358d2f3b290f11b062cb0010fa1d (diff)
downloadpoky-38400617febd61a1594969c86a6f1712a9d80516.tar.gz
Revert "wic: set bootimg_dir when using image-name artifacts"
This reverts commit 7ce1dc13f91df70e8a2f420e7c3eba51cbc4bd48. This patch broke the assumption that a non-null boot_dir means a user-assigned (-b command-line param) value. Reverting doesn't break anything, since the case it was added for doesn't use the boot_dir for anything except debugging anyhow. Fixes [YOCTO #6290] (From OE-Core rev: db90f10bf31dec8d7d7bb2d3680d50e133662850) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/lib/image/engine.py9
-rwxr-xr-xscripts/wic7
2 files changed, 5 insertions, 11 deletions
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py
index 3813fec609..f1df8b4db8 100644
--- a/scripts/lib/image/engine.py
+++ b/scripts/lib/image/engine.py
@@ -67,8 +67,7 @@ def find_artifacts(image_name):
67 """ 67 """
68 bitbake_env_lines = get_bitbake_env_lines() 68 bitbake_env_lines = get_bitbake_env_lines()
69 69
70 rootfs_dir = kernel_dir = bootimg_dir = "" 70 rootfs_dir = kernel_dir = hdddir = staging_data_dir = native_sysroot = ""
71 hdddir = staging_data_dir = native_sysroot = ""
72 71
73 for line in bitbake_env_lines.split('\n'): 72 for line in bitbake_env_lines.split('\n'):
74 if (get_line_val(line, "IMAGE_ROOTFS")): 73 if (get_line_val(line, "IMAGE_ROOTFS")):
@@ -86,12 +85,8 @@ def find_artifacts(image_name):
86 if (get_line_val(line, "STAGING_DIR_NATIVE")): 85 if (get_line_val(line, "STAGING_DIR_NATIVE")):
87 native_sysroot = get_line_val(line, "STAGING_DIR_NATIVE") 86 native_sysroot = get_line_val(line, "STAGING_DIR_NATIVE")
88 continue 87 continue
89 if (get_line_val(line, "DEPLOY_DIR_IMAGE")):
90 bootimg_dir = get_line_val(line, "DEPLOY_DIR_IMAGE")
91 continue
92 88
93 return (rootfs_dir, kernel_dir, bootimg_dir, hdddir, staging_data_dir, \ 89 return (rootfs_dir, kernel_dir, hdddir, staging_data_dir, native_sysroot)
94 native_sysroot)
95 90
96 91
97CANNED_IMAGE_DIR = "lib/image/canned-wks" # relative to scripts 92CANNED_IMAGE_DIR = "lib/image/canned-wks" # relative to scripts
diff --git a/scripts/wic b/scripts/wic
index 731481007c..15cc9b31ef 100755
--- a/scripts/wic
+++ b/scripts/wic
@@ -134,8 +134,8 @@ def wic_create_subcommand(args, usage_str):
134 bootimg_dir = staging_data_dir = hdddir = "" 134 bootimg_dir = staging_data_dir = hdddir = ""
135 135
136 if options.image_name: 136 if options.image_name:
137 (rootfs_dir, kernel_dir, bootimg_dir, hdddir, \ 137 (rootfs_dir, kernel_dir, hdddir, staging_data_dir, native_sysroot) = \
138 staging_data_dir, native_sysroot) = find_artifacts(options.image_name) 138 find_artifacts(options.image_name)
139 139
140 wks_file = args[0] 140 wks_file = args[0]
141 141
@@ -172,8 +172,7 @@ def wic_create_subcommand(args, usage_str):
172 not_found = not_found_dir = "" 172 not_found = not_found_dir = ""
173 if not os.path.isdir(rootfs_dir): 173 if not os.path.isdir(rootfs_dir):
174 (not_found, not_found_dir) = ("rootfs-dir", rootfs_dir) 174 (not_found, not_found_dir) = ("rootfs-dir", rootfs_dir)
175 elif not os.path.isdir(bootimg_dir) and not os.path.isdir(hdddir) \ 175 elif not os.path.isdir(hdddir) and not os.path.isdir(staging_data_dir):
176 and not os.path.isdir(staging_data_dir):
177 (not_found, not_found_dir) = ("bootimg-dir", bootimg_dir) 176 (not_found, not_found_dir) = ("bootimg-dir", bootimg_dir)
178 elif not os.path.isdir(kernel_dir): 177 elif not os.path.isdir(kernel_dir):
179 (not_found, not_found_dir) = ("kernel-dir", kernel_dir) 178 (not_found, not_found_dir) = ("kernel-dir", kernel_dir)