[bug#77148,6/9] gnu: ovmf-arm: Update installed firmware.
Commit Message
* gnu/packages/firmware.scm (ovmf-arm)[arguments]: Adjust the 'install
phase to install another binary and to truncate the file to the expected
length.
Change-Id: Ic3319c88ed03c9c80e466ef78eae60837158a456
---
gnu/packages/firmware.scm | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
@@ -1212,9 +1212,14 @@ (define-public ovmf-arm
(lambda _
(let ((fmw (string-append #$output "/share/firmware")))
(mkdir-p fmw)
- (copy-file (string-append "Build/ArmVirtQemu-ARM/"
- "RELEASE_GCC/FV/QEMU_EFI.fd")
- (string-append fmw "/ovmf_arm.bin"))))))))))))
+ (with-directory-excursion "Build/ArmVirtQemu-ARM/RELEASE_GCC/FV"
+ ;; Make the files the desired length and then install them
+ (truncate-file "QEMU_EFI.fd" (* 64 1024 1024))
+ (truncate-file "QEMU_VARS.fd" (* 64 1024 1024))
+ (copy-file "QEMU_VARS.fd"
+ (string-append fmw "/ovmf_vars_arm.bin"))
+ (copy-file "QEMU_EFI.fd"
+ (string-append fmw "/ovmf_arm.bin")))))))))))))
(define-public ovmf-riscv64
(let ((base (make-ovmf-firmware "riscv64")))