mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 07:26:13 -05:00
install: Make sure uvesafb can be loaded.
Fixes <https://issues.guix.gnu.org/60010>. Reported by pelzflorian (Florian Pelz) <pelzflorian@pelzflorian.de>. Previously, the 'modprobe' executable would try and fail to load the module from /lib/modules/*. Set 'LINUX_MODULE_DIRECTORY' to make sure 'modprobe' looks for the module in the right place. * gnu/system/install.scm (uvesafb-shepherd-service)[modprobe]: New variable. In 'start' method, invoke it instead of KMOD/bin/modprobe.
This commit is contained in:
parent
047ae5c345
commit
b1aef25453
1 changed files with 12 additions and 1 deletions
|
@ -284,13 +284,24 @@ (define %nscd-minimal-caches
|
|||
;; appropriate options. The GUI installer needs it when the machine does not
|
||||
;; support Kernel Mode Setting. Otherwise kmscon is missing /dev/fb0.
|
||||
(define (uvesafb-shepherd-service _)
|
||||
(define modprobe
|
||||
(program-file "modprobe-wrapper"
|
||||
#~(begin
|
||||
;; Use a wrapper because shepherd 0.9.3 won't let us
|
||||
;; pass environment variables to the child process:
|
||||
;; <https://issues.guix.gnu.org/60106>.
|
||||
(setenv "LINUX_MODULE_DIRECTORY"
|
||||
"/run/booted-system/kernel/lib/modules")
|
||||
(apply execl #$(file-append kmod "/bin/modprobe")
|
||||
"modprobe" (cdr (command-line))))))
|
||||
|
||||
(list (shepherd-service
|
||||
(documentation "Load the uvesafb kernel module if needed.")
|
||||
(provision '(maybe-uvesafb))
|
||||
(requirement '(file-systems))
|
||||
(start #~(lambda ()
|
||||
(or (file-exists? "/dev/fb0")
|
||||
(invoke #+(file-append kmod "/bin/modprobe")
|
||||
(invoke #+modprobe
|
||||
"uvesafb"
|
||||
(string-append "v86d=" #$v86d "/sbin/v86d")
|
||||
"mode_option=1024x768"))))
|
||||
|
|
Loading…
Reference in a new issue