diff options
author | Ed Bartosh <ed.bartosh@linux.intel.com> | 2015-04-15 23:47:10 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-04-24 11:06:55 +0100 |
commit | f2a0a985236af116a84cc62a4f7e1d4707aea6e9 (patch) | |
tree | 781ff0e7990d38b314d9bea34a02abf085ff453d /scripts/lib/image/engine.py | |
parent | 1d0c3387e8881a7a372ee38c0944540ce2ac8bc5 (diff) | |
download | poky-f2a0a985236af116a84cc62a4f7e1d4707aea6e9.tar.gz |
wic: code cleanup: wildcard imports
Here is what PEP8(Style Guide for Python Code) says about this:
Wildcard imports (from <module> import *) should be avoided, as they
make it unclear which names are present in the namespace, confusing
both readers and many automated tools.
(From OE-Core rev: 13416c1941f5dc8abcdb0073f2104a89eae2d6f1)
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/image/engine.py')
-rw-r--r-- | scripts/lib/image/engine.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/scripts/lib/image/engine.py b/scripts/lib/image/engine.py index 68d1ce2659..05c26386e7 100644 --- a/scripts/lib/image/engine.py +++ b/scripts/lib/image/engine.py | |||
@@ -42,7 +42,7 @@ from wic.utils import cmdln, misc, errors | |||
42 | from wic.conf import configmgr | 42 | from wic.conf import configmgr |
43 | from wic.plugin import pluginmgr | 43 | from wic.plugin import pluginmgr |
44 | from wic.__version__ import VERSION | 44 | from wic.__version__ import VERSION |
45 | from wic.utils.oe.misc import * | 45 | from wic.utils.oe import misc |
46 | 46 | ||
47 | 47 | ||
48 | def verify_build_env(): | 48 | def verify_build_env(): |
@@ -65,19 +65,19 @@ def find_artifacts(image_name): | |||
65 | Gather the build artifacts for the current image (the image_name | 65 | Gather the build artifacts for the current image (the image_name |
66 | e.g. core-image-minimal) for the current MACHINE set in local.conf | 66 | e.g. core-image-minimal) for the current MACHINE set in local.conf |
67 | """ | 67 | """ |
68 | bitbake_env_lines = get_bitbake_env_lines() | 68 | bitbake_env_lines = misc.get_bitbake_env_lines() |
69 | 69 | ||
70 | rootfs_dir = kernel_dir = bootimg_dir = native_sysroot = "" | 70 | rootfs_dir = kernel_dir = bootimg_dir = native_sysroot = "" |
71 | 71 | ||
72 | for line in bitbake_env_lines.split('\n'): | 72 | for line in bitbake_env_lines.split('\n'): |
73 | if (get_line_val(line, "IMAGE_ROOTFS")): | 73 | if (misc.get_line_val(line, "IMAGE_ROOTFS")): |
74 | rootfs_dir = get_line_val(line, "IMAGE_ROOTFS") | 74 | rootfs_dir = misc.get_line_val(line, "IMAGE_ROOTFS") |
75 | continue | 75 | continue |
76 | if (get_line_val(line, "DEPLOY_DIR_IMAGE")): | 76 | if (misc.get_line_val(line, "DEPLOY_DIR_IMAGE")): |
77 | kernel_dir = get_line_val(line, "DEPLOY_DIR_IMAGE") | 77 | kernel_dir = misc.get_line_val(line, "DEPLOY_DIR_IMAGE") |
78 | continue | 78 | continue |
79 | if (get_line_val(line, "STAGING_DIR_NATIVE")): | 79 | if (misc.get_line_val(line, "STAGING_DIR_NATIVE")): |
80 | native_sysroot = get_line_val(line, "STAGING_DIR_NATIVE") | 80 | native_sysroot = misc.get_line_val(line, "STAGING_DIR_NATIVE") |
81 | continue | 81 | continue |
82 | 82 | ||
83 | return (rootfs_dir, kernel_dir, bootimg_dir, native_sysroot) | 83 | return (rootfs_dir, kernel_dir, bootimg_dir, native_sysroot) |
@@ -87,7 +87,7 @@ CANNED_IMAGE_DIR = "lib/image/canned-wks" # relative to scripts | |||
87 | SCRIPTS_CANNED_IMAGE_DIR = "scripts/" + CANNED_IMAGE_DIR | 87 | SCRIPTS_CANNED_IMAGE_DIR = "scripts/" + CANNED_IMAGE_DIR |
88 | 88 | ||
89 | def build_canned_image_list(dl): | 89 | def build_canned_image_list(dl): |
90 | layers_path = get_bitbake_var("BBLAYERS") | 90 | layers_path = misc.get_bitbake_var("BBLAYERS") |
91 | canned_wks_layer_dirs = [] | 91 | canned_wks_layer_dirs = [] |
92 | 92 | ||
93 | if layers_path is not None: | 93 | if layers_path is not None: |