diff options
author | Marius Bakke <mbakke@fastmail.com> | 2019-05-24 22:44:51 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2019-05-24 22:44:51 +0200 |
commit | ddb4062784c66ecc0c42910b209dc80356a197ea (patch) | |
tree | d61154cfe888201707c2b4708bd6297ac371f0b0 /gnu/system.scm | |
parent | 563ecba5cf1dac64818fa7c452fcb191ec28e0fd (diff) | |
parent | dbe533292b2af2faad371c10bc9b3f03193f94b7 (diff) | |
download | guix-ddb4062784c66ecc0c42910b209dc80356a197ea.tar guix-ddb4062784c66ecc0c42910b209dc80356a197ea.tar.gz |
Merge branch 'master' into staging
Diffstat (limited to 'gnu/system.scm')
-rw-r--r-- | gnu/system.scm | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/gnu/system.scm b/gnu/system.scm index 0489b9720d..01be1243fe 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -72,6 +72,7 @@ operating-system-bootloader operating-system-services operating-system-essential-services + operating-system-default-essential-services operating-system-user-services operating-system-packages operating-system-host-name @@ -108,6 +109,7 @@ operating-system-boot-script system-linux-image-file-name + operating-system-with-gc-roots boot-parameters boot-parameters? @@ -213,7 +215,8 @@ (essential-services operating-system-essential-services ; list of services (thunked) - (default (essential-services this-operating-system))) + (default (operating-system-default-essential-services + this-operating-system))) (services operating-system-user-services ; list of services (default %base-services)) @@ -463,7 +466,7 @@ value of the SYSTEM-SERVICE-TYPE service." ("initrd" ,initrd) ("locale" ,locale)))))) ;used by libc -(define* (essential-services os) +(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 bookkeeping." @@ -517,6 +520,17 @@ bookkeeping." (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. |