Archived
1
0
Fork 0

gnu: ovmf-arm: Update to use GCC5.

* gnu/packages/firmware.scm (ovmf-arm): Updating OVMF to 202308 requires
GCC5, packages inheriting from ovmf also need to be updated.

Signed-off-by: Efraim Flashner <efraim@flashner.co.il>
Change-Id: I3a7b3f450e0da39129e7cffce7482b8e391e3858
This commit is contained in:
spacecadet@purge.sh 2023-11-12 03:07:35 +00:00 committed by Efraim Flashner
parent c67e8c12d8
commit edb794bbd4
No known key found for this signature in database
GPG key ID: 41AAE7DCCA3D8351

View file

@ -1018,6 +1018,7 @@ Virtual Machines. OVMF contains a sample UEFI firmware for QEMU and KVM.")
(supported-systems %supported-systems)))) (supported-systems %supported-systems))))
(define-public ovmf-arm (define-public ovmf-arm
(let ((toolchain-ver "GCC5"))
(package (package
(inherit ovmf) (inherit ovmf)
(name "ovmf-arm") (name "ovmf-arm")
@ -1033,21 +1034,23 @@ Virtual Machines. OVMF contains a sample UEFI firmware for QEMU and KVM.")
#~(modify-phases #$phases #~(modify-phases #$phases
#$@(if (string-prefix? "armhf" (%current-system)) #$@(if (string-prefix? "armhf" (%current-system))
'() '()
'((add-before 'configure 'set-env #~((add-before 'configure 'set-env
(lambda _ (lambda _
(setenv "GCC49_ARM_PREFIX" "arm-linux-gnueabihf-"))))) (setenv (string-append #$toolchain-ver "_ARM_PREFIX")
"arm-linux-gnueabihf-")))))
(replace 'build (replace 'build
(lambda _ (lambda _
(invoke "build" "-a" "ARM" "-t" "GCC49" (invoke "build" "-a" "ARM" "-t" #$toolchain-ver
"-p" "ArmVirtPkg/ArmVirtQemu.dsc"))) "-p" "ArmVirtPkg/ArmVirtQemu.dsc")))
(delete 'build-x64) (delete 'build-x64)
(replace 'install (replace 'install
(lambda _ (lambda _
(let ((fmw (string-append #$output "/share/firmware"))) (let ((fmw (string-append #$output "/share/firmware")))
(mkdir-p fmw) (mkdir-p fmw)
(copy-file "Build/ArmVirtQemu-ARM/RELEASE_GCC49/FV/QEMU_EFI.fd" (copy-file (string-append "Build/ArmVirtQemu-ARM/RELEASE_"
#$toolchain-ver "/FV/QEMU_EFI.fd")
(string-append fmw "/ovmf_arm.bin"))))))))) (string-append fmw "/ovmf_arm.bin")))))))))
(supported-systems %supported-systems))) (supported-systems %supported-systems))))
(define* (make-arm-trusted-firmware platform (define* (make-arm-trusted-firmware platform
#:key (triplet "aarch64-linux-gnu")) #:key (triplet "aarch64-linux-gnu"))