diff options
author | Danny Milosavljevic <dannym@scratchpost.org> | 2017-07-21 01:06:45 +0200 |
---|---|---|
committer | Danny Milosavljevic <dannym@scratchpost.org> | 2017-07-29 19:24:04 +0200 |
commit | 444f9dccc24138acf833f6fea17a8b47a776ba2b (patch) | |
tree | 9de5fc3a6a0171504e86fe0c812a47be7388bdd2 | |
parent | 303690c405446d1eea231044f0bcb48b88b6508d (diff) | |
download | guix-444f9dccc24138acf833f6fea17a8b47a776ba2b.tar guix-444f9dccc24138acf833f6fea17a8b47a776ba2b.tar.gz |
gnu: grub-efi: Add mtools input.
* gnu/packages/bootloaders.scm: Add (gnu packages mtools).
(grub-efi)[inputs]: Add mtools.
[arguments]: Add phase "use-absolute-mtools-path".
-rw-r--r-- | gnu/packages/bootloaders.scm | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index 299a569595..34b8953aa7 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -38,6 +38,7 @@ #:use-module (gnu packages gettext) #:use-module (gnu packages linux) #:use-module (gnu packages man) + #:use-module (gnu packages mtools) #:use-module (gnu packages ncurses) #:use-module (gnu packages perl) #:use-module (gnu packages python) @@ -150,6 +151,7 @@ menu to select one of the installed operating systems.") (synopsis "GRand Unified Boot loader (UEFI version)") (inputs `(("efibootmgr" ,efibootmgr) + ("mtools", mtools) ,@(package-inputs grub))) (arguments `(;; TODO: Tests need a UEFI firmware for qemu. There is one at @@ -167,7 +169,19 @@ menu to select one of the installed operating systems.") (("efibootmgr") (string-append (assoc-ref inputs "efibootmgr") "/sbin/efibootmgr"))) - #t))))))))) + #t)) + (add-after 'patch-stuff 'use-absolute-mtools-path + (lambda* (#:key inputs #:allow-other-keys) + (let ((mtools (assoc-ref inputs "mtools"))) + (substitute* "util/grub-mkrescue.c" + (("\"mformat\"") + (string-append "\"" mtools + "/bin/mformat\""))) + (substitute* "util/grub-mkrescue.c" + (("\"mcopy\"") + (string-append "\"" mtools + "/bin/mcopy\""))) + #t)))))))))) (define-public syslinux (let ((commit "bb41e935cc83c6242de24d2271e067d76af3585c")) |