【Tiny4412】 编译dnw源码报错 /lib/modules/2.6.32-431.el6.x86_64/build/: No such file or directory
生活随笔
收集整理的這篇文章主要介紹了
【Tiny4412】 编译dnw源码报错 /lib/modules/2.6.32-431.el6.x86_64/build/: No such file or directory
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
??? 1. 今天編譯dnw源碼的時候出現如下錯誤:
???? /lib/modules/2.6.32-431.el6.x86_64/build/: No such file or directory?
???? 截圖如下:
2. 解決辦法
這主要是沒安裝內核安裝包,可以查看/usr/src/kernel文件夾下是否有內核開發包文件。
安裝內核安裝包可以使用如下命令:
[root@deng 4th]# yum list | grep kernel This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register. abrt-addon-kerneloops.x86_64 2.0.8-21.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 dracut-kernel.noarch 004-335.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 kernel.x86_64 2.6.32-431.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 kernel-devel.x86_64 2.6.32-431.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 kernel-firmware.noarch 2.6.32-431.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 kernel-headers.x86_64 2.6.32-431.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 libreport-plugin-kerneloops.x86_64 2.0.9-19.el6 @anaconda-RedHatEnterpriseLinux-201311111358.x86_64/6.5 kernel-abi-whitelists.noarch 2.6.32-431.el6 Uplooking kernel-debug.x86_64 2.6.32-431.el6 Uplooking kernel-debug-devel.x86_64 2.6.32-431.el6 Uplooking kernel-doc.noarch 2.6.32-431.el6 Uplooking [root@deng 4th]#安裝對應的安裝包[root@deng 4th]# yum -y install kernel-devel.x86_64
安裝完成后,在/lib/modules/2.6.32-573.el6.x86_64目錄下查看build的鏈接,如果沒有指向build -> ../../../usr/src/kernels/2.6.32-573.22.1.el6.x86_64/的鏈接需要重新創建一個軟鏈接,具體如下:[root@deng 2.6.32-431.el6.x86_64]# ln -s build ../../../usr/src/kernels/2.6.32-431.el6.x86_64
創建完成后,就進行再次編譯,此時就不會報上述問題了。
總結
以上是生活随笔為你收集整理的【Tiny4412】 编译dnw源码报错 /lib/modules/2.6.32-431.el6.x86_64/build/: No such file or directory的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 【内核驱动】 内核驱动中添加系统调用
- 下一篇: 【Oracle】Redhat6.5环境下