diff options
author | Marius Bakke <mbakke@fastmail.com> | 2017-10-10 22:33:28 +0200 |
---|---|---|
committer | Marius Bakke <mbakke@fastmail.com> | 2017-10-10 22:33:28 +0200 |
commit | c01ef97594a8b06e884906a5efbdfacf8ba33dc3 (patch) | |
tree | 828b4711c6ad71ab8fc9b6fc8f23f80979c5fe9b /gnu/system.scm | |
parent | 86d02fa8010c053ba980e4c39373b9bf8af0561d (diff) | |
parent | 4b8b4418e609b5e0bfb6efbc11ac28deaa437e80 (diff) | |
download | guix-c01ef97594a8b06e884906a5efbdfacf8ba33dc3.tar.gz guix-c01ef97594a8b06e884906a5efbdfacf8ba33dc3.zip |
Merge branch 'master' into core-updates
Diffstat (limited to 'gnu/system.scm')
-rw-r--r-- | gnu/system.scm | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/gnu/system.scm b/gnu/system.scm index 8ab4801b74..5f562b48bb 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -231,6 +231,14 @@ directly by the user." (kernel-arguments boot-parameters-kernel-arguments) (initrd boot-parameters-initrd)) +(define (ensure-not-/dev device) + "If DEVICE starts with a slash, return #f. This is meant to filter out +Linux device names such as /dev/sda, and to preserve GRUB device names and +file system labels." + (if (and (string? device) (string-prefix? "/" device)) + #f + device)) + (define (read-boot-parameters port) "Read boot parameters from PORT and return the corresponding <boot-parameters> object or #f if the format is unrecognized." @@ -243,11 +251,6 @@ directly by the user." ((? string? device) device))) - (define (ensure-not-/dev device) - (if (and (string? device) (string-prefix? "/" device)) - #f - device)) - (match (read port) (('boot-parameters ('version 0) ('label label) ('root-device root) @@ -580,6 +583,9 @@ export INFOPATH=$HOME/.guix-profile/share/info:/run/current-system/profile/share export XDG_DATA_DIRS=$HOME/.guix-profile/share:/run/current-system/profile/share export XDG_CONFIG_DIRS=$HOME/.guix-profile/etc/xdg:/run/current-system/profile/etc/xdg +# Make sure libXcursor finds cursors installed into user or system profiles. See <http://bugs.gnu.org/24445> +export XCURSOR_PATH=$HOME/.icons:$HOME/.guix-profile/share/icons:/run/current-system/profile/share/icons + # Ignore the default value of 'PATH'. unset PATH @@ -939,7 +945,7 @@ kernel arguments for that derivation to <boot-parameters>." (operating-system-user-kernel-arguments os))) (initrd initrd) (bootloader-name bootloader-name) - (store-device (fs->boot-device store)) + (store-device (ensure-not-/dev (fs->boot-device store))) (store-mount-point (file-system-mount-point store)))))) (define (device->sexp device) |