diff options
author | Ludovic Courtès <ludo@gnu.org> | 2017-10-03 23:25:38 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2017-10-11 11:12:33 +0200 |
commit | 1c65cca5743e9171bbd94307195f123d26c0535e (patch) | |
tree | 7ce49ab08817158f722d0a0129e54efc0ad170cc /gnu/build/linux-boot.scm | |
parent | f26af33aec586bafcf21838d6ed3b7e00e2b5b03 (diff) | |
download | patches-1c65cca5743e9171bbd94307195f123d26c0535e.tar patches-1c65cca5743e9171bbd94307195f123d26c0535e.tar.gz |
file-systems: 'mount-file-system' now takes a <file-system> object.
* gnu/build/file-systems.scm (mount-file-system): Rename 'spec' to 'fs'
and assume it's a <file-system>.
* gnu/build/linux-boot.scm (boot-system): Assume MOUNTS is a list of
<file-system> and adjust accordingly.
* gnu/build/linux-container.scm (mount-file-systems): Remove
'file-system->spec' call.
* gnu/services/base.scm (file-system-shepherd-service): Add
'spec->file-system' call. Add (gnu system file-systems) to 'modules'.
* gnu/system/linux-initrd.scm (raw-initrd): Use (gnu system
file-systems). Add 'spec->file-system' call for #:mounts.
Diffstat (limited to 'gnu/build/linux-boot.scm')
-rw-r--r-- | gnu/build/linux-boot.scm | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm index 360ef3faed..3712abe910 100644 --- a/gnu/build/linux-boot.scm +++ b/gnu/build/linux-boot.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> +;;; Copyright © 2013, 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org> ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com> ;;; ;;; This file is part of GNU Guix. @@ -27,9 +27,11 @@ #:use-module (ice-9 match) #:use-module (ice-9 ftw) #:use-module (guix build utils) - #:use-module (guix build syscalls) + #:use-module ((guix build syscalls) + #:hide (file-system-type)) #:use-module (gnu build linux-modules) #:use-module (gnu build file-systems) + #:use-module (gnu system file-systems) #:export (mount-essential-file-systems linux-command-line find-long-option @@ -349,19 +351,17 @@ supports kernel command-line options '--load', '--root', and '--repl'. Mount the root file system, specified by the '--root' command-line argument, if any. -MOUNTS must be a list suitable for 'mount-file-system'. +MOUNTS must be a list of <file-system> objects. When VOLATILE-ROOT? is true, the root file system is writable but any changes to it are lost." - (define root-mount-point? - (match-lambda - ((device _ "/" _ ...) #t) - (_ #f))) + (define (root-mount-point? fs) + (string=? (file-system-mount-point fs) "/")) (define root-fs-type - (or (any (match-lambda - ((device _ "/" type _ ...) type) - (_ #f)) + (or (any (lambda (fs) + (and (root-mount-point? fs) + (file-system-type fs))) mounts) "ext4")) |