commit 5fa9b97734752832f02b2f9289b717a13ffb9a5d
Author: Sérgio M. Basto <sergio(a)serjux.com>
Date: Tue Dec 24 18:37:02 2019 +0000
New way to build for Kernel 5.5, with kernel v5.5, change the behavior of
depmod. In earlier versions, it was sufficient to copy the contents of
Module.sysmvers from the vboxdrv directory to the current directory to have
the exported symbols from vboxdrv be available to another module such as
vboxnetflt, etc. With v5.5, that no longer works.
The workaround is to pass the path of Module.sysvers to kbuild (make) in a
symbol named KBUILD_EXTRA_SYMBOLS.
VirtualBox-kmod.spec | 22 ++++++++++++++++++++--
1 file changed, 20 insertions(+), 2 deletions(-)
---
diff --git a/VirtualBox-kmod.spec b/VirtualBox-kmod.spec
index 0725446..443b4c2 100644
--- a/VirtualBox-kmod.spec
+++ b/VirtualBox-kmod.spec
@@ -45,7 +45,7 @@
Name: VirtualBox-kmod
Version: 6.1.0
-Release: 1%{?dist}
+Release: 2%{?dist}
#Release: 1%%{?prerel:.%%{prerel}}%%{?dist}
Summary: Kernel module for VirtualBox
@@ -109,6 +109,9 @@ for kernel_version in %{?kernel_versions}; do
make VBOX_USE_INSERT_PAGE=1 %{?_smp_mflags}
KERN_DIR="${kernel_version##*___}" -C "${kernel_version##*___}"
M="${PWD}/_kmod_build_${kernel_version%%___*}/${module}" modules
done
+ %if ! %{with newvboxsf}
+ export
KBUILD_EXTRA_SYMBOLS=$(pwd)/kmod_build_${kernel_version%%___*}/vboxguest/Module.symvers
+ %endif
# copy vboxdrv (for host) module symbols which are used by vboxnetflt and vboxnetadp
km's:
cp _kmod_build_${kernel_version%%___*}/{vboxdrv/Module.symvers,vboxnetadp}
cp _kmod_build_${kernel_version%%___*}/{vboxdrv/Module.symvers,vboxnetflt}
@@ -116,9 +119,15 @@ for kernel_version in %{?kernel_versions}; do
# copy vboxguest (for guest) module symbols which are used by vboxsf km:
cp _kmod_build_${kernel_version%%___*}/{vboxguest/Module.symvers,vboxsf}
%endif
- for module in vbox{netadp,netflt,sf%{?with_vboxvideo:,video}}; do
+ make %{?_smp_mflags} KERN_DIR="${kernel_version##*___}" -C
"${kernel_version##*___}"
M="${PWD}/_kmod_build_${kernel_version%%___*}/vboxsf" modules
+ for module in vbox{netadp,netflt}; do
+ export
KBUILD_EXTRA_SYMBOLS=$(pwd)/_kmod_build_${kernel_version%%___*}/vboxdrv/Module.symvers
make VBOX_USE_INSERT_PAGE=1 %{?_smp_mflags}
KERN_DIR="${kernel_version##*___}" -C "${kernel_version##*___}"
M="${PWD}/_kmod_build_${kernel_version%%___*}/${module}" modules
done
+ %if %{with vboxvideo}
+ export
KBUILD_EXTRA_SYMBOLS=$(pwd)/_kmod_build_${kernel_version%%___*}/vboxguest/Module.symvers
+ make VBOX_USE_INSERT_PAGE=1 %{?_smp_mflags}
KERN_DIR="${kernel_version##*___}" -C "${kernel_version##*___}"
M="${PWD}/_kmod_build_${kernel_version%%___*}/vboxvideo" modules
+ %endif
done
@@ -145,6 +154,15 @@ DIRS=$(ls %{name}-%{version} |wc -l)
%changelog
+* Tue Dec 24 2019 Sérgio Basto <sergio(a)serjux.com> - 6.1.0-2
+- New way to build for Kernel 5.5, with kernel v5.5, change the behavior of
+ depmod. In earlier versions, it was sufficient to copy the contents of
+ Module.sysmvers from the vboxdrv directory to the current directory to have
+ the exported symbols from vboxdrv be available to another module such as
+ vboxnetflt, etc. With v5.5, that no longer works.
+ The workaround is to pass the path of Module.sysvers to kbuild (make) in a
+ symbol named KBUILD_EXTRA_SYMBOLS.
+
* Wed Dec 18 2019 Sérgio Monteiro Basto <sergio(a)serjux.com> - 6.1.0-1
- Update to 6.1.0
Show replies by date