diff options
Diffstat (limited to 'meta/lib/oeqa/runtime/multilib.py')
-rw-r--r-- | meta/lib/oeqa/runtime/multilib.py | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/meta/lib/oeqa/runtime/multilib.py b/meta/lib/oeqa/runtime/multilib.py deleted file mode 100644 index 5cce24f5f4..0000000000 --- a/meta/lib/oeqa/runtime/multilib.py +++ /dev/null | |||
@@ -1,42 +0,0 @@ | |||
1 | import unittest | ||
2 | from oeqa.oetest import oeRuntimeTest, skipModule | ||
3 | from oeqa.utils.decorators import * | ||
4 | |||
5 | def setUpModule(): | ||
6 | multilibs = oeRuntimeTest.tc.d.getVar("MULTILIBS") or "" | ||
7 | if "multilib:lib32" not in multilibs: | ||
8 | skipModule("this isn't a multilib:lib32 image") | ||
9 | |||
10 | |||
11 | class MultilibTest(oeRuntimeTest): | ||
12 | |||
13 | def archtest(self, binary, arch): | ||
14 | """ | ||
15 | Check that ``binary`` has the ELF class ``arch`` (e.g. ELF32/ELF64). | ||
16 | """ | ||
17 | |||
18 | (status, output) = self.target.run("readelf -h %s" % binary) | ||
19 | self.assertEqual(status, 0, "Failed to readelf %s" % binary) | ||
20 | |||
21 | l = [l.split()[1] for l in output.split('\n') if "Class:" in l] | ||
22 | if l: | ||
23 | theclass = l[0] | ||
24 | else: | ||
25 | self.fail("Cannot parse readelf output\n" + s) | ||
26 | |||
27 | self.assertEqual(theclass, arch, msg="%s isn't %s (is %s)" % (binary, arch, theclass)) | ||
28 | |||
29 | @skipUnlessPassed('test_ssh') | ||
30 | def test_check_multilib_libc(self): | ||
31 | """ | ||
32 | Check that a multilib image has both 32-bit and 64-bit libc in. | ||
33 | """ | ||
34 | self.archtest("/lib/libc.so.6", "ELF32") | ||
35 | self.archtest("/lib64/libc.so.6", "ELF64") | ||
36 | |||
37 | @testcase('279') | ||
38 | @skipUnlessPassed('test_check_multilib_libc') | ||
39 | def test_file_connman(self): | ||
40 | self.assertTrue(oeRuntimeTest.hasPackage('lib32-connman'), msg="This test assumes lib32-connman is installed") | ||
41 | |||
42 | self.archtest("/usr/sbin/connmand", "ELF32") | ||