Re: kernel source

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Gowri Satish Adimulam wrote:
> Hi ,
> 
> as i mentioned in my earlier mails issue with compiling hello-1.c 
> earlier there were suggestions from many people thanks for that .
> I have read make manual and finally came with good make file.
> 
> Now , i facing different error .
> 
> ==========error message
> # make
> make -C /lib/modules/2.6.11-1.1369_FC4/build
> M=/home/gowri/workspace/kernel_pract modules
> make: *** /lib/modules/2.6.11-1.1369_FC4/build: No such file or
> directory.  Stop.
> make: *** [all] Error 2
> 
> =====end error message 
> 
> I have already installed kernel sources
> using yum , "yumdownloader --source kernel".

Try "yum install kernel-devel". I am not sure what yumdownloader is but
even if you put the rest of the command with a valid yum combination, it
would only install the source for the kernel under the /usr/src/redhat
directory, not in the source location.

After installing with the above command the source will be installed in
/usr/src/kernels/<version>. You will need to copy the proper config from
/boot/config-<version> to /usr/src/kernels/<version>/.config

> 
> But when we type command rpm -qa | grep kernel-source
> nothing is returned .

The actual package is kernel-devel<whatever version>.

> 
> is it the problem related to kernel source ?
> if yes how to download kernel source.
> 
> 
> Make file ==============
> obj-m += hello-1.o
> 
> all:
>         make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules
> 
> clean:
>         make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean
> 
> ===========================end of make file 
> 
> 
> 
> 
> --
> Kernelnewbies: Help each other learn about the Linux kernel.
> Archive:       http://mail.nl.linux.org/kernelnewbies/
> FAQ:           http://kernelnewbies.org/faq/
> 
> 


-- 
   kr

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux