mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2025-01-18 21:46:35 +01:00
installer: Warn about hardware support after the welcome page.
This is a followup to 682639c107
, which
added the uvesafb upfront, before welcome page had been displayed.
* gnu/installer/newt/welcome.scm (check-hardware-support): New
procedure.
(run-welcome-page): Use it.
This commit is contained in:
parent
de61a0aa4a
commit
4f7ffb97a4
1 changed files with 44 additions and 41 deletions
|
@ -1,6 +1,6 @@
|
||||||
;;; GNU Guix --- Functional package management for GNU
|
;;; GNU Guix --- Functional package management for GNU
|
||||||
;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com>
|
;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com>
|
||||||
;;; Copyright © 2020 Ludovic Courtès <ludo@gnu.org>
|
;;; Copyright © 2020, 2022 Ludovic Courtès <ludo@gnu.org>
|
||||||
;;; Copyright © 2022 Florian Pelz <pelzflorian@pelzflorian.de>
|
;;; Copyright © 2022 Florian Pelz <pelzflorian@pelzflorian.de>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
|
@ -121,55 +121,58 @@ (define (choice->item str)
|
||||||
(lambda ()
|
(lambda ()
|
||||||
(destroy-form-and-pop form))))))
|
(destroy-form-and-pop form))))))
|
||||||
|
|
||||||
(define (run-welcome-page logo)
|
(define (check-hardware-support)
|
||||||
"Run a welcome page with the given textual LOGO displayed at the center of
|
"Warn about unsupported devices."
|
||||||
the page. Ask the user to choose between manual installation, graphical
|
(when (member "uvesafb" (modules-loaded))
|
||||||
installation and reboot."
|
(run-error-page (G_ "\
|
||||||
(begin
|
|
||||||
(when (member "uvesafb" (modules-loaded))
|
|
||||||
(run-error-page (G_ "\
|
|
||||||
This may be a false alarm, but possibly your graphics hardware does not
|
This may be a false alarm, but possibly your graphics hardware does not
|
||||||
work well with only free software. Expect trouble. If after installation,
|
work well with only free software. Expect trouble. If after installation,
|
||||||
the system does not boot, perhaps you will need to add nomodeset to the
|
the system does not boot, perhaps you will need to add nomodeset to the
|
||||||
kernel arguments and need to configure the uvesafb kernel module.")
|
kernel arguments and need to configure the uvesafb kernel module.")
|
||||||
(G_ "Pre-install warning")))
|
(G_ "Pre-install warning"))))
|
||||||
(when (file-exists? %core-dump)
|
|
||||||
(match
|
(define (run-welcome-page logo)
|
||||||
(choice-window
|
"Run a welcome page with the given textual LOGO displayed at the center of
|
||||||
(G_ "Previous installation failed")
|
the page. Ask the user to choose between manual installation, graphical
|
||||||
(G_ "Continue")
|
installation and reboot."
|
||||||
(G_ "Report the failure")
|
(when (file-exists? %core-dump)
|
||||||
(G_ "It seems that the previous installation exited unexpectedly \
|
(match (choice-window
|
||||||
|
(G_ "Previous installation failed")
|
||||||
|
(G_ "Continue")
|
||||||
|
(G_ "Report the failure")
|
||||||
|
(G_ "It seems that the previous installation exited unexpectedly \
|
||||||
and generated a core dump. Do you want to continue or to report the failure \
|
and generated a core dump. Do you want to continue or to report the failure \
|
||||||
first?"))
|
first?"))
|
||||||
(1 #t)
|
(1 #t)
|
||||||
(2 (raise
|
(2 (raise
|
||||||
(condition
|
(condition
|
||||||
(&user-abort-error))))))
|
(&user-abort-error))))))
|
||||||
(run-menu-page
|
|
||||||
(G_ "GNU Guix install")
|
(run-menu-page
|
||||||
(G_ "Welcome to GNU Guix system installer!
|
(G_ "GNU Guix install")
|
||||||
|
(G_ "Welcome to GNU Guix system installer!
|
||||||
|
|
||||||
You will be guided through a graphical installation program.
|
You will be guided through a graphical installation program.
|
||||||
|
|
||||||
If you are familiar with GNU/Linux and you want tight control over \
|
If you are familiar with GNU/Linux and you want tight control over \
|
||||||
the installation process, you can instead choose manual installation. \
|
the installation process, you can instead choose manual installation. \
|
||||||
Documentation is accessible at any time by pressing Ctrl-Alt-F2.")
|
Documentation is accessible at any time by pressing Ctrl-Alt-F2.")
|
||||||
logo
|
logo
|
||||||
#:listbox-items
|
#:listbox-items
|
||||||
`((,(G_ "Graphical install using a terminal based interface")
|
`((,(G_ "Graphical install using a terminal based interface")
|
||||||
.
|
.
|
||||||
,(const #t))
|
,check-hardware-support)
|
||||||
(,(G_ "Install using the shell based process")
|
(,(G_ "Install using the shell based process")
|
||||||
.
|
.
|
||||||
,(lambda ()
|
,(lambda ()
|
||||||
;; Switch to TTY3, where a root shell is available for shell based
|
(check-hardware-support)
|
||||||
;; install. The other root TTY's would have been ok too.
|
;; Switch to TTY3, where a root shell is available for shell based
|
||||||
(system* "chvt" "3")
|
;; install. The other root TTY's would have been ok too.
|
||||||
(run-welcome-page logo)))
|
(system* "chvt" "3")
|
||||||
(,(G_ "Reboot")
|
(run-welcome-page logo)))
|
||||||
.
|
(,(G_ "Reboot")
|
||||||
,(lambda ()
|
.
|
||||||
(newt-finish)
|
,(lambda ()
|
||||||
(reboot))))
|
(newt-finish)
|
||||||
#:listbox-item->text car)))
|
(reboot))))
|
||||||
|
#:listbox-item->text car))
|
||||||
|
|
Loading…
Reference in a new issue