When installing asterisk and the zaptel or dahdi module, you may reach the error:
You do not appear to have the sources for <your-kernel-version>
Here, I will explain exactly what asterisk is looking for and how you can fix it.
First, you may really need to install the kernel sources. The headers are needed to compile zaptel/dahdi.
If you use yum, you can install from repository.
yum -y install kernel-devel
If you run SMP kernel, use instead
yum -y install kernel-smp-devel
Here is what zaptel/dahdi will do to determine if you have the kernel source or not :
- find your kernel version by running uname -r and stock it into $(KVERS)
- set variable $(KSRC) to one of the following /lib/modules/$(KVERS)/build or /usr/src/linux or /usr/src/linux-2.4. The Makefile will then check if one of those directories exist.
- The $(KSRC) directory should contain the .config file.
If you installed the kernel sources, you should have the .config file somewhere in /usr/src/kernels/(somedir)
You just then have to create a symbolic link from /usr/src/linux or /lib/modules/$(KVERS)/build to that directory.
Reconfigure, recompile zaptel/dahdi and asterisk.
Hope it helps
From http://www.astblog.com