1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
4 ;;; This file is part of GNU Guix.
6 ;;; GNU Guix is free software; you can redistribute it and/or modify it
7 ;;; under the terms of the GNU General Public License as published by
8 ;;; the Free Software Foundation; either version 3 of the License, or (at
9 ;;; your option) any later version.
11 ;;; GNU Guix is distributed in the hope that it will be useful, but
12 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
13 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 ;;; GNU General Public License for more details.
16 ;;; You should have received a copy of the GNU General Public License
17 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19 (define-module (gnu packages grub)
20 #:use-module (guix download)
21 #:use-module (guix packages)
22 #:use-module ((guix licenses) #:select (gpl3+))
23 #:use-module (guix build-system gnu)
24 #:use-module (gnu packages)
25 #:use-module (gnu packages flex)
26 #:use-module (gnu packages bison)
27 #:use-module ((gnu packages gettext) #:renamer (symbol-prefix-proc 'gnu:))
28 #:use-module (gnu packages fontutils)
29 #:use-module (gnu packages linux)
30 #:use-module (gnu packages qemu)
31 #:use-module (gnu packages ncurses)
32 #:use-module (gnu packages cdrom))
40 (uri (string-append "mirror://gnu/grub/grub-"
44 "0n64hpmsccvicagvr0c6v0kgp2yw0kgnd3jvsyd26cnwgs7c6kkq"))))
45 (build-system gnu-build-system)
47 '(#:patches (list (assoc-ref %build-inputs "patch/gets"))
48 #:configure-flags '("--disable-werror")
49 #:phases (alist-cons-before
50 'patch-source-shebangs 'patch-stuff
52 (substitute* "grub-core/Makefile.in"
53 (("/bin/sh") (which "sh")))
55 ;; TODO: Re-enable this test when we have Parted.
56 (substitute* "tests/partmap_test.in"
57 (("set -e") "exit 77")))
61 ("gettext" ,gnu:gettext)
62 ("freetype" ,freetype)
66 ("patch/gets" ,(search-patch "grub-gets-undeclared.patch"))))
71 ;; Dependencies for the test suite. The "real" QEMU is needed here,
72 ;; because several targets are used.
74 ("xorriso" ,xorriso)))
75 (home-page "http://www.gnu.org/software/grub/")
77 "GNU GRUB, the Grand Unified Boot Loader (2.x beta)")
79 "GNU GRUB is a Multiboot boot loader. It was derived from GRUB, GRand
80 Unified Bootloader, which was originally designed and implemented by Erich
83 Briefly, the boot loader is the first software program that runs when a
84 computer starts. It is responsible for loading and transferring control to
85 the operating system kernel software (such as the Hurd or the Linux). The
86 kernel, in turn, initializes the rest of the operating system (e.g., GNU).")