diff options
author | Daniel Drake <dsd@laptop.org> | 2012-10-02 16:31:43 (GMT) |
---|---|---|
committer | Daniel Drake <dsd@laptop.org> | 2012-10-02 16:31:43 (GMT) |
commit | ab3d3f992d8271fb6608e815f28611a0ab088343 (patch) | |
tree | 2e2c5b902383849f20a1608382cbe97f147b2b6a /modules/signing/preimage.10.extract.sh | |
parent | c7425d50162106b2de997d71ec3b8bba65c03a15 (diff) |
Generate firmware zip files with model-suffixed names (#12129)
The XO-4 at the present time requires model-suffixes zip file names
e.g. runos4.zip.
This also seems to make sense in the general case, and is implemented
here as being fully backwards-compatible with firmware that don't
support it.
Diffstat (limited to 'modules/signing/preimage.10.extract.sh')
-rw-r--r-- | modules/signing/preimage.10.extract.sh | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/modules/signing/preimage.10.extract.sh b/modules/signing/preimage.10.extract.sh index 489f8b4..01f3753 100644 --- a/modules/signing/preimage.10.extract.sh +++ b/modules/signing/preimage.10.extract.sh @@ -4,6 +4,8 @@ # this must be run before the base module creates versioned fs layout . $OOB__shlib +shopt -s nullglob + enabled=$(read_config signing extract) [[ "$enabled" == "1" ]] || exit 0 @@ -17,10 +19,11 @@ echo "Extracting content for signing..." copy_out_file() { local name=$1 - local path="$fsmount"/boot/${1}.zip - [ -f "$path"] || return - cp $path $tgt - found=1 + for path in "$fsmount"/boot/${name}*.zip; do + [ -f "$path" ] || continue + cp $path $tgt + found=1 + done } copy_out bootfw |