unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#73927] [PATCH 00/16] Installer support for (cross) installing the Hurd.
@ 2024-10-21  8:13 Janneke Nieuwenhuizen
  2024-10-21  8:16 ` [bug#73927] [PATCH 01/16] system: hurd: Remove qemu networking from %base-services/hurd Janneke Nieuwenhuizen
                   ` (17 more replies)
  0 siblings, 18 replies; 61+ messages in thread
From: Janneke Nieuwenhuizen @ 2024-10-21  8:13 UTC (permalink / raw)
  To: 73927
  Cc: othacehe, ludo, dev, Josselin Poiret, Ludovic Courtès,
	Mathieu Othacehe

Hi!

This patch set adds initial support for installing and running the Hurd on
real iron.  Writing a draft blog post on all the Hurd work that we've done
last year and describing the clumsy way to install a Hurd system inspired me
to have another look at the installer.

I've dusted off some old patches to fix booting a Hurd installation more than
once, then there's some preliminary (installer) work and then it adds a
"Kernel" selection page where you can optionally select "Hurd" next to the
default "Linux Libre".

If you select "Hurd", some defaults are changed such as using an ext2 file
system, some options are disabled such as creating an encrypted partition or a
swap partition, and some menus have a warning about availability of packages.
Finally a fully functional "config.scm" is created for installing the Hurd.

It is using the regular GNU/Linux installer for now and the Hurd system is
being cross installed.  It might be nice to have a Hurd based installer image
some time, maybe when we have better networking support (rumpnet? ;).

I've updated the `hurd-team' branch with this patch set.  To build the
installer, do something like

--8<---------------cut here---------------start------------->8---
./pre-inst-env guix system image -t iso9660 gnu/system/install.scm
or
./pre-inst-env guix system image -t iso9660 --system=i686-linux gnu/system/install.scm
--8<---------------cut here---------------end--------------->8---

