Install wireguard-dkms fails with error


can you please advise how to install package wireguard-dkms?

My system is running Linux kernel

root@osmc:~# uname -r

and I installed Linux kernel header

root@osmc:~# apt list --installed | grep header

WARNING: apt-real does not have a stable CLI interface. Use with caution in scripts.

vero364-headers-4.9.269-15-osmc/unknown,now 4.9.269-15-osmc arm64 [installed]

however I get this error when I try to install package wireguard-dkms:

Unpacking wireguard-dkms (1.0.20210219-1) over (1.0.20210219-1) ...
Setting up wireguard-dkms (1.0.20210219-1) ...
Loading new wireguard-1.0.20210219 DKMS files...
Building for 4.9.269-15-osmc
Building initial module for 4.9.269-15-osmc
Error! Bad return status for module build on kernel: 4.9.269-15-osmc (aarch64)
Consult /var/lib/dkms/wireguard/1.0.20210219/build/make.log for more information.
dpkg: error processing package wireguard-dkms (--configure):
 installed wireguard-dkms package post-installation script subprocess returned error exit status 10
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)

Please advise how to fix this error.


The Wireguard module is already included.