I tried to compile simple device driver (hello.c) in RasPi. I already installed tool and some linux-headers in Raspbian. The current version is 3.2.27. But, I cannot find the 3.2.27's linux-header. How can I compile device driver with the right version of linux-header in Raspbian?
By the way, I can compile and run the same simple driver hello.c in Ubuntu Desktop.
Thank you in advance.pi@raspberrypi ~ $ sudo apt-cache search linux-header*
linux-headers-2.6-mx5 - Header files for Linux mx5 configuration (dummy package)
linux-headers-2.6-omap - Header files for Linux omap configuration (dummy package)
linux-headers-3.2.0-3-all - All header files for Linux 3.2 (meta-package)
linux-headers-3.2.0-3-all-armhf - All header files for Linux 3.2 (meta-package)
linux-headers-3.2.0-3-common - Common header files for Linux 3.2.0-3
linux-headers-3.2.0-3-rpi - Header files for Linux 3.2.0-3-rpi
linux-headers-mx5 - Header files for Linux mx5 configuration (meta-package)
linux-headers-omap - Header files for Linux omap configuration (meta-package)
linux-headers-vexpress - Header files for Linux vexpress configuration (meta-package)
$
pi@raspberrypi ~ $ sudo apt-get install linux-headers-3.2.0-3-rpi linux-headers-3.2.0-3-all
Reading package lists... Done
Building dependency tree
Reading state information... Done
linux-headers-3.2.0-3-all is already the newest version.
linux-headers-3.2.0-3-rpi is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded
$
pi@raspberrypi ~ $ gcc -v
Using built-in specs ....
gcc version 4.6.3 (Debian 4.6.3-8+rpi1)
pi@raspberrypi ~ $ uname -a
Linux raspberrypi 3.2.27+ #102 PREEMPT Sat Sep 1 01:00:50 BST 2012 armv6l GNU/Linux