(note that the 32bit version using linux-libre-6.10.13 panics for me, I've had
success with linux-libre-5.15 (see <https://git.savannah.gnu.org/cgit/guix.git/commit/?id=80f8ef0a01f2cf39deebfecc344e5f04d87d4bd4>).

The last, but not unimportant feature, are patches to run the installer in
dry-run mode and especially to run it directly from Guile, i.e., without
building the (current-guix) guix derivation for the `hurd-team' branch and
whatnot.

To run the installer (semi-) directly, do something like:

--8<---------------cut here---------------start------------->8---
/pre-inst-env guile -c '((@ (gnu installer) run-installer) #:dry-run? #t)'
or
sudo -E ./pre-inst-env guile -c '((@ (gnu installer) run-installer))'
--8<---------------cut here---------------end--------------->8---

BE VERY CAREFUL WHEN NOT USING #:DRY-RUN #T!

It feels a bit clumsy because it still builds a lightweight installer script
in the store.  We could avoid going via the store and factor-out the gexp'ed
installer steps list from the `installer-steps' procedure.  This is
problematic because it then needs (newt), (parted), and (webutils) modules to
build the installer OS.  We could just add guile-newt, guile-parted,
guile-webutils to the guix package's dependencies but I figured, also from how
the installer was written, that we really don't want this.

I also tried using #:autoload (see
<https://git.savannah.gnu.org/cgit/guix.git/commit/?id=841b0f00afcc57442e348cdec7ca4fcae8372afb>),
but #:autoload seems to fail on record predicates like `disk?'

--8<---------------cut here---------------start------------->8---
Wrong type to apply (#<syntax-transformer disk?>).
--8<---------------cut here---------------end--------------->8---

and also tried adding an extra indirection
(see <https://git.savannah.gnu.org/cgit/guix.git/commit/?id=29a65fa3d251fe1cffea6db5231a0eb7c339987b>)
in the hope to avoid having to use #:autoload for (parted), but as yet to no
avail.

Greetings,
Janneke

Janneke Nieuwenhuizen (16):
  system: hurd: Remove qemu networking from %base-services/hurd.
  gnu: hurd: Support system init in /libexec/runsystem.
  hurd-boot: Support system init: Create essential device nodes.
  system: hurd: Add swap-services to hurd-default-essential-services.
  gnu: hurd: Support second boot.
  hurd-boot: Support second boot.
  maint: Add installer dependencies to the manifest.
  installer: Remove unused (newt) imports.
  installer: Align comments.
  installer: Use "partitioning-page" consistently.
  installer: Fix file-name typos.
  installer: Use `%' for parameter %run-command-in-installer.
  installer: Add dry-run?
  installer: Add "Kernel" page to select the Hurd.
  installer: Add static-networking template.
  DRAFT installer: Support dry-run from Guile via store.

 gnu/build/hurd-boot.scm                 |  35 ++--
 gnu/installer.scm                       | 206 ++++++++++++++++++------
 gnu/installer/final.scm                 |  10 +-
 gnu/installer/kernel.scm                |  34 ++++
 gnu/installer/newt.scm                  |  24 ++-
 gnu/installer/newt/ethernet.scm         |   1 -
 gnu/installer/newt/final.scm            |  20 ++-
 gnu/installer/newt/kernel.scm           |  45 ++++++
 gnu/installer/newt/keymap.scm           |   6 +-
 gnu/installer/newt/locale.scm           |   7 +-
 gnu/installer/newt/page.scm             |   7 +-
 gnu/installer/newt/parameters.scm       |   1 -
 gnu/installer/newt/partition.scm        |  10 +-
 gnu/installer/newt/services.scm         |  32 ++--
 gnu/installer/parted.scm                | 114 ++++++++-----
 gnu/installer/record.scm                |   8 +-
 gnu/installer/services.scm              |  68 ++++++--
 gnu/installer/steps.scm                 |  30 ++--
 gnu/installer/utils.scm                 |  17 +-
 gnu/local.mk                            |   3 +
 gnu/packages/hurd.scm                   |   8 +-
 gnu/packages/patches/hurd-startup.patch |  82 ++++++++++
 gnu/services/base.scm                   |  20 ++-
 gnu/services/virtualization.scm         |   4 +-
 gnu/system.scm                          |  13 +-
 gnu/system/examples/bare-hurd.tmpl      |  10 +-
 gnu/system/hurd.scm                     |  26 +--
 gnu/system/images/hurd.scm              |   2 +-
 manifest.scm                            |   7 +-
 29 files changed, 661 insertions(+), 189 deletions(-)
 create mode 100644 gnu/installer/kernel.scm
 create mode 100644 gnu/installer/newt/kernel.scm
 create mode 100644 gnu/packages/patches/hurd-startup.patch


base-commit: aaa12db63270c487e3be1963b0fdfe93fdb2544d
-- 
2.46.0





^ permalink raw reply	[flat|nested] 61+ messages in thread

end of thread, other threads:[~2024-10-30 14:36 UTC | newest]

Thread overview: 61+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-21  8:13 [bug#73927] [PATCH 00/16] Installer support for (cross) installing the Hurd Janneke Nieuwenhuizen
2024-10-21  8:16 ` [bug#73927] [PATCH 01/16] system: hurd: Remove qemu networking from %base-services/hurd Janneke Nieuwenhuizen
2024-10-21  8:16 ` [bug#73927] [PATCH 02/16] gnu: hurd: Support system init in /libexec/runsystem Janneke Nieuwenhuizen
2024-10-21  8:16 ` [bug#73927] [PATCH 03/16] hurd-boot: Support system init: Create essential device nodes Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 04/16] system: hurd: Add swap-services to hurd-default-essential-services Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 05/16] gnu: hurd: Support second boot Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 06/16] hurd-boot: " Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 07/16] maint: Add installer dependencies to the manifest Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 08/16] installer: Remove unused (newt) imports Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 09/16] installer: Align comments Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 10/16] installer: Use "partitioning-page" consistently Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 11/16] installer: Fix file-name typos Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 12/16] installer: Use `%' for parameter %run-command-in-installer Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 13/16] installer: Add dry-run? Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 14/16] installer: Add "Kernel" page to select the Hurd Janneke Nieuwenhuizen
2024-10-21 18:14   ` Mathieu Othacehe
2024-10-22  8:53     ` janneke
2024-10-22 14:34       ` janneke
2024-10-22 18:06         ` Mathieu Othacehe
2024-10-22 19:18           ` [bug#73927] [PATCH v2 " janneke
2024-10-21  8:17 ` [bug#73927] [PATCH 15/16] installer: Add static-networking template Janneke Nieuwenhuizen
2024-10-21  8:17 ` [bug#73927] [PATCH 16/16] DRAFT installer: Support dry-run from Guile via store Janneke Nieuwenhuizen
2024-10-21 18:18   ` Mathieu Othacehe
2024-10-22  8:21     ` janneke
2024-10-25  9:39 ` [bug#73927] [PATCH v3 00/17] Installer support for (cross) installing the Hurd Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 01/17] gnu: guile-fibers: Fix cross-build for " Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 02/17] guix system: When installing the Hurd, create essential devices Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 03/17] bootloader: grub: Remove hardcoded partition number for the Hurd Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 04/17] system: hurd: Remove qemu networking from %base-services/hurd Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 05/17] system: hurd: Add swap-services to hurd-default-essential-services Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 06/17] gnu: hurd: Support second boot Janneke Nieuwenhuizen
2024-10-25  9:39   ` [bug#73927] [PATCH v3 07/17] hurd-boot: " Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 08/17] maint: Add installer dependencies to the manifest Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 09/17] installer: Remove unused (newt) imports Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 10/17] installer: Align comments Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 11/17] installer: Use "partitioning-page" consistently Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 12/17] installer: Fix file-name typos Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 13/17] installer: Use `%' for parameter %run-command-in-installer Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 14/17] installer: Add dry-run? Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 15/17] installer: Add "Kernel" page to select the Hurd Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 16/17] installer: Add static-networking template Janneke Nieuwenhuizen
2024-10-25  9:40   ` [bug#73927] [PATCH v3 17/17] installer: Support dry-run from Guile via store Janneke Nieuwenhuizen
2024-10-30 14:30 ` [bug#73927] [PATCH v4 00/18] Installer support for (cross) installing the Hurd Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 01/18] gnu: guile-fibers: Fix cross-build for " Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 02/18] reconfigure: Use native bootloader package for running the installer Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 03/18] guix system: When installing the Hurd, create essential devices Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 04/18] bootloader: grub: Remove hardcoded partition number for the Hurd Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 05/18] system: hurd: Remove qemu networking from %base-services/hurd Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 06/18] system: hurd: Add swap-services to hurd-default-essential-services Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 07/18] gnu: hurd: Support second boot Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 08/18] hurd-boot: " Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 09/18] maint: Add installer dependencies to the manifest Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 10/18] installer: Remove unused (newt) imports Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 11/18] installer: Align comments Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 12/18] installer: Use "partitioning-page" consistently Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 13/18] installer: Fix file-name typos Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 14/18] installer: Use `%' for parameter %run-command-in-installer Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 15/18] installer: Add dry-run? Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 16/18] installer: Add "Kernel" page to select the Hurd Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 17/18] installer: Add static-networking template Janneke Nieuwenhuizen
2024-10-30 14:30   ` [bug#73927] [PATCH v4 18/18] installer: Support dry-run from Guile via store Janneke Nieuwenhuizen

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).