summaryrefslogtreecommitdiffstats
path: root/meta/classes/package.bbclass
diff options
context:
space:
mode:
authorAlexander Kanavin <alex.kanavin@gmail.com>2019-09-03 16:32:41 (GMT)
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-09-06 13:58:10 (GMT)
commitfe029a11bc6324a4234cdba8922c3229d3d4272d (patch)
treea72a5ca1c196fa8666be9840163e4726e68fd017 /meta/classes/package.bbclass
parent4efd32b3ec101e8917d68f9fe2f12ed75806f568 (diff)
downloadpoky-fe029a11bc6324a4234cdba8922c3229d3d4272d.tar.gz
package.bbclass: allow shell-style wildcards in PRIVATE_LIBS
PRIVATE_LIBS is used to exclude 'private' libraries from getting added to automatic runtime dependency resolution. This variable currently has to list all libraries by name, which becomes a maintenance issue if the list of such libraries frequently changes, or is very large. This change allows using shell-style wildcards in the variable, similar to how FILES lists what gets packaged. (From OE-Core rev: 732db32714c208d8eeeb90308926dc886ef7b791) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/package.bbclass')
-rw-r--r--meta/classes/package.bbclass6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 114d655..aa8451f 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -1646,7 +1646,8 @@ python package_do_shlibs() {
1646 prov = (this_soname, ldir, pkgver) 1646 prov = (this_soname, ldir, pkgver)
1647 if not prov in sonames: 1647 if not prov in sonames:
1648 # if library is private (only used by package) then do not build shlib for it 1648 # if library is private (only used by package) then do not build shlib for it
1649 if not private_libs or this_soname not in private_libs: 1649 import fnmatch
1650 if not private_libs or len([i for i in private_libs if fnmatch.fnmatch(this_soname, i)]) == 0:
1650 sonames.add(prov) 1651 sonames.add(prov)
1651 if libdir_re.match(os.path.dirname(file)): 1652 if libdir_re.match(os.path.dirname(file)):
1652 needs_ldconfig = True 1653 needs_ldconfig = True
@@ -1829,7 +1830,8 @@ python package_do_shlibs() {
1829 # /opt/abc/lib/libfoo.so.1 and contains /usr/bin/abc depending on system library libfoo.so.1 1830 # /opt/abc/lib/libfoo.so.1 and contains /usr/bin/abc depending on system library libfoo.so.1
1830 # but skipping it is still better alternative than providing own 1831 # but skipping it is still better alternative than providing own
1831 # version and then adding runtime dependency for the same system library 1832 # version and then adding runtime dependency for the same system library
1832 if private_libs and n[0] in private_libs: 1833 import fnmatch
1834 if private_libs and len([i for i in private_libs if fnmatch.fnmatch(n[0], i)]) > 0:
1833 bb.debug(2, '%s: Dependency %s covered by PRIVATE_LIBS' % (pkg, n[0])) 1835 bb.debug(2, '%s: Dependency %s covered by PRIVATE_LIBS' % (pkg, n[0]))
1834 continue 1836 continue
1835 if n[0] in shlib_provider.keys(): 1837 if n[0] in shlib_provider.keys():