不少朋友在编译内核模块会提示失败,因为需要安装对应操作系统的编译头文件,请按照如下步骤安装即可解决,适用于debian和ubuntu。
在此做个记录。。。
sudo apt-get update # This will update the repositories list
sudo apt-get upgrade # This will update all the necessary packages on your system
sudo apt-get dist-upgrade # This will add/remove any needed packages
reboot # You may need this since sometimes after a upgrade/dist-upgrade, there are some left over entries that get fixed after a reboot
sudo apt-get install linux-headers-$(uname -r) # This should work now