guix-commits
[Top][All Lists]
Advanced

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

34/36: system: Add hurd-operating-system-directory-base-entries.


From: guix-commits
Subject: 34/36: system: Add hurd-operating-system-directory-base-entries.
Date: Mon, 27 Apr 2020 06:19:53 -0400 (EDT)

janneke pushed a commit to branch wip-hurd-vm
in repository guix.

commit d2915bb9159828db72d312dda40b1319201a5d78
Author: Jan (janneke) Nieuwenhuizen <address@hidden>
AuthorDate: Sat Apr 25 23:13:57 2020 +0200

    system: Add hurd-operating-system-directory-base-entries.
    
    * gnu/system.scm (hurd-operating-system-directory-base-entries): New
    procedure.
    (hurd-default-essential-services): Use it.  Add user-processes-service.
    * gnu/system/hurd.scm (%base-services/hurd): Remove user-processes-service.
---
 gnu/system.scm      | 34 ++++++++++++++++++++++------------
 gnu/system/hurd.scm |  3 +--
 2 files changed, 23 insertions(+), 14 deletions(-)

diff --git a/gnu/system.scm b/gnu/system.scm
index 30113bf..60dc882 100644
--- a/gnu/system.scm
+++ b/gnu/system.scm
@@ -516,6 +516,14 @@ value of the SYSTEM-SERVICE-TYPE service."
                 ("initrd" ,initrd)
                 ("locale" ,locale))))))   ;used by libc
 
+(define* (hurd-operating-system-directory-base-entries os)
+  "Return the basic entries of the 'system' directory of OS for use as the
+value of the SYSTEM-SERVICE-TYPE service."
+  (let ((locale (operating-system-locale-directory os)))
+    (mlet* %store-monad ((kernel -> (operating-system-kernel os)))
+      (return `(("kernel" ,kernel)
+                ("locale" ,locale))))))
+
 (define (operating-system-default-essential-services os)
   "Return the list of essential services for OS.  These are special services
 that implement part of what's declared in OS are responsible for low-level
@@ -565,18 +573,20 @@ bookkeeping."
                                   (operating-system-firmware os)))))))
 
 (define (hurd-default-essential-services os)
-  (list (service system-service-type '())
-        %boot-service
-        %shepherd-root-service
-        %activation-service
-        (account-service (append (operating-system-accounts os)
-                                 (operating-system-groups os))
-                         (operating-system-skeletons os))
-        (service hurd-file-systems-service-type)
-        (pam-root-service (operating-system-pam-services os))
-        (hurd-etc-service os)
-        (service profile-service-type
-                 (operating-system-packages os))))
+  (let ((entries (hurd-operating-system-directory-base-entries os)))
+    (list (service system-service-type entries)
+          %boot-service
+          %shepherd-root-service
+          %activation-service
+          (service user-processes-service-type '(user-processes))
+          (account-service (append (operating-system-accounts os)
+                                   (operating-system-groups os))
+                           (operating-system-skeletons os))
+          (service hurd-file-systems-service-type)
+          (pam-root-service (operating-system-pam-services os))
+          (hurd-etc-service os)
+          (service profile-service-type
+                   (operating-system-packages os)))))
 
 (define* (operating-system-services os)
   "Return all the services of OS, including \"essential\" services."
diff --git a/gnu/system/hurd.scm b/gnu/system/hurd.scm
index 9a72d1c..0054c77 100644
--- a/gnu/system/hurd.scm
+++ b/gnu/system/hurd.scm
@@ -89,8 +89,7 @@
         inetutils less net-base openssh shepherd which))
 
 (define %base-services/hurd
-  (list (service user-processes-service-type)
-        (service hurd-console-service-type
+  (list (service hurd-console-service-type
                  (hurd-console-configuration (hurd hurd)))
         (service hurd-ttys-service-type
                  (hurd-ttys-configuration (hurd hurd)))



reply via email to

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