[Pkg-zfsonlinux-devel] Bug#915886: Probable work-around

Ben McCann bn.mccann at gmail.com
Wed Dec 19 20:20:39 GMT 2018


The issue is that Debian delivers Linux headers in two directories, each of
which is linked under /lib/modules. On my system, with 4.14, these symlinks
are under /lib/modules/4.14.0-3-amd64:

cd /lib/modules/4.14.0-3-amd64

ls -ld build source
lrwxrwxrwx 1 root root 37 Jan 25 2018 build ->
/usr/src/linux-headers-4.14.0-3-amd64
lrwxrwxrwx 1 root root 38 Jan 25 2018 source ->
/usr/src/linux-headers-4.14.0-3-common

The zfs-dkms 'configure' script assumes the Linux include files are
accessible via the 'build' symlink but that only provides access to amd64
CPU dependent files. All the rest of the linux header files are accessible
via 'source' which points to the 'common' header files. That breaks the
zfs-dkms build when 'dkms' runs the 'configure' command.

The work-around creates a symlink to
/usr/src/linux-headers-4.14.0-3-common/include/linux under
linux-headers-4.14.0--amd64 so the configure script can find the files it
needs:

cd /usr/src/linux-headers-4.14.0-3-amd64
ln -s /usr/src/linux-headers-4.14.0-3-common/include/linux .

Now 'build/include/linux' points to the linux headers:

ls -l /lib/modules/4.14.0-3-amd64/build/include/
total 76
drwxr-xr-x 698 root root 69632 Dec 19 09:54 config
drwxr-xr-x 3 root root 4096 Dec 19 09:54 generated
lrwxrwxrwx 1 root root 52 Dec 19 11:22 linux ->
/usr/src/linux-headers-4.14.0-3-common/include/linux

Substitute your kernel version du jour for 4.14.0-3. I've only tested this
with 4.14 so YMMV with other kernel versions.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-zfsonlinux-devel/attachments/20181219/b4be1b81/attachment.html>


More information about the Pkg-zfsonlinux-devel mailing list