mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-24 21:38:07 -05:00
system: Add 'operating-system-with-gc-roots'.
* gnu/tests/install.scm (operating-system-with-gc-roots): Move to... * gnu/system.scm (operating-system-with-gc-roots): ... here. New procedure.
This commit is contained in:
parent
3f9bed04f0
commit
9fcfe30d28
2 changed files with 12 additions and 11 deletions
|
@ -109,6 +109,7 @@ (define-module (gnu system)
|
|||
operating-system-boot-script
|
||||
|
||||
system-linux-image-file-name
|
||||
operating-system-with-gc-roots
|
||||
|
||||
boot-parameters
|
||||
boot-parameters?
|
||||
|
@ -519,6 +520,17 @@ (define* (operating-system-services os)
|
|||
(append (operating-system-user-services os)
|
||||
(operating-system-essential-services os))))
|
||||
|
||||
(define (operating-system-with-gc-roots os roots)
|
||||
"Return a variant of OS where ROOTS are registered as GC roots."
|
||||
(operating-system
|
||||
(inherit os)
|
||||
|
||||
;; We use this procedure for the installation OS, which already defines GC
|
||||
;; roots. Add ROOTS to those.
|
||||
(services (cons (simple-service 'extra-root
|
||||
gc-root-service-type roots)
|
||||
(operating-system-user-services os)))))
|
||||
|
||||
|
||||
;;;
|
||||
;;; /etc.
|
||||
|
|
|
@ -123,17 +123,6 @@ (define (operating-system-with-current-guix os)
|
|||
(inherit config)
|
||||
(guix (current-guix))))))))
|
||||
|
||||
(define (operating-system-with-gc-roots os roots)
|
||||
"Return a variant of OS where ROOTS are registered as GC roots."
|
||||
(operating-system
|
||||
(inherit os)
|
||||
|
||||
;; We use this procedure for the installation OS, which already defines GC
|
||||
;; roots. Add ROOTS to those.
|
||||
(services (cons (simple-service 'extra-root
|
||||
gc-root-service-type roots)
|
||||
(operating-system-user-services os)))))
|
||||
|
||||
|
||||
(define MiB (expt 2 20))
|
||||
|
||||
|
|
Loading…
Reference in a new issue