diff options
-rw-r--r-- | meta/lib/oeqa/selftest/cases/pkgdata.py | 9 | ||||
-rw-r--r-- | meta/recipes-core/zlib/zlib_1.2.12.bb | 12 |
2 files changed, 4 insertions, 17 deletions
diff --git a/meta/lib/oeqa/selftest/cases/pkgdata.py b/meta/lib/oeqa/selftest/cases/pkgdata.py index 254abc40c6..87d069de65 100644 --- a/meta/lib/oeqa/selftest/cases/pkgdata.py +++ b/meta/lib/oeqa/selftest/cases/pkgdata.py | |||
@@ -47,8 +47,8 @@ class OePkgdataUtilTests(OESelftestTestCase): | |||
47 | self.assertGreater(pkgsize, 1, "Size should be greater than 1. %s" % result.output) | 47 | self.assertGreater(pkgsize, 1, "Size should be greater than 1. %s" % result.output) |
48 | 48 | ||
49 | def test_find_path(self): | 49 | def test_find_path(self): |
50 | result = runCmd('oe-pkgdata-util find-path /lib/libz.so.1') | 50 | result = runCmd('oe-pkgdata-util find-path /usr/lib/libz.so.1') |
51 | self.assertEqual(result.output, 'zlib: /lib/libz.so.1') | 51 | self.assertEqual(result.output, 'zlib: /usr/lib/libz.so.1') |
52 | result = runCmd('oe-pkgdata-util find-path /usr/bin/m4') | 52 | result = runCmd('oe-pkgdata-util find-path /usr/bin/m4') |
53 | self.assertEqual(result.output, 'm4: /usr/bin/m4') | 53 | self.assertEqual(result.output, 'm4: /usr/bin/m4') |
54 | result = runCmd('oe-pkgdata-util find-path /not/exist', ignore_status=True) | 54 | result = runCmd('oe-pkgdata-util find-path /not/exist', ignore_status=True) |
@@ -120,8 +120,7 @@ class OePkgdataUtilTests(OESelftestTestCase): | |||
120 | curpkg = line.split(':')[0] | 120 | curpkg = line.split(':')[0] |
121 | files[curpkg] = [] | 121 | files[curpkg] = [] |
122 | return files | 122 | return files |
123 | bb_vars = get_bb_vars(['base_libdir', 'libdir', 'includedir', 'mandir']) | 123 | bb_vars = get_bb_vars(['libdir', 'includedir', 'mandir']) |
124 | base_libdir = bb_vars['base_libdir'] | ||
125 | libdir = bb_vars['libdir'] | 124 | libdir = bb_vars['libdir'] |
126 | includedir = bb_vars['includedir'] | 125 | includedir = bb_vars['includedir'] |
127 | mandir = bb_vars['mandir'] | 126 | mandir = bb_vars['mandir'] |
@@ -138,7 +137,7 @@ class OePkgdataUtilTests(OESelftestTestCase): | |||
138 | self.assertIn('libz1', list(files.keys()), "listed pkgs. files: %s" %result.output) | 137 | self.assertIn('libz1', list(files.keys()), "listed pkgs. files: %s" %result.output) |
139 | self.assertIn('libz-dev', list(files.keys()), "listed pkgs. files: %s" %result.output) | 138 | self.assertIn('libz-dev', list(files.keys()), "listed pkgs. files: %s" %result.output) |
140 | self.assertGreater(len(files['libz1']), 1) | 139 | self.assertGreater(len(files['libz1']), 1) |
141 | libspec = os.path.join(base_libdir, 'libz.so.1.*') | 140 | libspec = os.path.join(libdir, 'libz.so.1.*') |
142 | found = False | 141 | found = False |
143 | for fileitem in files['libz1']: | 142 | for fileitem in files['libz1']: |
144 | if fnmatch.fnmatchcase(fileitem, libspec): | 143 | if fnmatch.fnmatchcase(fileitem, libspec): |
diff --git a/meta/recipes-core/zlib/zlib_1.2.12.bb b/meta/recipes-core/zlib/zlib_1.2.12.bb index e921703137..77e7a4937f 100644 --- a/meta/recipes-core/zlib/zlib_1.2.12.bb +++ b/meta/recipes-core/zlib/zlib_1.2.12.bb | |||
@@ -39,16 +39,4 @@ do_install_ptest() { | |||
39 | install ${B}/examplesh ${D}${PTEST_PATH} | 39 | install ${B}/examplesh ${D}${PTEST_PATH} |
40 | } | 40 | } |
41 | 41 | ||
42 | # Move zlib shared libraries for target builds to $base_libdir so the library | ||
43 | # can be used in early boot before $prefix is mounted. | ||
44 | do_install:append:class-target() { | ||
45 | if [ ${base_libdir} != ${libdir} ] | ||
46 | then | ||
47 | mkdir -p ${D}/${base_libdir} | ||
48 | mv ${D}/${libdir}/libz.so.* ${D}/${base_libdir} | ||
49 | libname=`readlink ${D}/${libdir}/libz.so` | ||
50 | ln -sf ${@oe.path.relative("${libdir}", "${base_libdir}")}/$libname ${D}${libdir}/libz.so | ||
51 | fi | ||
52 | } | ||
53 | |||
54 | BBCLASSEXTEND = "native nativesdk" | 42 | BBCLASSEXTEND = "native nativesdk" |