From: "alexander.heinisch via isar-users" <isar-users@googlegroups.com>
To: isar-users@googlegroups.com
Cc: quirin.gylstorff@siemens.com,
Alexander Heinisch <alexander.heinisch@siemens.com>
Subject: [RFC] isar-installer: Let bmap resolve bmap filename
Date: Wed, 17 Sep 2025 14:35:25 +0200 [thread overview]
Message-ID: <20250917123525.488412-1-alexander.heinisch@siemens.com> (raw)
From: Alexander Heinisch <alexander.heinisch@siemens.com>
The current implementation detects .wic.bmap files only in local /install folder only.
That means, bmap is not supported when pulling images from http or similar.
from `man 1 bmaptool`:
"Unless the bmap file is explicitly specified with the "--bmap" option, bmaptool automatically discovers it by looking for a file with the same basename as IMAGE but with the ".bmap" extension. The bmap file is only looked for in IMAGE's directory (or base URL, in case IMAGE was specified as an URL). If the bmap file is not found, bmaptool fails. To copy without bmap, use the "--nobmap" option."
Thus, having `bmaptool copy` auto resolve the bmap file, allows a more robust handling to detect bmap files.
Not only on local media, but also when image is pulled via http.
The downside is, that it fails in cases we don't provide a bmap file unless --nobmap is specified. (Handling for such is not contained in this patch)
Is support for installers without bmap file really a thing?
Signed-off-by: Alexander Heinisch <alexander.heinisch@siemens.com>
---
.../deploy-image/files/usr/bin/deploy-image-wic.sh | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy-image-wic.sh b/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy-image-wic.sh
index 333762f1..3162e9f1 100755
--- a/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy-image-wic.sh
+++ b/meta-isar/recipes-installer/deploy-image/files/usr/bin/deploy-image-wic.sh
@@ -31,7 +31,6 @@ if ! $installer_unattended; then
dialog --msgbox "Could not find an image to install. Installation aborted." 6 60
exit 1
fi
- DISK_BMAP=$(find "$installdata" -type f -iname "${installer_image_uri%.wic*}.wic.bmap")
# inspired by poky/meta/recipes-core/initrdscripts/files/install-efi.sh
target_device_list=""
@@ -117,10 +116,6 @@ if ! $installer_unattended; then
# set absolute paths to be compatible with unattended mode
installer_image_uri="$installdata/$installer_image_uri"
-
- if [ -z "$DISK_BMAP" ]; then
- DISK_BMAP="$installdata/$DISK_BMAP"
- fi
fi
if ! cmp /dev/zero "$installer_target_dev" -n 1M; then
@@ -139,11 +134,6 @@ if ! cmp /dev/zero "$installer_target_dev" -n 1M; then
fi
fi
-bmap_options=""
-if [ -z "$DISK_BMAP" ]; then
- bmap_options="--nobmap"
-fi
-
if ! $installer_unattended; then
clear
fi
@@ -160,6 +150,7 @@ version_ge() {
# Get bmap-tools version
bmap_version=$(bmaptool --version | awk '{ print $NF }')
+bmap_options=""
if version_ge "$bmap_version" "3.6"; then
# Create a named pipe for progress communication
progress_pipe="/tmp/progress"
--
2.39.5
--
You received this message because you are subscribed to the Google Groups "isar-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/isar-users/20250917123525.488412-1-alexander.heinisch%40siemens.com.
reply other threads:[~2025-09-17 12:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20250917123525.488412-1-alexander.heinisch@siemens.com \
--to=isar-users@googlegroups.com \
--cc=alexander.heinisch@siemens.com \
--cc=quirin.gylstorff@siemens.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