Closes#302291Closes#301536
The following things have changed:
* For 5.7+: ZSWAP compressor uses zstd now.
* For 5.11+: ZRAM compressor uses zstd now.
* For 5.13+: kernel modules are compressed with zstd instead of xz.
* For 5.19+: support zstd-compressed firmware.
The modules-closure functionality needed explicit support for copying
over `.zst` files. Also, the VM image builder used busybox's `insmod`
before which doesn't support zstd. Switched to `kmod` and added xz/zstd
as dependencies for it, similar to how it's done for the actual stage1
in d33e52b253. The use of `kmod` here
doesn't seem to be such a big deal since it's only a build-time
dependency.
The deb files we want are no longer available in the Debian mirrors,
so we need to download them from the snapshots we download the package
lists from.
This makes it possible to build the os-prober NixOS test again.
This fixes e.g. building the rpm of patchelf as in
pkgs/build-support/vm/test.nix. The glob won't work if there are
multiple spec files but I don't think rpmbuild would work in that case
either.
These gave missing attribute errors. They should have been written as
strings in ae9337179b.
Fixes: ae9337179b ("vm: deprecate phases")
Fixes: 52b10ee872 ("vmTools refactor: don't use huge `with pkgs;`")
These are usually set up by systemd, but there's no systemd in the
VM. /dev/fd is required for <(...) syntax in bash, and I'm sure lots
of things depend on the stdin/stdout/stderr links as well.
The current name is misleading: it doesn't contain cli arguments,
but several constants and utility functions related to qemu.
This commit also removes the use of `with import ...` for clarity.
The `platform` field is pointless nesting: it's just stuff that happens
to be defined together, and that should be an implementation detail.
This instead makes `linux-kernel` and `gcc` top level fields in platform
configs. They join `rustc` there [all are optional], which was put there
and not in `platform` in anticipation of a change like this.
`linux-kernel.arch` in particular also becomes `linuxArch`, to match the
other `*Arch`es.
The next step after is this to combine the *specific* machines from
`lib.systems.platforms` with `lib.systems.examples`, keeping just the
"multiplatform" ones for defaulting.
Originally this was meant to support other Windows versions than just
Windows XP, but before I actually got a chance to implement this I left
the project that I implemented this for.
The code has been broken for years now and I highly doubt anyone is
interested in resurrecting this (including me), so in order to make this
less of a maintenance burden for everybody, let's remove it.
Signed-off-by: aszlig <aszlig@nix.build>