On 8/25/23 23:14, David C. Rankin wrote:
On 8/25/23 21:23, David C. Rankin wrote:
All,
Upgrading the kernel on Archlinux from linux-6.4.11 to linux-6.4.12 broke
the dkms build of virtualbox 6.1.46 modules. Specifically from the log:
DKMS make.log for vboxhost-6.1.46_non_OSE for kernel 6.4.12-arch1-1 (x86_64)
<snip>
The problem is a new header requirement, net/gso.h, in VBoxNetFlt-linux.c. A
simple sed expression to include the new header fixes the issue for linux
6.4.12, but if you build for multiple kernel versions, it will make the older
kernel dkms builds unhappy.
I simply used:
sed 's|#include <linux/inetdevice.h>|&\n#include <net/gso.h>|'
src/virtualbox-bin-6.1.46/VirtualBox-extracted/src/vboxhost/vboxnetflt/linux/VBoxNetFlt-linux.c
<snip>
To handle both the current and LTS kernel on arch, you need to provide a
preprocessor conditional for the kernel version. That is handled by:
# fix 6.4.10 include requirement
sed -i 's|#include <linux/inetdevice.h>|&\n#if
RTLNX_VER_MIN(6,4,10)\n#include <net/gso.h>\n#endif|'
"${_extractdir}/src/vboxhost/vboxnetflt/linux/VBoxNetFlt-linux.c"
Which simply adds:
#if RTLNX_VER_MIN(6,4,10)
#include <net/gso.h>
#endif
immediately after:
#include <linux/inetdevice.h>
in src/vboxhost/vboxnetflt/linux/VBoxNetFlt-linux.c
--
David C. Rankin, J.D.,P.E.
_______________________________________________
VBox-users-community mailing list
VBox-users-community@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vbox-users-community
_______________________________________________
Unsubscribe:
mailto:vbox-users-community-requ...@lists.sourceforge.net?subject=unsubscribe