ii  dkms                             2.2.0.3-2ubuntu11.7

# dkms build -m xtables-addons -v 2.12 -k 4.15.0-56-generic 
--kernelsourcedir="/root/unpack/usr/src/linux-headers-4.15.0-56-generic"
Error! Your kernel headers for kernel 4.15.0-56-generic cannot be found.
Please install the linux-headers-4.15.0-56-generic package,
or use the --kernelsourcedir option to tell DKMS where it's located

ii  dkms                             2.2.0.3-2ubuntu11.8

# dkms build -m xtables-addons -v 2.12 -k 4.15.0-56-generic
--kernelsourcedir="/root/unpack/usr/src/linux-headers-4.15.0-56-generic"

Preparing kernel 4.15.0-56-generic for module build:
(This is not compiling a kernel, just preparing kernel symbols)
Storing current .config to be restored when complete
...
DKMS: build completed.

# dkms status
xtables-addons, 2.12, 4.15.0-56-generic, x86_64: built
xtables-addons, 2.12, 4.4.0-157-generic, x86_64: installed


** Tags removed: verification-needed verification-needed-xenial
** Tags added: verification-done verification-done-xenial

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to dkms in Ubuntu.
https://bugs.launchpad.net/bugs/1838045

Title:
  Header check ignore --kernelsourcedir

Status in dkms package in Ubuntu:
  Fix Released
Status in dkms source package in Xenial:
  Fix Committed

Bug description:
  In Ubuntu 16.04/Xenial the dkms command (2.2.0.3-2ubuntu11.7) ignores
  the provided kernel source directory and then fails by not finding the
  headers.

  This was fixed upstream in 2.2.0.3-5 and landed in 18.04/Bionic.
  Proposing to backport the additional line of code into Xenial.

  +    [ ! -z "$ksourcedir_fromcli" ] && DIR=$kernel_source_dir

  Testcase:
  Trying to compile any DKMS module with kernel source (headers) in a 
non-standard location (/usr/src) will fail with an error reporting missing 
headers without the change, even using --kernelsourcedir. With the patch 
applied, this works.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/dkms/+bug/1838045/+subscriptions

-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to