0

I'm trying to install Click Modular Router as a Linux Kernel Module.

I ran the command

sudo ./configure --enable-linuxmodule

And I got the following error

Can't find /usr/src/linux, so I can't compile the linuxmodule driver! (You may need the --with-linux=DIR option.)

I then ran the following command

sudo ./configure --enable-linuxmodule --with-linux=/usr/src/linux-headers-3.2.0-55-generic-pae

And I got the following error

Can't find Linux System.map file in /usr/src/linux-headers-3.2.0-55-generic-pae. (You may need the --with-linux=DIR and/or --with-linux-map=MAP options.)

I need to set this up in such a way that I can put this in an automated deployment script. How would I go about doing this?

1 Answer 1

1

You need to do something like this:

$: LINUX_VERSION=`uname -r` ./configure --with-linux=/usr/src/linux-headers-$LINUX_VERSION --with-linux-map=/boot/System.map-$LINUX_VERSION

If other parts are required, you may need to pass options for them in the same way, if they are for versioned pieces.

The best solution for automated deployment, would be to package it as a debian package, that is installed with dkms so that the kernel module will automatically get rebuilt when new kernels are installed in the system. You can see the virtualbox-dkms package, and other similar -dkms named packages, for how to do this.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .