From a4b3c24326171fdb0f50935a239203e1d0638d57 Mon Sep 17 00:00:00 2001 From: Krish Jain Date: Fri, 21 Jul 2023 18:49:12 +0530 Subject: [PATCH] add information about the packages contained in the built sysext --- build_library/build_image_util.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/build_library/build_image_util.sh b/build_library/build_image_util.sh index e6cfdd25b56..734101b62f8 100755 --- a/build_library/build_image_util.sh +++ b/build_library/build_image_util.sh @@ -259,6 +259,18 @@ image_packages_portage() { ROOT="$1" PORTAGE_CONFIGROOT="${BUILD_DIR}"/configroot \ equery --no-color list --format '$cpv::$repo' '*' } + +# List dependencies for a package runtime dependencies + +function package_run_dependencies() ( + pkg=${1:?} + ebuild=$(equery-${BOARD} w "${pkg}") + function inherit() { : ; } + . "${ebuild}" + echo ${RDEPEND} +) + + # List packages implicitly contained in rootfs, such as in torcx packages or # initramfs. image_packages_implicit() { @@ -294,6 +306,12 @@ image_packages_implicit() { [ -z "${FLAGS_torcx_manifest}" ] || torcx_manifest::sources_on_disk "${FLAGS_torcx_manifest}" | while read pkg ; do query_available_package "${pkg}" ; done + + + # Include source packages of all sysext images installed on disk. + for docker_containerd_package in $(package_run_dependencies docker) $(package_run_dependencies containerd); do + query_available_package ${docker_containerd_package} + done } # Generate a list of packages installed in an image.