unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#40579] [RFC PATCH] add iPXE.
@ 2020-04-12 17:59 Vincent Legoll
  2020-04-12 18:47 ` Tobias Geerinckx-Rice via Guix-patches via
                   ` (2 more replies)
  0 siblings, 3 replies; 18+ messages in thread
From: Vincent Legoll @ 2020-04-12 17:59 UTC (permalink / raw)
  To: 40579

[-- Attachment #1: Type: text/plain, Size: 518 bytes --]

Here is a patch for review that adds iPXE.


The licensing is "interesting", see:

https://ipxe.org/licensing

Is that a problem ?


There was no real install target in makefile, so I

added one, any hints on how to write that in a

cleaner way ?


I've put all firmware & rom images in $(out)/bin

Is there a better subdirectory to put such files ?


The double with-directory-excursion could be

handled with a single phase cd'ing into src, but I

can't find where I've seen that...


WDYT ?


-- 

Vincent Legoll



[-- Attachment #2: 0001-gnu-Add-iPXE.patch --]
[-- Type: text/x-patch, Size: 3589 bytes --]

From d0fcf7a69a7503e8fb5b61a4c1109ebfed208a40 Mon Sep 17 00:00:00 2001
From: Vincent Legoll <vincent.legoll@gmail.com>
Date: Sun, 12 Apr 2020 19:54:47 +0200
Subject: [PATCH] gnu: Add iPXE.

* gnu/packages/bootloaders.scm (ipxe): New variable.
---
 gnu/packages/bootloaders.scm | 54 ++++++++++++++++++++++++++++++++++++
 1 file changed, 54 insertions(+)

diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm
index cadcc937e1..4b1f209540 100644
--- a/gnu/packages/bootloaders.scm
+++ b/gnu/packages/bootloaders.scm
@@ -11,6 +11,7 @@
 ;;; Copyright © 2019 nee <nee@cock.li>
 ;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
 ;;; Copyright © 2020 Björn Höfling <bjoern.hoefling@bjoernhoefling.de>
+;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -834,6 +835,59 @@ to Novena upstream, does not load u-boot.img from the first partition.")
        `(("firmware" ,arm-trusted-firmware-rk3399)
          ,@(package-native-inputs base))))))
 
+(define-public ipxe
+  (package
+    (name "ipxe")
+    (version "1.20.1")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/ipxe/ipxe")
+                    (commit (string-append "v" version))))
+              (file-name (string-append name "-" version "-checkout"))
+              (sha256
+               (base32
+                "0w7h7y97gj9nqvbmsg1zp6zj5mpbbpckqbbx7bpp6k3ahy5fk8zp"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases (modify-phases %standard-phases
+                  (add-after 'unpack 'add-real-make-install
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (substitute* "src/Makefile"
+                        (("^install :")
+                         (string-append "install :"
+                                        "\n\t@$(MKDIR) -p "
+                                        (assoc-ref outputs "out") "/bin"
+                                        "\n\t@$(CP) $(ALL) "
+                                        (assoc-ref outputs "out") "/bin"
+                                        "\n\n__old_install :")))
+                      #t))
+                  (delete 'configure)
+                  (replace 'build
+                     (lambda _ (with-directory-excursion "src"
+                                 (invoke "make" "-j" (number->string
+                                         (parallel-job-count))))))
+                  (replace 'install
+                     (lambda _ (with-directory-excursion "src"
+                                 (invoke "make" "install")))))
+       #:tests? #f))
+    (native-inputs
+     `(("perl" ,perl)
+       ("syslinux" ,syslinux)
+       ("cdrtools" ,cdrtools)
+       ("mtools" ,mtools)
+       ("xz" ,xz)))
+    (home-page "https://ipxe.org")
+    (synopsis "PXE-compliant network boot firmware")
+    (description "iPXE is a network boot firmware.  It provides a full PXE
+implementation enhanced with additional features such as booting from: a web
+server via HTTP, an iSCSI SAN, a Fibre Channel SAN via FCoE, an AoE SAN, a
+wireless network, a wide-area network, an Infiniband network.  It allows to
+control the boot process with a script.  You can use iPXE to replace the
+existing PXE ROM on your network card, or you can chainload into iPXE to obtain
+the features of iPXE without the hassle of reflashing.")
+    (license license:gpl2+)))
+
 (define-public vboot-utils
   (package
     (name "vboot-utils")
-- 
2.26.0


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2021-01-14  8:36 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-12 17:59 [bug#40579] [RFC PATCH] add iPXE Vincent Legoll
2020-04-12 18:47 ` Tobias Geerinckx-Rice via Guix-patches via
2020-04-12 18:58   ` Tobias Geerinckx-Rice via Guix-patches via
2020-04-12 19:46   ` Danny Milosavljevic
2020-04-12 21:18     ` Tobias Geerinckx-Rice via Guix-patches via
2020-04-12 23:28       ` [bug#40579] [PATCH v2] gnu: Add iPXE Tobias Geerinckx-Rice via Guix-patches via
2020-04-14 15:11         ` [bug#40579] [PATCH v3] " Vincent Legoll
2020-04-15 20:41         ` [bug#40579] [PATCH v2] " Danny Milosavljevic
2020-04-15 20:55           ` Vincent Legoll
2020-06-09 19:31           ` Brice Waegeneire
2020-06-09 19:58             ` Vincent Legoll
2020-06-09 20:11               ` Brice Waegeneire
2021-01-12 21:01                 ` Vincent Legoll
2021-01-12 21:44 ` [bug#40579] [PATCH 1/2] " Vincent Legoll
2021-01-12 21:44   ` [bug#40579] [PATCH 2/2] gnu: ipxe: Update to 1.21.1 Vincent Legoll
2021-01-12 21:47   ` [bug#40579] [PATCH 1/2] gnu: Add iPXE Vincent Legoll
2021-01-14  0:53     ` Danny Milosavljevic
2021-01-14  8:33 ` bug#40579: [RFC PATCH] add iPXE Vincent Legoll

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).