diff options
Diffstat (limited to 'meta/lib/oeqa/utils')
-rw-r--r-- | meta/lib/oeqa/utils/commands.py | 2 | ||||
-rw-r--r-- | meta/lib/oeqa/utils/dump.py | 4 | ||||
-rw-r--r-- | meta/lib/oeqa/utils/package_manager.py | 12 | ||||
-rw-r--r-- | meta/lib/oeqa/utils/targetbuild.py | 8 | ||||
-rw-r--r-- | meta/lib/oeqa/utils/testexport.py | 14 |
5 files changed, 20 insertions, 20 deletions
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index aecf8cf5a8..3a68b001b7 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py | |||
@@ -231,7 +231,7 @@ def runqemu(pn, ssh=True): | |||
231 | logger = logging.getLogger('BitBake.QemuRunner') | 231 | logger = logging.getLogger('BitBake.QemuRunner') |
232 | logger.setLevel(logging.DEBUG) | 232 | logger.setLevel(logging.DEBUG) |
233 | logger.propagate = False | 233 | logger.propagate = False |
234 | logdir = recipedata.getVar("TEST_LOG_DIR", True) | 234 | logdir = recipedata.getVar("TEST_LOG_DIR") |
235 | 235 | ||
236 | qemu = oeqa.targetcontrol.QemuTarget(recipedata) | 236 | qemu = oeqa.targetcontrol.QemuTarget(recipedata) |
237 | finally: | 237 | finally: |
diff --git a/meta/lib/oeqa/utils/dump.py b/meta/lib/oeqa/utils/dump.py index 71422a9aea..44037a989d 100644 --- a/meta/lib/oeqa/utils/dump.py +++ b/meta/lib/oeqa/utils/dump.py | |||
@@ -6,8 +6,8 @@ import itertools | |||
6 | from .commands import runCmd | 6 | from .commands import runCmd |
7 | 7 | ||
8 | def get_host_dumper(d): | 8 | def get_host_dumper(d): |
9 | cmds = d.getVar("testimage_dump_host", True) | 9 | cmds = d.getVar("testimage_dump_host") |
10 | parent_dir = d.getVar("TESTIMAGE_DUMP_DIR", True) | 10 | parent_dir = d.getVar("TESTIMAGE_DUMP_DIR") |
11 | return HostDumper(cmds, parent_dir) | 11 | return HostDumper(cmds, parent_dir) |
12 | 12 | ||
13 | 13 | ||
diff --git a/meta/lib/oeqa/utils/package_manager.py b/meta/lib/oeqa/utils/package_manager.py index 099ecc9728..0f6bdbc542 100644 --- a/meta/lib/oeqa/utils/package_manager.py +++ b/meta/lib/oeqa/utils/package_manager.py | |||
@@ -4,24 +4,24 @@ def get_package_manager(d, root_path): | |||
4 | """ | 4 | """ |
5 | from oe.package_manager import RpmPM, OpkgPM, DpkgPM | 5 | from oe.package_manager import RpmPM, OpkgPM, DpkgPM |
6 | 6 | ||
7 | pkg_class = d.getVar("IMAGE_PKGTYPE", True) | 7 | pkg_class = d.getVar("IMAGE_PKGTYPE") |
8 | if pkg_class == "rpm": | 8 | if pkg_class == "rpm": |
9 | pm = RpmPM(d, | 9 | pm = RpmPM(d, |
10 | root_path, | 10 | root_path, |
11 | d.getVar('TARGET_VENDOR', True)) | 11 | d.getVar('TARGET_VENDOR')) |
12 | pm.create_configs() | 12 | pm.create_configs() |
13 | 13 | ||
14 | elif pkg_class == "ipk": | 14 | elif pkg_class == "ipk": |
15 | pm = OpkgPM(d, | 15 | pm = OpkgPM(d, |
16 | root_path, | 16 | root_path, |
17 | d.getVar("IPKGCONF_TARGET", True), | 17 | d.getVar("IPKGCONF_TARGET"), |
18 | d.getVar("ALL_MULTILIB_PACKAGE_ARCHS", True)) | 18 | d.getVar("ALL_MULTILIB_PACKAGE_ARCHS")) |
19 | 19 | ||
20 | elif pkg_class == "deb": | 20 | elif pkg_class == "deb": |
21 | pm = DpkgPM(d, | 21 | pm = DpkgPM(d, |
22 | root_path, | 22 | root_path, |
23 | d.getVar('PACKAGE_ARCHS', True), | 23 | d.getVar('PACKAGE_ARCHS'), |
24 | d.getVar('DPKG_ARCH', True)) | 24 | d.getVar('DPKG_ARCH')) |
25 | 25 | ||
26 | pm.write_index() | 26 | pm.write_index() |
27 | pm.update() | 27 | pm.update() |
diff --git a/meta/lib/oeqa/utils/targetbuild.py b/meta/lib/oeqa/utils/targetbuild.py index 59593f5ef3..c001602b54 100644 --- a/meta/lib/oeqa/utils/targetbuild.py +++ b/meta/lib/oeqa/utils/targetbuild.py | |||
@@ -25,7 +25,7 @@ class BuildProject(metaclass=ABCMeta): | |||
25 | # Download self.archive to self.localarchive | 25 | # Download self.archive to self.localarchive |
26 | def _download_archive(self): | 26 | def _download_archive(self): |
27 | 27 | ||
28 | dl_dir = self.d.getVar("DL_DIR", True) | 28 | dl_dir = self.d.getVar("DL_DIR") |
29 | if dl_dir and os.path.exists(os.path.join(dl_dir, self.archive)): | 29 | if dl_dir and os.path.exists(os.path.join(dl_dir, self.archive)): |
30 | bb.utils.copyfile(os.path.join(dl_dir, self.archive), self.localarchive) | 30 | bb.utils.copyfile(os.path.join(dl_dir, self.archive), self.localarchive) |
31 | return | 31 | return |
@@ -40,7 +40,7 @@ class BuildProject(metaclass=ABCMeta): | |||
40 | 40 | ||
41 | cmd = '' | 41 | cmd = '' |
42 | for var in exportvars: | 42 | for var in exportvars: |
43 | val = self.d.getVar(var, True) | 43 | val = self.d.getVar(var) |
44 | if val: | 44 | if val: |
45 | cmd = 'export ' + var + '=\"%s\"; %s' % (val, cmd) | 45 | cmd = 'export ' + var + '=\"%s\"; %s' % (val, cmd) |
46 | 46 | ||
@@ -103,8 +103,8 @@ class SDKBuildProject(BuildProject): | |||
103 | self.testdir = testpath | 103 | self.testdir = testpath |
104 | self.targetdir = testpath | 104 | self.targetdir = testpath |
105 | bb.utils.mkdirhier(testpath) | 105 | bb.utils.mkdirhier(testpath) |
106 | self.datetime = d.getVar('DATETIME', True) | 106 | self.datetime = d.getVar('DATETIME') |
107 | self.testlogdir = d.getVar("TEST_LOG_DIR", True) | 107 | self.testlogdir = d.getVar("TEST_LOG_DIR") |
108 | bb.utils.mkdirhier(self.testlogdir) | 108 | bb.utils.mkdirhier(self.testlogdir) |
109 | self.logfile = os.path.join(self.testlogdir, "sdk_target_log.%s" % self.datetime) | 109 | self.logfile = os.path.join(self.testlogdir, "sdk_target_log.%s" % self.datetime) |
110 | BuildProject.__init__(self, d, uri, foldername, tmpdir=testpath) | 110 | BuildProject.__init__(self, d, uri, foldername, tmpdir=testpath) |
diff --git a/meta/lib/oeqa/utils/testexport.py b/meta/lib/oeqa/utils/testexport.py index 57be2ca449..be2a2110fc 100644 --- a/meta/lib/oeqa/utils/testexport.py +++ b/meta/lib/oeqa/utils/testexport.py | |||
@@ -72,9 +72,9 @@ def process_binaries(d, params): | |||
72 | return extract_bin_command | 72 | return extract_bin_command |
73 | 73 | ||
74 | if determine_if_poky_env(): # machine with poky environment | 74 | if determine_if_poky_env(): # machine with poky environment |
75 | exportpath = d.getVar("TEST_EXPORT_DIR", True) if export_env else d.getVar("DEPLOY_DIR", True) | 75 | exportpath = d.getVar("TEST_EXPORT_DIR") if export_env else d.getVar("DEPLOY_DIR") |
76 | rpm_deploy_dir = d.getVar("DEPLOY_DIR_RPM", True) | 76 | rpm_deploy_dir = d.getVar("DEPLOY_DIR_RPM") |
77 | arch = get_dest_folder(d.getVar("TUNE_FEATURES", True), os.listdir(rpm_deploy_dir)) | 77 | arch = get_dest_folder(d.getVar("TUNE_FEATURES"), os.listdir(rpm_deploy_dir)) |
78 | arch_rpm_dir = os.path.join(rpm_deploy_dir, arch) | 78 | arch_rpm_dir = os.path.join(rpm_deploy_dir, arch) |
79 | extracted_bin_dir = os.path.join(exportpath,"binaries", arch, "extracted_binaries") | 79 | extracted_bin_dir = os.path.join(exportpath,"binaries", arch, "extracted_binaries") |
80 | packaged_bin_dir = os.path.join(exportpath,"binaries", arch, "packaged_binaries") | 80 | packaged_bin_dir = os.path.join(exportpath,"binaries", arch, "packaged_binaries") |
@@ -92,7 +92,7 @@ def process_binaries(d, params): | |||
92 | return "" | 92 | return "" |
93 | for item in native_rpm_file_list:# will copy all versions of package. Used version will be selected on remote machine | 93 | for item in native_rpm_file_list:# will copy all versions of package. Used version will be selected on remote machine |
94 | bb.plain("Copying native package file: %s" % item) | 94 | bb.plain("Copying native package file: %s" % item) |
95 | sh.copy(os.path.join(rpm_deploy_dir, native_rpm_dir, item), os.path.join(d.getVar("TEST_EXPORT_DIR", True), "binaries", "native")) | 95 | sh.copy(os.path.join(rpm_deploy_dir, native_rpm_dir, item), os.path.join(d.getVar("TEST_EXPORT_DIR"), "binaries", "native")) |
96 | else: # nothing to do here; running tests under bitbake, so we asume native binaries are in sysroots dir. | 96 | else: # nothing to do here; running tests under bitbake, so we asume native binaries are in sysroots dir. |
97 | if param_list[1] or param_list[4]: | 97 | if param_list[1] or param_list[4]: |
98 | bb.warn("Native binary %s %s%s. Running tests under bitbake environment. Version can't be checked except when the test itself does it" | 98 | bb.warn("Native binary %s %s%s. Running tests under bitbake environment. Version can't be checked except when the test itself does it" |
@@ -148,7 +148,7 @@ def process_binaries(d, params): | |||
148 | else: # this is for target device | 148 | else: # this is for target device |
149 | if param_list[2] == "rpm": | 149 | if param_list[2] == "rpm": |
150 | return "No need to extract, this is an .rpm file" | 150 | return "No need to extract, this is an .rpm file" |
151 | arch = get_dest_folder(d.getVar("TUNE_FEATURES", True), os.listdir(binaries_path)) | 151 | arch = get_dest_folder(d.getVar("TUNE_FEATURES"), os.listdir(binaries_path)) |
152 | extracted_bin_path = os.path.join(binaries_path, arch, "extracted_binaries") | 152 | extracted_bin_path = os.path.join(binaries_path, arch, "extracted_binaries") |
153 | extracted_bin_list = [item for item in os.listdir(extracted_bin_path)] | 153 | extracted_bin_list = [item for item in os.listdir(extracted_bin_path)] |
154 | packaged_bin_path = os.path.join(binaries_path, arch, "packaged_binaries") | 154 | packaged_bin_path = os.path.join(binaries_path, arch, "packaged_binaries") |
@@ -206,9 +206,9 @@ def send_bin_to_DUT(d,params): | |||
206 | from oeqa.oetest import oeRuntimeTest | 206 | from oeqa.oetest import oeRuntimeTest |
207 | param_list = params | 207 | param_list = params |
208 | cleanup_list = list() | 208 | cleanup_list = list() |
209 | bins_dir = os.path.join(d.getVar("TEST_EXPORT_DIR", True), "binaries") if determine_if_poky_env() \ | 209 | bins_dir = os.path.join(d.getVar("TEST_EXPORT_DIR"), "binaries") if determine_if_poky_env() \ |
210 | else os.getenv("bin_dir") | 210 | else os.getenv("bin_dir") |
211 | arch = get_dest_folder(d.getVar("TUNE_FEATURES", True), os.listdir(bins_dir)) | 211 | arch = get_dest_folder(d.getVar("TUNE_FEATURES"), os.listdir(bins_dir)) |
212 | arch_rpms_dir = os.path.join(bins_dir, arch, "packaged_binaries") | 212 | arch_rpms_dir = os.path.join(bins_dir, arch, "packaged_binaries") |
213 | extracted_bin_dir = os.path.join(bins_dir, arch, "extracted_binaries", param_list[0]) | 213 | extracted_bin_dir = os.path.join(bins_dir, arch, "extracted_binaries", param_list[0]) |
214 | 214 | ||