guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#27695] [PATCH 1/2] bootloader: Add grub-hybrid-bootloader.


From: Danny Milosavljevic
Subject: [bug#27695] [PATCH 1/2] bootloader: Add grub-hybrid-bootloader.
Date: Fri, 14 Jul 2017 21:01:56 +0200

* gnu/packages/bootloaders.scm (grub-hybrid): New variable.
* gnu/bootloader/grub.scm (grub-hybrid-bootloader): New variable.
---
 gnu/bootloader/grub.scm      |  7 +++++++
 gnu/packages/bootloaders.scm | 20 ++++++++++++++++++++
 2 files changed, 27 insertions(+)

diff --git a/gnu/bootloader/grub.scm b/gnu/bootloader/grub.scm
index 880491c98..a67d914ef 100644
--- a/gnu/bootloader/grub.scm
+++ b/gnu/bootloader/grub.scm
@@ -55,6 +55,7 @@
 
             grub-bootloader
             grub-efi-bootloader
+            grub-hybrid-bootloader
 
             grub-configuration))
 
@@ -413,6 +414,12 @@ submenu \"GNU system, old configurations...\" {~%")
    (name 'grub-efi)
    (package grub-efi)))
 
+(define* grub-hybrid-bootloader
+  (bootloader
+   (inherit grub-bootloader)
+   (name 'grub-hybrid)
+   (package grub-hybrid)))
+
 
 ;;;
 ;;; Compatibility macros.
diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm
index 9c6927f2a..946bdfd9b 100644
--- a/gnu/packages/bootloaders.scm
+++ b/gnu/packages/bootloaders.scm
@@ -182,6 +182,26 @@ menu to select one of the installed operating systems.")
                                        "/bin/mcopy\"")))
                      #t))))))))))
 
+(define-public grub-hybrid
+  (package
+    (inherit grub-efi)
+    (name "grub-hybrid")
+    (synopsis "GRand Unified Boot loader (Hybrid version)")
+    (native-inputs
+     `(("grub" ,grub)
+       ,@(package-native-inputs grub-efi)))
+    (arguments
+     (substitute-keyword-arguments (package-arguments grub-efi)
+      ((#:phases phases)
+      `(modify-phases ,phases
+         (add-after 'install 'install-non-efi
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (copy-recursively (string-append (assoc-ref inputs "grub")
+                                              "/lib/grub/i386-pc")
+                               (string-append (assoc-ref outputs "out")
+                                              "/lib/grub/i386-pc"))
+             #t))))))))
+
 (define-public syslinux
   (let ((commit "bb41e935cc83c6242de24d2271e067d76af3585c"))
     (package





reply via email to

[Prev in Thread] Current Thread [Next in Thread]