image_list_installed_packages_pn has been taken from cve-check.bbclass to make it available for other classes.
Signed-off-by: Davide Gardenal <[email protected]> --- meta/lib/oe/rootfs.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/meta/lib/oe/rootfs.py b/meta/lib/oe/rootfs.py index 9e6b411fb6..54a356102f 100644 --- a/meta/lib/oe/rootfs.py +++ b/meta/lib/oe/rootfs.py @@ -393,6 +393,15 @@ def image_list_installed_packages(d, rootfs_dir=None): cls = importlib.import_module('oe.package_manager.' + img_type) return cls.PMPkgsList(d, rootfs_dir).list_pkgs() +def image_list_installed_packages_pn(d): + recipies = set() + for pkg in list(image_list_installed_packages(d)): + pkg_info = os.path.join(d.getVar('PKGDATA_DIR'), + 'runtime-reverse', pkg) + pkg_data = oe.packagedata.read_pkgdatafile(pkg_info) + recipies.add(pkg_data["PN"]) + return recipies + if __name__ == "__main__": """ We should be able to run this as a standalone script, from outside bitbake -- 2.34.1
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#167340): https://lists.openembedded.org/g/openembedded-core/message/167340 Mute This Topic: https://lists.openembedded.org/mt/92043903/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
