- Build virtualbox guest additions from source and fix paths
- Install VBoxDRMClient to support resizing
- Support resizing on wayland and x11
- Adding multiple new options
- clipboard
- seamless
- Removing x11 option
- Support linux 6.8
Move vboxclient.desktop from $out/share/autostart/ to
$out/etc/xdg/autostart/. This allows desktop environment autostart logic
to run VBoxClient-all, which is required for shared clipboard
functionality.
Fixes#89923.
Although virtualbox has code to download it at runtime, I'd like to have
it included at build time because:
* I like programs that are fully functional even when offline.
* Runtime downloading doesn't work, it results in error message
"During certificate downloading: Unknown reason".
This change increases the closure size 5 % (969 -> 1020 MiB).
with structuredAttrs lists will be bash arrays which cannot be exported
which will be a issue with some patches and some wrappers like cc-wrapper
this makes it clearer that NIX_CFLAGS_COMPILE must be a string as lists
in env cause a eval failure
Some history:
The linux kernel v5.18-rc contains the commit
> commit 6e8ec2552c7d13991148e551e3325a624d73fac6
> Author: Jason A. Donenfeld <Jason@zx2c4.com>
> Date: 2022-01-16 14:23:10 +0100
>
> random: use computational hash for entropy extraction
> [...]
which modifies the kernels random number generator.
This change broke VirtualBox 6.1.34 in several ways:
It causes random crashes and filesystem corruption in the guest
(at least on some host CPU models).
More details can be found in the
corresponding ticket in the VirtualBox bug tracker:
https://www.virtualbox.org/ticket/20914
That ticket also contains a patch "vbox-linux-5.18.patch"
for VirtualBox that fixes the problem,
at least for kernels 5.18 and (hopefully) above.
This patch got added to nixpkgs' VirtualBox build recipe with
9c8132494f .
Meanwhile, the kernel patch got backported to LTS kernels.
As the VirtualBox patch contains several `#if RTLNX_VER_MIN(5,18,0)`
clauses to apply the fix,
it can't heal VirtualBox on LTS kernel versions.
The result is that VirtualBox is still broken if used
with linux kernels 5.10 and 5.15
(currenly the default kernel in nixpkgs).
Luckily, VirtualBox developers updated the patch
(now named "vbox-linux-5.19.patch") to not only fix the
problem for the upcoming 5.19 kernel, but also address
backport releases.
The commit at hand replaces "vbox-linux-5.18.patch"
with the new "vbox-linux-5.19.patch",
fixing VirtualBox for LTS kernel releases.
The guest additions currently don't build, either before or after this
change, but upgrading is still good because it gets us Linux 5.16
compatibility for the kernel module.