rootfs.py: dont try to list installed packages for baremetal images

Theres not a rootfs for baremetal images, hence we should avoid
trying to list rootfs packages for them.

This fixes an issue where some classes (e.g. license_image) rely on
rootfs functionality when included for baremetal images even if its
nonexistent

(From OE-Core rev: 5a7e13f46083ce3b08aa762238c1e93b7626dda4)

Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandro@enedino.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Alejandro Hernandez Samaniego
2022-09-08 18:06:55 -06:00
committed by Richard Purdie
parent dfa8b896c6
commit a86f9ec0d7

View File

@@ -386,6 +386,10 @@ def create_rootfs(d, manifest_dir=None, progress_reporter=None, logcatcher=None)
def image_list_installed_packages(d, rootfs_dir=None):
# Theres no rootfs for baremetal images
if bb.data.inherits_class('baremetal-image', d):
return ""
if not rootfs_dir:
rootfs_dir = d.getVar('IMAGE_ROOTFS')