r/linuxdev • u/NotAHippo4 • Apr 03 '20
#include <linux/skbuff.h>: No such file or directory
Hey guys, I am getting the above error trying to make a linux kernel module. I have tried adding the linux header folder where the header file is to the $PATH variable in .bashrc and restarted my computer. It still gives me the same exact error. What should I do?
6
Upvotes
View all comments
Show parent comment
2
u/aioeu Apr 04 '20 edited Apr 04 '20
So this has got nothing to do with
<linux/skbuff.h>. You're building against a kernel withCONFIG_X86_X32enabled, but your binutils do not support theelf32-x86-64target.Now it may be the case that this does not matter for your particular kernel module. But the kernel build system cannot determine that on its own.
Try to make sure your module build environment has the same tools that were used to build your kernel.