public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Uladzimir Bely <ubely@ilbers.de>
To: isar-users@googlegroups.com
Subject: [PATCH] Reinstall imager deps if package in IMAGER_INSTALL has changed.
Date: Mon, 30 Jan 2023 10:07:41 +0100	[thread overview]
Message-ID: <20230130090741.5317-1-ubely@ilbers.de> (raw)

When debugging packages in `isar-apt` that are in IMAGER_INSTALL
list, they happen not to be updated in the resulting image.

For example, in case of u-boot IMAGE_BOOT_FILES is used to generate
files for `/boot` partition. Buildchroot is currently used for
extracting required files from `u-boot`, `optee-os`, etc. These
packages are installed in buildchroot via IMAGER_INSTALL list.

Since modifications of the packages don't change their versions,
updated packages don't go to buildchroot, so previously used versions
are wrongly used. The following can be seen in log:

"<package> is already the newest version"

This patch forces reinstalling all the packages from IMAGER_INSTALL
list if some of them has changed.

Signed-off-by: Uladzimir Bely <ubely@ilbers.de>
---
 meta/classes/image-tools-extension.bbclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/classes/image-tools-extension.bbclass b/meta/classes/image-tools-extension.bbclass
index 101704d0..640e1958 100644
--- a/meta/classes/image-tools-extension.bbclass
+++ b/meta/classes/image-tools-extension.bbclass
@@ -35,12 +35,12 @@ do_install_imager_deps() {
             -o APT::Get::List-Cleanup="0"
         apt-get -o Debug::pkgProblemResolver=yes --no-install-recommends -y \
             --allow-unauthenticated --allow-downgrades --download-only install \
-            ${IMAGER_INSTALL}'
+            --reinstall ${IMAGER_INSTALL}'
 
     deb_dl_dir_export ${BUILDCHROOT_DIR} ${distro}
     sudo -E chroot ${BUILDCHROOT_DIR} sh -c ' \
         apt-get -o Debug::pkgProblemResolver=yes --no-install-recommends -y \
             --allow-unauthenticated --allow-downgrades install \
-            ${IMAGER_INSTALL}'
+            --reinstall ${IMAGER_INSTALL}'
 }
 addtask install_imager_deps before do_image_tools
-- 
2.20.1


             reply	other threads:[~2023-01-30  9:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-30  9:07 Uladzimir Bely [this message]
2023-01-30 10:53 ` Henning Schild
2023-01-30 12:28   ` Moessbauer, Felix
2023-01-30 13:00     ` Roberto A. Foglietta

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230130090741.5317-1-ubely@ilbers.de \
    --to=ubely@ilbers.de \
    --cc=isar-users@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox