summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2024-06-16 17:49:44 +0100
committerLeah Rowe <leah@libreboot.org>2024-06-16 17:50:13 +0100
commit12b26f207fe343ffe7077398abc75f09b83c7506 (patch)
tree1cf26eecf52ed1a337eee44090e9f36f9e2a9b9a
parente67628c6a5e7a6ac23b4c519a753ead61beae116 (diff)
roms cproms(): allow other commands besides cp
e.g. the operator might specify mv instead Signed-off-by: Leah Rowe <leah@libreboot.org>
-rwxr-xr-xscript/roms20
1 files changed, 10 insertions, 10 deletions
diff --git a/script/roms b/script/roms
index d0f95524..fd294e06 100755
--- a/script/roms
+++ b/script/roms
@@ -219,7 +219,7 @@ build_seabios_roms()
newrom="$romdir/seabios_${board}_${initmode}_$displaymode"
[ "$initmode" = "normal" ] && newrom="$romdir/seabios" \
&& newrom="${newrom}_${board}_$initmode"
- x_ cprom "$t" "$newrom.rom"
+ x_ cprom cp "$t" "$newrom.rom"
fi
x_ rm -f "$t"
}
@@ -256,15 +256,15 @@ build_grub_roms()
newrom="$romdir/${payload1}_${board}_${initmode}_$displaymode.rom"
[ "$initmode" = "normal" ] && newrom="$romdir/${payload1}_" \
&& newrom="$newrom${board}_$initmode.rom"
- x_ cprom "$tmprom" "$newrom"
+ x_ cprom cp "$tmprom" "$newrom"
if [ "$payload_seabios_withgrub" = "y" ] && \
[ "$payload1" != "grub" ]; then
cbfs "$tmprom" "$grubdata/bootorder" bootorder raw
- x_ cprom "$tmprom" "${newrom%.rom}_grubfirst.rom"
+ x_ cprom cp "$tmprom" "${newrom%.rom}_grubfirst.rom"
if [ "$payload_seabios_grubonly" = "y" ]; then
x_ "$cbfstool" "$tmprom" add-int -i 0 \
-n etc/show-boot-menu
- x_ cprom "$tmprom" "${newrom%.rom}_grubonly.rom"
+ x_ cprom cp "$tmprom" "${newrom%.rom}_grubonly.rom"
fi
fi
}
@@ -293,18 +293,18 @@ build_uboot_roms()
newrom="$romdir/uboot_payload_${board}_${initmode}_$displaymode.rom"
x_ cp "$cbrom" "$tmprom"
cbfs "$tmprom" "$ubootelf" "fallback/payload"
- x_ cprom "$tmprom" "$newrom"
+ x_ cprom cp "$tmprom" "$newrom"
x_ rm -f "$tmprom"
}
cprom()
{
- printf "Creating target image: %s\n" "$2"
+ printf "Creating target image: %s\n" "$3"
- x_ mkdir -p "${2%/*}"
- x_ cp "$1" "$2"
- [ "$xbmk_release" = "y" ] && mksha512sum "$2" "vendorhashes" && \
- x_ ./vendor inject -r "$2" -b "$board" -n nuke; return 0
+ x_ mkdir -p "${3%/*}"
+ x_ $1 "$2" "$3"
+ [ "$xbmk_release" = "y" ] && mksha512sum "$3" "vendorhashes" && \
+ x_ ./vendor inject -r "$3" -b "$board" -n nuke; return 0
}
main $@