So I am trying to write a simple hello module no need to say a newbie :)
however while following steps to create a make file - what I saw was I didnot have build folder at uname -r/build so I created one - not sure that itself should be problem as in instead of creating build folder if I am suppose to download some package ?
Also looking online there is solution which says I need to do below steps
prepare-kernel-sources cd /usr/src/linux - now turns out I dont i have linux folder too cp -rf include/generated/* include/linux/
make: Entering directory `/lib/modules/2.6.32-5-amd64/build'
make: *** No rule to make target `modules'. Stop.
make: Leaving directory `/lib/modules/2.6.32-5-amd64/build'
I have tried to install following packages - only the highlighted ones goes through rest gives error
**apt-get install linux-headers-$(uname -r)** goes through
apt-get install Linux-headers-generic
apt-get install build-essentials
apt-cache search linux-headers-$(uname -r)
apt-get install kernel-source-$(uname -r)
**apt-get source linux-image-$(uname -r)** goes through
Can someone please help ?
apt-get source
is helpful here though as that probably just grabbed the sources used to build the Debian package itself.) – Etan Reisner