From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marius Bakke Subject: [PATCH 5/6] gnu: Add efibootmgr. Date: Sat, 5 Nov 2016 12:55:10 +0000 Message-ID: <20161105125511.29383-6-mbakke@fastmail.com> References: <20161105125511.29383-1-mbakke@fastmail.com> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38926) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1c30Vo-0001dE-Tt for guix-devel@gnu.org; Sat, 05 Nov 2016 08:55:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1c30Vn-0001Ps-Ru for guix-devel@gnu.org; Sat, 05 Nov 2016 08:55:56 -0400 Received: from out2-smtp.messagingengine.com ([66.111.4.26]:38177) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1c30Vn-0001On-KB for guix-devel@gnu.org; Sat, 05 Nov 2016 08:55:55 -0400 In-Reply-To: <20161105125511.29383-1-mbakke@fastmail.com> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org Cc: Marius Bakke * gnu/packages/linux.scm (efibootmgr): New variable. --- gnu/packages/linux.scm | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 86e9ff5..5896410 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -3155,3 +3155,49 @@ interface to the UEFI variable facility.") (list license:lgpl2.1+ (license:non-copyleft "file://src/crc32.c" "See src/crc32.c in the distribution."))))) + +(define-public efibootmgr + (package + (name "efibootmgr") + (version "14") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/rhinstaller/" name + "/releases/download/" version "/" name + "-" version ".tar.bz2")) + (sha256 + (base32 + "1n3sydvpr6yl040hhf460k7mrxby7laqd9dqs6pq0js1hijc2zip")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; No tests. + #:make-flags + (list (string-append "prefix=" %output) + (string-append "libdir=" %output "/lib") + ;; Override CFLAGS to add efivar include directory. + (string-append "CFLAGS=-O2 -g -flto -I" + (assoc-ref %build-inputs "efivar") + "/include/efivar")) + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'branding + ;; Replace default loader path with something more familiar. + (lambda _ + (substitute* "src/efibootmgr.c" + (("EFI\\\\\\\\redhat") ; Matches 'EFI\\redhat'. + "EFI\\\\gnu")) + #t)) + (delete 'configure)))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (inputs + `(("efivar" ,efivar) + ("popt" ,popt))) + (home-page "https://github.com/rhinstaller/efibootmgr") + (synopsis "Modify the Extensible Firmware Interface (EFI) boot manager") + (description + "@code{efibootmgr} is a Linux user-space application to modify the +Intel Extensible Firmware Interface (EFI) Boot Manager. This application +can create and destroy boot entries, change the boot order, change the next +running boot option, and more.") + (license license:gpl2+))) -- 2.10.2