all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure.
@ 2017-01-10 17:36 manolis837
  2017-01-10 17:36 ` [PATCH 2/2] gnu: Add GNU Mach manolis837
  2017-01-12 14:09 ` [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure Ludovic Courtès
  0 siblings, 2 replies; 4+ messages in thread
From: manolis837 @ 2017-01-10 17:36 UTC (permalink / raw)
  To: guix-devel

From: Manolis Ragkousis <manolis837@gmail.com>

* gnu/packages/hurd.scm (gnumach-source-url): New procedure.
  (gnumach-headers)[source]: Adjust accordingly.
---
 gnu/packages/hurd.scm | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/hurd.scm b/gnu/packages/hurd.scm
index 557091d05..ba91b60be 100644
--- a/gnu/packages/hurd.scm
+++ b/gnu/packages/hurd.scm
@@ -35,6 +35,10 @@
   (and (string-suffix? "-gnu" triplet)
        (not (string-contains triplet "linux"))))
 
+(define (gnumach-source-url version)
+  (string-append "mirror://gnu/gnumach/gnumach-"
+                 version ".tar.gz"))
+
 (define-public gnumach-headers
   (package
     (name "gnumach-headers")
@@ -42,8 +46,7 @@
     (source
      (origin
       (method url-fetch)
-      (uri (string-append "mirror://gnu/gnumach/gnumach-"
-                          version ".tar.gz"))
+      (uri (gnumach-source-url version))
       (sha256
        (base32
         "02hygsfpd2dljl5lg1vjjg9pizi9jyxd4aiiqzjshz6jax62jm9f"))))
-- 
2.11.0

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

* [PATCH 2/2] gnu: Add GNU Mach.
  2017-01-10 17:36 [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure manolis837
@ 2017-01-10 17:36 ` manolis837
  2017-01-12 14:11   ` Ludovic Courtès
  2017-01-12 14:09 ` [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure Ludovic Courtès
  1 sibling, 1 reply; 4+ messages in thread
From: manolis837 @ 2017-01-10 17:36 UTC (permalink / raw)
  To: guix-devel

From: Manolis Ragkousis <manolis837@gmail.com>

* gnu/packages/hurd.scm (gnumach): New variable.
---
 gnu/packages/hurd.scm | 33 ++++++++++++++++++++++++++++++++-
 1 file changed, 32 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/hurd.scm b/gnu/packages/hurd.scm
index ba91b60be..e745c73d6 100644
--- a/gnu/packages/hurd.scm
+++ b/gnu/packages/hurd.scm
@@ -1,5 +1,5 @@
 ;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2014, 2015, 2016 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
+;;; Copyright © 2014, 2015, 2016, 2017 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -210,3 +210,34 @@ Library for GNU/Hurd.")
 Hurd-minimal package which are needed for both glibc and GCC.")
     (home-page (package-home-page hurd-headers))
     (license (package-license hurd-headers))))
+
+(define-public gnumach
+  (package
+    (name "gnumach")
+    (version "1.8")
+    (source
+     (origin
+      (method url-fetch)
+      (uri (gnumach-source-url version))
+      (sha256
+       (base32
+        "02hygsfpd2dljl5lg1vjjg9pizi9jyxd4aiiqzjshz6jax62jm9f"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:phases (modify-phases %standard-phases
+                  (add-after 'install 'produce-image
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (let* ((out  (assoc-ref outputs "out"))
+                             (boot (string-append out "/boot")))
+                        (system* "make" "gnumach.gz")
+                        (copy-file "gnumach.gz"
+                                   (string-append boot "/gnumach.gz"))))))))
+    (native-inputs
+     `(("mig" ,mig)
+       ("perl" ,perl)))
+    (supported-systems %hurd-systems)
+    (home-page "https://www.gnu.org/software/hurd/microkernel/mach/gnumach.html")
+    (synopsis "Microkernel of the GNU system")
+    (description
+     "GNU Mach is the microkernel upon which a GNU Hurd system is based.")
+    (license gpl2+)))
-- 
2.11.0

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

* Re: [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure.
  2017-01-10 17:36 [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure manolis837
  2017-01-10 17:36 ` [PATCH 2/2] gnu: Add GNU Mach manolis837
@ 2017-01-12 14:09 ` Ludovic Courtès
  1 sibling, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-01-12 14:09 UTC (permalink / raw)
  To: manolis837; +Cc: guix-devel

manolis837@gmail.com skribis:

> From: Manolis Ragkousis <manolis837@gmail.com>
>
> * gnu/packages/hurd.scm (gnumach-source-url): New procedure.
>   (gnumach-headers)[source]: Adjust accordingly.

OK!

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

* Re: [PATCH 2/2] gnu: Add GNU Mach.
  2017-01-10 17:36 ` [PATCH 2/2] gnu: Add GNU Mach manolis837
@ 2017-01-12 14:11   ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-01-12 14:11 UTC (permalink / raw)
  To: manolis837; +Cc: guix-devel

manolis837@gmail.com skribis:

> From: Manolis Ragkousis <manolis837@gmail.com>
>
> * gnu/packages/hurd.scm (gnumach): New variable.

[...]

> +     `(#:phases (modify-phases %standard-phases
> +                  (add-after 'install 'produce-image
> +                    (lambda* (#:key outputs #:allow-other-keys)
> +                      (let* ((out  (assoc-ref outputs "out"))
> +                             (boot (string-append out "/boot")))
> +                        (system* "make" "gnumach.gz")
> +                        (copy-file "gnumach.gz"
> +                                   (string-append boot "/gnumach.gz"))))))))

Make sure the phase returns #t on success:

  (and (zero? (system* "make" …))
       (begin
         (copy-file …)
         #t))

> +    (synopsis "Microkernel of the GNU system")
> +    (description
> +     "GNU Mach is the microkernel upon which a GNU Hurd system is based.")
> +    (license gpl2+)))

Does it build both on GNU/Linux and GNU/Hurd?

We probably need a ‘supported-systems’ field to restrict to i686 and
x86_64(?) GNU/Hurd and possibly GNU/Linux.

OK with these changes, thank you!

Ludo’.

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

end of thread, other threads:[~2017-01-12 14:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-10 17:36 [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure manolis837
2017-01-10 17:36 ` [PATCH 2/2] gnu: Add GNU Mach manolis837
2017-01-12 14:11   ` Ludovic Courtès
2017-01-12 14:09 ` [PATCH 1/2] gnu: hurd: Add gnumach-source-url procedure Ludovic Courtès

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.