Path to Linux Tree
Hello evreyone,
I am trying to compile a simple kernel module and its documentation says that : /* * demo-module.c * * Compile with * gcc -I/path-to-linux-tree /include -D__KERNEL__ -DMODULE -O2 \ * -Wall -Wstrict-prototypes -c -o demo-module.o demo-module.c */ How can I determine the value of above mentioned "path-to-linux-tree" ?? Thanks in advance. |
it'll be where your kernel source / headers are installed, e.g. /usr/src/linux-2.6.18/include
|
Quote:
But in /usr/src directory I have only one folder called "Fedora" and nothing interesting seems to be inside it... and I have no idea where my kernel source / headers are installed.. thanks. |
In Redhat and Redhat clones like Fedora the kernel source is not normally installed during the install. To see if you have it do a ' rpm -qa | grep kernel '. Look for a kernel-devel****** that matches the current running kernel. If you don't have it then if it is the orginal kernel from the install the rpm will be on one of the CD. Or download it from the ftp site. If newer then goto where you got the new one and download the kernel-devel******.rpm that matches the current running kernel version.
Brian |
All times are GMT -5. The time now is 10:32 AM. |